Patchwork acpi: s4: hibernate/resume failures should be HIGH failures

login
register
mail settings
Submitter Colin King
Date June 28, 2012, 10:44 a.m.
Message ID <1340880244-13312-1-git-send-email-colin.king@canonical.com>
Download mbox | patch
Permalink /patch/167851/
State Accepted
Headers show

Comments

Colin King - June 28, 2012, 10:44 a.m.
From: Colin Ian King <colin.king@canonical.com>

Signed-off-by: Colin Ian King <colin.king@canonical.com>
---
 src/acpi/s4/s4.c |    8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
Alex Hung - July 2, 2012, 2:46 a.m.
On 06/28/2012 06:44 PM, Colin King wrote:
> From: Colin Ian King <colin.king@canonical.com>
>
> Signed-off-by: Colin Ian King <colin.king@canonical.com>
> ---
>   src/acpi/s4/s4.c |    8 ++++----
>   1 file changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/src/acpi/s4/s4.c b/src/acpi/s4/s4.c
> index 368fdcc..087b881 100644
> --- a/src/acpi/s4/s4.c
> +++ b/src/acpi/s4/s4.c
> @@ -177,19 +177,19 @@ static int s4_hibernate(fwts_framework *fw,
>
>   	/* Add in error check for pm-hibernate status */
>   	if ((status > 0) && (status < 128)) {
> -		fwts_failed(fw, LOG_LEVEL_MEDIUM, "PMActionFailedPreS4",
> +		fwts_failed(fw, LOG_LEVEL_HIGH, "PMActionFailedPreS4",
>   			"pm-action failed before trying to put the system "
>   			"in the requested power saving state.");
>   		fwts_tag_failed(fw, FWTS_TAG_POWER_MANAGEMENT);
>   		(*pm_errors)++;
>   	} else if (status == 128) {
> -		fwts_failed(fw, LOG_LEVEL_MEDIUM, "PMActionPowerStateS4",
> +		fwts_failed(fw, LOG_LEVEL_HIGH, "PMActionPowerStateS4",
>   			"pm-action tried to put the machine in the requested "
>   			"power state but failed.");
>   		fwts_tag_failed(fw, FWTS_TAG_POWER_MANAGEMENT);
>   		(*pm_errors)++;
>   	} else if (status > 128) {
> -		fwts_failed(fw, LOG_LEVEL_MEDIUM, "PMActionFailedS4",
> +		fwts_failed(fw, LOG_LEVEL_HIGH, "PMActionFailedS4",
>   			"pm-action encountered an error and also failed to "
>   			"enter the requested power saving state.");
>   		fwts_tag_failed(fw, FWTS_TAG_POWER_MANAGEMENT);
> @@ -278,7 +278,7 @@ static int s4_test_multiple(fwts_framework *fw)
>   				if ((!retried) && (tracing_buffer_size > 4096)) {
>   					retried = true;
>
> -					fwts_failed(fw, LOG_LEVEL_MEDIUM,
> +					fwts_failed(fw, LOG_LEVEL_HIGH,
>   						"TracingBufferTooBig",
>   						"/sys/kernel/debug/tracing/buffer_size_kb is set to %d Kbytes which "
>   						"may cause hibernate to fail. Programs such as ureadahead may have "
>


Acked-by: Alex Hung <alex.hung@canonical.com>
Ivan Hu - July 2, 2012, 10:33 a.m.
On 06/28/2012 06:44 PM, Colin King wrote:
> From: Colin Ian King <colin.king@canonical.com>
>
> Signed-off-by: Colin Ian King <colin.king@canonical.com>
> ---
>   src/acpi/s4/s4.c |    8 ++++----
>   1 file changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/src/acpi/s4/s4.c b/src/acpi/s4/s4.c
> index 368fdcc..087b881 100644
> --- a/src/acpi/s4/s4.c
> +++ b/src/acpi/s4/s4.c
> @@ -177,19 +177,19 @@ static int s4_hibernate(fwts_framework *fw,
>
>   	/* Add in error check for pm-hibernate status */
>   	if ((status > 0) && (status < 128)) {
> -		fwts_failed(fw, LOG_LEVEL_MEDIUM, "PMActionFailedPreS4",
> +		fwts_failed(fw, LOG_LEVEL_HIGH, "PMActionFailedPreS4",
>   			"pm-action failed before trying to put the system "
>   			"in the requested power saving state.");
>   		fwts_tag_failed(fw, FWTS_TAG_POWER_MANAGEMENT);
>   		(*pm_errors)++;
>   	} else if (status == 128) {
> -		fwts_failed(fw, LOG_LEVEL_MEDIUM, "PMActionPowerStateS4",
> +		fwts_failed(fw, LOG_LEVEL_HIGH, "PMActionPowerStateS4",
>   			"pm-action tried to put the machine in the requested "
>   			"power state but failed.");
>   		fwts_tag_failed(fw, FWTS_TAG_POWER_MANAGEMENT);
>   		(*pm_errors)++;
>   	} else if (status > 128) {
> -		fwts_failed(fw, LOG_LEVEL_MEDIUM, "PMActionFailedS4",
> +		fwts_failed(fw, LOG_LEVEL_HIGH, "PMActionFailedS4",
>   			"pm-action encountered an error and also failed to "
>   			"enter the requested power saving state.");
>   		fwts_tag_failed(fw, FWTS_TAG_POWER_MANAGEMENT);
> @@ -278,7 +278,7 @@ static int s4_test_multiple(fwts_framework *fw)
>   				if ((!retried) && (tracing_buffer_size > 4096)) {
>   					retried = true;
>
> -					fwts_failed(fw, LOG_LEVEL_MEDIUM,
> +					fwts_failed(fw, LOG_LEVEL_HIGH,
>   						"TracingBufferTooBig",
>   						"/sys/kernel/debug/tracing/buffer_size_kb is set to %d Kbytes which "
>   						"may cause hibernate to fail. Programs such as ureadahead may have "
>
Acked-by: Ivan Hu<ivan.hu@canonical.com>

Patch

diff --git a/src/acpi/s4/s4.c b/src/acpi/s4/s4.c
index 368fdcc..087b881 100644
--- a/src/acpi/s4/s4.c
+++ b/src/acpi/s4/s4.c
@@ -177,19 +177,19 @@  static int s4_hibernate(fwts_framework *fw,
 
 	/* Add in error check for pm-hibernate status */
 	if ((status > 0) && (status < 128)) {
-		fwts_failed(fw, LOG_LEVEL_MEDIUM, "PMActionFailedPreS4",
+		fwts_failed(fw, LOG_LEVEL_HIGH, "PMActionFailedPreS4",
 			"pm-action failed before trying to put the system "
 			"in the requested power saving state.");
 		fwts_tag_failed(fw, FWTS_TAG_POWER_MANAGEMENT);
 		(*pm_errors)++;
 	} else if (status == 128) {
-		fwts_failed(fw, LOG_LEVEL_MEDIUM, "PMActionPowerStateS4",
+		fwts_failed(fw, LOG_LEVEL_HIGH, "PMActionPowerStateS4",
 			"pm-action tried to put the machine in the requested "
 			"power state but failed.");
 		fwts_tag_failed(fw, FWTS_TAG_POWER_MANAGEMENT);
 		(*pm_errors)++;
 	} else if (status > 128) {
-		fwts_failed(fw, LOG_LEVEL_MEDIUM, "PMActionFailedS4",
+		fwts_failed(fw, LOG_LEVEL_HIGH, "PMActionFailedS4",
 			"pm-action encountered an error and also failed to "
 			"enter the requested power saving state.");
 		fwts_tag_failed(fw, FWTS_TAG_POWER_MANAGEMENT);
@@ -278,7 +278,7 @@  static int s4_test_multiple(fwts_framework *fw)
 				if ((!retried) && (tracing_buffer_size > 4096)) {
 					retried = true;
 
-					fwts_failed(fw, LOG_LEVEL_MEDIUM,
+					fwts_failed(fw, LOG_LEVEL_HIGH,
 						"TracingBufferTooBig",
 						"/sys/kernel/debug/tracing/buffer_size_kb is set to %d Kbytes which "
 						"may cause hibernate to fail. Programs such as ureadahead may have "