platform/x86: dell-laptop: fix broken kbd backlight on Inspiron 10xx
A message that is not in the archive (sent off-list or not yet received): 156824368856.28378.14511879419677114177@WARFSTATION
Re: [PATCH] platform/x86: dell-laptop: fix phantom kbd backlight on Inspiron 10xx
Quoted 10 lines · On Thursday 12 September 2019 01:14:48 Pacien TRAN-GIRARD wrote:
This patch registers a quirk disabling keyboard backlight support for the Dell Inspiron 1012 and 1018.
Those models wrongly report supporting the
KBD_LED_OFF_TOKENandKBD_LED_ON_TOKENSMBIOS tokens, exposing keyboard brightness controls through sysfs which freeze the system when used.The associated SMBIOS calls never return and cause the system to hang, notably at boot when systemd-backlight tries to restore previous brightness settings.
Hi! This sounds like a firmware bug. Have you already reported it to Dell?
Quoted 2 lines
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=107651
Signed-off-by Pacien TRAN-GIRARD <[email protected]>
Signature · 2 lines
Pali Rohár [email protected]
A message that is not in the archive (sent off-list or not yet received): 156882055514.9370.16951540573597044820@WARFSTATION
Re: [PATCH] platform/x86: dell-laptop: fix phantom kbd backlight on Inspiron 10xx
Quoted 9 lines · On Wednesday 18 September 2019 17:29:15 Pacien TRAN-GIRARD wrote:
Quoting Pali Rohár (2019-09-12 09:33:58)
Quoted 8 lines · On Thursday 12 September 2019 01:14:48 Pacien TRAN-GIRARD wrote:
Quoted 7 lines
This patch registers a quirk disabling keyboard backlight support for the Dell Inspiron 1012 and 1018.
Those models wrongly report supporting the
KBD_LED_OFF_TOKENandKBD_LED_ON_TOKENSMBIOS tokens, exposing keyboard brightness controls through sysfs which freeze the system when used.
Quoted 8 lines
Quoted 5 lines
Quoted 3 lines
The associated SMBIOS calls never return and cause the system to hang, notably at boot when systemd-backlight tries to restore previous brightness settings.
Hi! This sounds like a firmware bug. Have you already reported it to Dell?
Yes, the issue has been reported to Dell's technical support, which didn't provide a satisfying answer.
There were already some firmware problems with keyboard backlight and Mario posted this comment about Linux support:
https://github.com/dell/libsmbios/issues/48#issuecomment-391328501
Can you try to use libsmbios tools and if they do not work too, report problem also there?
Quoted 2 lines
I'm not familiar with Dell's policy, but I doubt that they would issue a BIOS update for discontinued models from 2010.
We need to wait what Mario wrote about this particular problem.
Quoted 10 lines
Quoted 7 lines
Quoted 3 lines
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=107651
Signed-off-by Pacien TRAN-GIRARD <[email protected]>Signature · 2 lines
Pali Rohr [email protected]--
Pacien TRAN-GIRARD <[email protected]>
Signature · 2 lines
Pali Rohár [email protected]
RE: [PATCH] platform/x86: dell-laptop: fix phantom kbd backlight on Inspiron 10xx
Quoted 32 lines
-----Original Message-----
From: Pali Rohár <[email protected]>
Sent: Sunday, September 22, 2019 8:43 AM
To: Pacien TRAN-GIRARD
Cc: Matthew Garrett; Darren Hart; Andy Shevchenko; platform-driver- [email protected]; [email protected]; Limonciello, Mario
Subject: Re: [PATCH] platform/x86: dell-laptop: fix phantom kbd backlight on Inspiron 10xxQuoted 9 lines · On Wednesday 18 September 2019 17:29:15 Pacien TRAN-GIRARD wrote:
Quoting Pali Rohár (2019-09-12 09:33:58)
Quoted 8 lines · On Thursday 12 September 2019 01:14:48 Pacien TRAN-GIRARD wrote:
Quoted 7 lines
This patch registers a quirk disabling keyboard backlight support for the Dell Inspiron 1012 and 1018.
Those models wrongly report supporting the
KBD_LED_OFF_TOKENandKBD_LED_ON_TOKENSMBIOS tokens, exposing keyboard brightness controls through sysfs which freeze the system when used.Quoted 8 lines
Quoted 5 lines
Quoted 3 lines
The associated SMBIOS calls never return and cause the system to hang, notably at boot when systemd-backlight tries to restore previous brightness settings.
Hi! This sounds like a firmware bug. Have you already reported it to Dell?
Yes, the issue has been reported to Dell's technical support, which didn't provide a satisfying answer.
There were already some firmware problems with keyboard backlight and Mario posted this comment about Linux support:
https://github.com/dell/libsmbios/issues/48#issuecomment-391328501
Quoted 8 lines
Can you try to use libsmbios tools and if they do not work too, report problem also there?
Quoted 2 lines
I'm not familiar with Dell's policy, but I doubt that they would issue a BIOS update for discontinued models from 2010.
We need to wait what Mario wrote about this particular problem.
I agree an Inspiron is unlikely to be updated 9 years later. I think the right thing to do in this instance is to blacklist this particular platform in kernel driver.
Quoted 14 lines
Quoted 10 lines
Quoted 7 lines
Quoted 3 lines
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=107651
Signed-off-by Pacien TRAN-GIRARD <[email protected]>--
Pali Rohr
[email protected]--
Pacien TRAN-GIRARD <[email protected]>--
Pali Rohár
[email protected]
Re: [PATCH] platform/x86: dell-laptop: fix phantom kbd backlight on Inspiron 10xx
Quoted 8 lines · On Mon, Sep 23, 2019 at 4:24 PM <[email protected]> wrote:
Quoted 7 lines
From: Pali Rohár <[email protected]>
Sent: Sunday, September 22, 2019 8:43 AM
To: Pacien TRAN-GIRARD
Cc: Matthew Garrett; Darren Hart; Andy Shevchenko; platform-driver- [email protected]; [email protected]; Limonciello, Mario
Subject: Re: [PATCH] platform/x86: dell-laptop: fix phantom kbd backlight on Inspiron 10xx
Quoted 5 lines
Quoted 2 lines
We need to wait what Mario wrote about this particular problem.
I agree an Inspiron is unlikely to be updated 9 years later. I think the right thing to do in this instance is to blacklist this particular platform in kernel driver.
Does it mean you are okay with the proposed patch? Can you give your tag then?
Signature · 2 lines
With Best Regards, Andy Shevchenko
Re: [PATCH] platform/x86: dell-laptop: fix phantom kbd backlight on Inspiron 10xx
Quoted 9 lines · On Wednesday 25 September 2019 11:07:35 Andy Shevchenko wrote:
Quoted 7 lines · On Mon, Sep 23, 2019 at 4:24 PM <[email protected]> wrote:
Quoted 7 lines
From: Pali Rohár <[email protected]>
Sent: Sunday, September 22, 2019 8:43 AM
To: Pacien TRAN-GIRARD
Cc: Matthew Garrett; Darren Hart; Andy Shevchenko; platform-driver- [email protected]; [email protected]; Limonciello, Mario
Subject: Re: [PATCH] platform/x86: dell-laptop: fix phantom kbd backlight on Inspiron 10xx
Quoted 7 lines
Quoted 5 lines
Quoted 2 lines
We need to wait what Mario wrote about this particular problem.
I agree an Inspiron is unlikely to be updated 9 years later. I think the right thing to do in this instance is to blacklist this particular platform in kernel driver.
Does it mean you are okay with the proposed patch? Can you give your tag then?
I would rather use different name as kbd_phantom_backlight. E.g. lbd_broken_backlight or something which indicates non-working / disabled support.
Also in commit message is written that problem is with KBD_LED_OFF_TOKEN and KBD_LED_ON_TOKEN tokens, but proposed patch does not blacklist these tokens, but rather turn off whole kbd functionality. So proposed patch does not patch commit message, nor explain it.
Signature · 2 lines
Pali Rohár [email protected]
PATCH v2 1/1 platform/x86: dell-laptop: fix broken kbd backlight on Inspiron 10xx
This patch adds a quirk disabling keyboard backlight support for the Dell Inspiron 1012 and 1018.
Those models wrongly report supporting keyboard backlight control features (through SMBIOS tokens) even though they're not equipped with a backlit keyboard. This led to broken controls being exposed through sysfs by this driver which froze the system when used.
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=107651
--- drivers/platform/x86/dell-laptop.c | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+)
drivers/platform/x86/dell-laptop.c +26 -0
@@ -33,6 +33,7 @@struct quirk_entry {bool touchpad_led; +bool kbd_broken_backlight;bool kbd_led_levels_off_1;bool kbd_missing_ac_tag;
@@ -73,6 +74,10 @@ static struct quirk_entry quirk_dell_latitude_e6410 = { .kbd_led_levels_off_1 = true, }; +static struct quirk_entry quirk_dell_inspiron_1012 = { + .kbd_broken_backlight = true, +}; +static struct platform_driver platform_driver = { .driver = { .name ="dell-laptop" ,
@@ -310,6 +315,24 @@ static const struct dmi_system_id dell_quirks[] __initconst = { }, .driver_data = &quirk_dell_latitude_e6410, }, + { + .callback = dmi_matched, + .ident = "Dell Inspiron 1012", + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."), + DMI_MATCH(DMI_PRODUCT_NAME, "Inspiron 1012"), + }, + .driver_data = &quirk_dell_inspiron_1012, + }, + { + .callback = dmi_matched, + .ident = "Dell Inspiron 1018", + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."), + DMI_MATCH(DMI_PRODUCT_NAME, "Inspiron 1018"), + }, + .driver_data = &quirk_dell_inspiron_1012, + }, { } };
@@ -2040,6 +2063,9 @@ static int __init kbd_led_init(struct device *dev) {int ret; +if (quirks && quirks->kbd_broken_backlight) +return -ENODEV ; +kbd_init ();if (!kbd_led_present)return -ENODEV ;
Signature · 1 line
2.19.2
Quoted 86 lines
-----Original Message-----
From: Pacien TRAN-GIRARD <[email protected]>
Sent: Wednesday, September 25, 2019 4:48 AM
Cc: Pali Rohár; Limonciello, Mario; Matthew Garrett; Darren Hart; Andy Shevchenko; Platform Driver; Linux Kernel Mailing List
Subject: [PATCH v2] platform/x86: dell-laptop: fix broken kbd backlight on Inspiron 10xx[EXTERNAL EMAIL]
This patch adds a quirk disabling keyboard backlight support for the Dell Inspiron 1012 and 1018.
Those models wrongly report supporting keyboard backlight control features (through SMBIOS tokens) even though they're not equipped with a backlit keyboard. This led to broken controls being exposed through sysfs by this driver which froze the system when used.
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=107651
Signed-off-by Pacien TRAN-GIRARD <[email protected]>--- drivers/platform/x86/dell-laptop.c | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+)drivers/platform/x86/dell- renamed from drivers/platform/x86/dell-laptop.c +0
-0
laptop.c
indexd27be2836bc2..ffe5abbdadda100644drivers/platform/x86/dell-laptop.c +26
-1@@ -33,6 +33,7 @@struct quirk_entry {bool touchpad_led; +bool kbd_broken_backlight;bool kbd_led_levels_off_1;bool kbd_missing_ac_tag;@@ -73,6 +74,10 @@ static struct quirk_entry quirk_dell_latitude_e6410 = { .kbd_led_levels_off_1 = true, }; +static struct quirk_entry quirk_dell_inspiron_1012 = { + .kbd_broken_backlight = true, +}; +static struct platform_driver platform_driver = { .driver = { .name ="dell-laptop" ,@@ -310,6 +315,24 @@ static const struct dmi_system_id dell_quirks[]__initconst = { }, .driver_data = &quirk_dell_latitude_e6410, }, + { + .callback = dmi_matched, + .ident = "Dell Inspiron 1012", + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ), +DMI_MATCH (DMI_PRODUCT_NAME ,"Inspiron 1012" ), + }, + .driver_data = &quirk_dell_inspiron_1012, + }, + { + .callback = dmi_matched, + .ident = "Dell Inspiron 1018", + .matches = { +DMI_MATCH (DMI_SYS_VENDOR ,"Dell Inc." ), +DMI_MATCH (DMI_PRODUCT_NAME ,"Inspiron 1018" ), + }, + .driver_data = &quirk_dell_inspiron_1012, + }, { } };@@ -2040,6 +2063,9 @@ static int __init kbd_led_init(struct device *dev) {int ret; +if (quirks && quirks->kbd_broken_backlight) +return -ENODEV ; +kbd_init ();if (!kbd_led_present)return -ENODEV ; --
Quoted 1 line
2.19.2
Looks fine to me, thanks.
Quoted 9 lines · Pacien TRAN-GIRARD
This patch adds a quirk disabling keyboard backlight support for the Dell Inspiron 1012 and 1018.
Those models wrongly report supporting keyboard backlight control features (through SMBIOS tokens) even though they're not equipped with a backlit keyboard. This led to broken controls being exposed through sysfs by this driver which froze the system when used.
Pali, are you okay with this one?
Quoted 66 lines
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=107651
Signed-off-by Pacien TRAN-GIRARD <[email protected]>--- drivers/platform/x86/dell-laptop.c | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+)drivers/platform/x86/dell-laptop.c +26
-1@@ -33,6 +33,7 @@struct quirk_entry {bool touchpad_led; +bool kbd_broken_backlight;bool kbd_led_levels_off_1;bool kbd_missing_ac_tag;@@ -73,6 +74,10 @@ static struct quirk_entry quirk_dell_latitude_e6410 = { .kbd_led_levels_off_1 = true, }; +static struct quirk_entry quirk_dell_inspiron_1012 = { + .kbd_broken_backlight = true, +}; +static struct platform_driver platform_driver = { .driver = { .name ="dell-laptop" ,@@ -310,6 +315,24 @@ static const struct dmi_system_id dell_quirks[] __initconst = { }, .driver_data = &quirk_dell_latitude_e6410, }, + { + .callback = dmi_matched, + .ident = "Dell Inspiron 1012", + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."), + DMI_MATCH(DMI_PRODUCT_NAME, "Inspiron 1012"), + }, + .driver_data = &quirk_dell_inspiron_1012, + }, + { + .callback = dmi_matched, + .ident = "Dell Inspiron 1018", + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."), + DMI_MATCH(DMI_PRODUCT_NAME, "Inspiron 1018"), + }, + .driver_data = &quirk_dell_inspiron_1012, + }, { } };@@ -2040,6 +2063,9 @@ static int __init kbd_led_init(struct device *dev) {int ret; +if (quirks && quirks->kbd_broken_backlight) +return -ENODEV ; +kbd_init ();if (!kbd_led_present)return -ENODEV ; --2.19.2
Signature · 2 lines
With Best Regards, Andy Shevchenko
Quoted 6 lines · On Wednesday 25 September 2019 18:06:40 Andy Shevchenko wrote:
Quoted 4 lines · Pacien TRAN-GIRARD
This patch adds a quirk disabling keyboard backlight support for the Dell Inspiron 1012 and 1018.
Quoted 7 lines
Quoted 5 lines
Those models wrongly report supporting keyboard backlight control features (through SMBIOS tokens) even though they're not equipped with a backlit keyboard. This led to broken controls being exposed through sysfs by this driver which froze the system when used.
Pali, are you okay with this one?
So the real problem is that kbd backlight is not broken, but rather laptop is without backlight keyboard? I thought that just API was broken and keyboard backlight needs to be configured somehow else (via dedicated buttons, etc...).
If yes, then I guess that check for quirk should be in kbd_init() function which do detection if keyboard backlight is present or not. And better name for quirk could be "kbd_led_not_present"...
Quoted 69 lines
Quoted 66 lines
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=107651
Signed-off-by Pacien TRAN-GIRARD <[email protected]>--- drivers/platform/x86/dell-laptop.c | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+)drivers/platform/x86/dell-laptop.c +26
-1@@ -33,6 +33,7 @@struct quirk_entry {bool touchpad_led; +bool kbd_broken_backlight;bool kbd_led_levels_off_1;bool kbd_missing_ac_tag;@@ -73,6 +74,10 @@ static struct quirk_entry quirk_dell_latitude_e6410 = { .kbd_led_levels_off_1 = true, }; +static struct quirk_entry quirk_dell_inspiron_1012 = { + .kbd_broken_backlight = true, +}; +static struct platform_driver platform_driver = { .driver = { .name ="dell-laptop" ,@@ -310,6 +315,24 @@ static const struct dmi_system_id dell_quirks[] __initconst = { }, .driver_data = &quirk_dell_latitude_e6410, }, + { + .callback = dmi_matched, + .ident = "Dell Inspiron 1012", + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."), + DMI_MATCH(DMI_PRODUCT_NAME, "Inspiron 1012"), + }, + .driver_data = &quirk_dell_inspiron_1012, + }, + { + .callback = dmi_matched, + .ident = "Dell Inspiron 1018", + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."), + DMI_MATCH(DMI_PRODUCT_NAME, "Inspiron 1018"), + }, + .driver_data = &quirk_dell_inspiron_1012, + }, { } };@@ -2040,6 +2063,9 @@ static int __init kbd_led_init(struct device *dev) {int ret; +if (quirks && quirks->kbd_broken_backlight) +return -ENODEV ; +kbd_init ();if (!kbd_led_present)return -ENODEV ; --2.19.2
Signature · 2 lines
Pali Rohár [email protected]
PATCH v3 1/1 platform/x86: dell-laptop: disable kbd backlight on Inspiron 10xx
This patch adds a quirk disabling keyboard backlight support for the Dell Inspiron 1012 and 1018.
Those models wrongly report supporting keyboard backlight control features (through SMBIOS tokens) even though they're not equipped with a backlit keyboard. This led to broken controls being exposed through sysfs by this driver which froze the system when used.
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=107651
--- drivers/platform/x86/dell-laptop.c | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+)
drivers/platform/x86/dell-laptop.c +26 -0
@@ -33,6 +33,7 @@struct quirk_entry {bool touchpad_led; +bool kbd_led_not_present;bool kbd_led_levels_off_1;bool kbd_missing_ac_tag;
@@ -73,6 +74,10 @@ static struct quirk_entry quirk_dell_latitude_e6410 = { .kbd_led_levels_off_1 = true, }; +static struct quirk_entry quirk_dell_inspiron_1012 = { + .kbd_led_not_present = true, +}; +static struct platform_driver platform_driver = { .driver = { .name ="dell-laptop" ,
@@ -310,6 +315,24 @@ static const struct dmi_system_id dell_quirks[] __initconst = { }, .driver_data = &quirk_dell_latitude_e6410, }, + { + .callback = dmi_matched, + .ident = "Dell Inspiron 1012", + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."), + DMI_MATCH(DMI_PRODUCT_NAME, "Inspiron 1012"), + }, + .driver_data = &quirk_dell_inspiron_1012, + }, + { + .callback = dmi_matched, + .ident = "Dell Inspiron 1018", + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."), + DMI_MATCH(DMI_PRODUCT_NAME, "Inspiron 1018"), + }, + .driver_data = &quirk_dell_inspiron_1012, + }, { } };
@@ -1493,6 +1516,9 @@ static void kbd_init(void) {int ret; +if (quirks && quirks->kbd_led_not_present) +return ; + ret =kbd_init_info ();kbd_init_tokens ();
Signature · 1 line
2.19.2
Re: [PATCH v3] platform/x86: dell-laptop: disable kbd backlight on Inspiron 10xx
Quoted 11 lines · On Friday 27 September 2019 23:19:03 Pacien TRAN-GIRARD wrote:
This patch adds a quirk disabling keyboard backlight support for the Dell Inspiron 1012 and 1018.
Those models wrongly report supporting keyboard backlight control features (through SMBIOS tokens) even though they're not equipped with a backlit keyboard. This led to broken controls being exposed through sysfs by this driver which froze the system when used.
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=107651
Signed-off-by Pacien TRAN-GIRARD <[email protected]>---
Thank you for update! Now it is clear what is the problem and you can add my
Quoted 61 lines
drivers/platform/x86/dell-laptop.c | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+)drivers/platform/x86/dell-laptop.c +26
-0@@ -33,6 +33,7 @@struct quirk_entry {bool touchpad_led; +bool kbd_led_not_present;bool kbd_led_levels_off_1;bool kbd_missing_ac_tag;@@ -73,6 +74,10 @@ static struct quirk_entry quirk_dell_latitude_e6410 = { .kbd_led_levels_off_1 = true, }; +static struct quirk_entry quirk_dell_inspiron_1012 = { + .kbd_led_not_present = true, +}; +static struct platform_driver platform_driver = { .driver = { .name ="dell-laptop" ,@@ -310,6 +315,24 @@ static const struct dmi_system_id dell_quirks[] __initconst = { }, .driver_data = &quirk_dell_latitude_e6410, }, + { + .callback = dmi_matched, + .ident = "Dell Inspiron 1012", + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."), + DMI_MATCH(DMI_PRODUCT_NAME, "Inspiron 1012"), + }, + .driver_data = &quirk_dell_inspiron_1012, + }, + { + .callback = dmi_matched, + .ident = "Dell Inspiron 1018", + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."), + DMI_MATCH(DMI_PRODUCT_NAME, "Inspiron 1018"), + }, + .driver_data = &quirk_dell_inspiron_1012, + }, { } };@@ -1493,6 +1516,9 @@ static void kbd_init(void) {int ret; +if (quirks && quirks->kbd_led_not_present) +return ; + ret =kbd_init_info ();kbd_init_tokens ();
Signature · 2 lines
Pali Rohár [email protected]
Re: [PATCH] platform/x86: dell-laptop: fix phantom kbd backlight on Inspiron 10xx
In reply to Pali Rohár+Cc: Mario
Quoted 21 lines · Pali Rohár
Quoted 10 lines · On Thursday 12 September 2019 01:14:48 Pacien TRAN-GIRARD wrote:
This patch registers a quirk disabling keyboard backlight support for the Dell Inspiron 1012 and 1018.
Those models wrongly report supporting the
KBD_LED_OFF_TOKENandKBD_LED_ON_TOKENSMBIOS tokens, exposing keyboard brightness controls through sysfs which freeze the system when used.The associated SMBIOS calls never return and cause the system to hang, notably at boot when systemd-backlight tries to restore previous brightness settings.
Hi! This sounds like a firmware bug. Have you already reported it to Dell?
Quoted 2 lines
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=107651
Signed-off-by Pacien TRAN-GIRARD <[email protected]>--
Pali Rohár
[email protected]
Signature · 2 lines
With Best Regards, Andy Shevchenko