Skip to contentSkip to conversation

ACPI video: fix a poor error message

PATCH Superseded Zhang Rui 3 participants 5 messages Aug 17, 2010 ACPI

lore
Share & tools
lore

Zhang Rui

author
#0 lore raw

PATCH 1/1 ACPI video: fix a poor error message

Fix a poor error message, according to comment
https://bugzilla.kernel.org/show_bug.cgi?id=16599#c3

CC Robert Moore <[email protected]>
CC Thomas Renninger <[email protected]>
---
 drivers/acpi/video_detect.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/acpi/video_detect.c +2 -2
Index: linux-2.6/drivers/acpi/video_detect.c
===================================================================
@@ -59,8 +59,8 @@ acpi_backlight_cap_match(acpi_handle han
 				  "support\n"));
 		*cap |= ACPI_VIDEO_BACKLIGHT;
 		if (ACPI_FAILURE(acpi_get_handle(handle, "_BQC", &h_dummy)))
-			printk(KERN_WARNING FW_BUG PREFIX "ACPI brightness "
-					"control misses _BQC function\n");
+			printk(KERN_WARNING FW_BUG PREFIX "could not find "
+					"required _BQC function\n");
 		/* We have backlight support, no need to scan further */
 		return AE_CTRL_TERMINATE;
 	}
#1 lore raw

drivers/acpi/video_detect.c acpi_backlight_cap_match(acpi_handle han · line 63

Quoted 6 lines · Zhang Rui
drivers/acpi/video_detect.c +2 -2
 		*cap |= ACPI_VIDEO_BACKLIGHT;
 		if (ACPI_FAILURE(acpi_get_handle(handle, "_BQC", &h_dummy)))
-			printk(KERN_WARNING FW_BUG PREFIX "ACPI brightness "
-					"control misses _BQC function\n");
+			printk(KERN_WARNING FW_BUG PREFIX "could not find "
+					"required _BQC function\n");

I don't really like the "required". It's a spec requirement but the driver will work fine (if suboptimally) without it.

Signature · 1 line
Matthew Garrett | [email protected]
#2 lore raw

Do we agree that the original message is unclear?

I'm not even sure that ACPI requires this method.

Perhaps the message should describe what won't happen because of the missing _BQC method.

Quoted 20 lines

-----Original Message-----
From: Matthew Garrett [mailto:[email protected]]
Sent: Tuesday, August 17, 2010 6:35 AM
To: Zhang, Rui
Cc: Brown, Len; [email protected]; Moore, Robert; Thomas Renninger
Subject: Re: [PATCH] ACPI video: fix a poor error message

drivers/acpi/video_detect.c acpi_backlight_cap_match(acpi_handle han · line 63

Quoted 6 lines · Zhang Rui
drivers/acpi/video_detect.c +2 -2
 		*cap |= ACPI_VIDEO_BACKLIGHT;
 		if (ACPI_FAILURE(acpi_get_handle(handle, "_BQC", &h_dummy)))
-			printk(KERN_WARNING FW_BUG PREFIX "ACPI brightness "
-					"control misses _BQC function\n");
+			printk(KERN_WARNING FW_BUG PREFIX "could not find "
+					"required _BQC function\n");

I don't really like the "required". It's a spec requirement but the driver will work fine (if suboptimally) without it.

--
Matthew Garrett | [email protected]

#3 lore raw
Quoted 3 lines · Robert

Do we agree that the original message is unclear?

I'm not even sure that ACPI requires this method.

Indeed, it's not actually on the list of required methods.

Quoted 1 line

Perhaps the message should describe what won't happen because of the missing _BQC method.

Perhaps just "No _BQC method: Unable to determine initial brightness"?

Signature · 1 line
Matthew Garrett | [email protected]
#4 lore raw

I like this much better. Probably should drop the colon, so it looks something like:

[Firmware Bug]: ACPI: No _BQC method, cannot determine initial brightness

I leave the question as to whether this is an actual firmware bug to you guys.

Bob

Quoted 21 lines

-----Original Message-----
From: Matthew Garrett [mailto:[email protected]]
Sent: Tuesday, August 17, 2010 8:28 AM
To: Moore, Robert
Cc: Zhang, Rui; Brown, Len; [email protected]; Thomas Renninger
Subject: Re: [PATCH] ACPI video: fix a poor error message

Quoted 3 lines · Robert

Do we agree that the original message is unclear?

I'm not even sure that ACPI requires this method.

Indeed, it's not actually on the list of required methods.

Quoted 1 line

Perhaps the message should describe what won't happen because of the

missing _BQC method.

Perhaps just "No _BQC method: Unable to determine initial brightness"?

--
Matthew Garrett | [email protected]