* [PATCH] ACPI/backlight: Force backlight native for Clevo NL5xRU and @ 2022-03-15 19:02 Werner Sembach 2022-03-15 19:02 ` [PATCH] ACPI/backlight: Force backlight native for Clevo NL5xRU and NL5xNU Werner Sembach 0 siblings, 1 reply; 3+ messages in thread From: Werner Sembach @ 2022-03-15 19:02 UTC (permalink / raw) To: rafael, lenb, linux-acpi, linux-kernel This patch works around a bug appearing on at least two Clevo devices. I also put some effort in finding the root cause for this bug to fix it in general: https://bugzilla.kernel.org/show_bug.cgi?id=215683 I could pinpoint it down where it happens, but could use some ideas for cleanly fixing it. ^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH] ACPI/backlight: Force backlight native for Clevo NL5xRU and NL5xNU 2022-03-15 19:02 [PATCH] ACPI/backlight: Force backlight native for Clevo NL5xRU and Werner Sembach @ 2022-03-15 19:02 ` Werner Sembach 2022-03-17 13:30 ` Rafael J. Wysocki 0 siblings, 1 reply; 3+ messages in thread From: Werner Sembach @ 2022-03-15 19:02 UTC (permalink / raw) To: rafael, lenb, linux-acpi, linux-kernel Clevo NL5xRU and NL5xNU/TUXEDO Aura 15 Gen1 and Gen2 have both a working native and video interface. However the default detection mechanism first registers the video interface before unregistering it again and switching to the native interface during boot. This results in a dangling SBIOS request for backlight change for some reason, causing the backlight to switch to ~2% once per boot on the first power cord connect or disconnect event. Setting the native interface explicitly circumvents this buggy behaviour by avoiding the unregistering process. Signed-off-by: Werner Sembach <wse@tuxedocomputers.com> Cc: stable@vger.kernel.org --- drivers/acpi/video_detect.c | 75 +++++++++++++++++++++++++++++++++++++ 1 file changed, 75 insertions(+) diff --git a/drivers/acpi/video_detect.c b/drivers/acpi/video_detect.c index 4f64713e9917..becc198e4c22 100644 --- a/drivers/acpi/video_detect.c +++ b/drivers/acpi/video_detect.c @@ -415,6 +415,81 @@ static const struct dmi_system_id video_detect_dmi_table[] = { DMI_MATCH(DMI_PRODUCT_NAME, "GA503"), }, }, + /* + * Clevo NL5xRU and NL5xNU/TUXEDO Aura 15 Gen1 and Gen2 have both a + * working native and video interface. However the default detection + * mechanism first registers the video interface before unregistering + * it again and switching to the native interface during boot. This + * results in a dangling SBIOS request for backlight change for some + * reason, causing the backlight to switch to ~2% once per boot on the + * first power cord connect or disconnect event. Setting the native + * interface explicitly circumvents this buggy behaviour, by avoiding + * the unregistering process. + */ + { + .callback = video_detect_force_native, + .ident = "Clevo NL5xRU", + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "TUXEDO"), + DMI_MATCH(DMI_BOARD_NAME, "NL5xRU"), + }, + }, + { + .callback = video_detect_force_native, + .ident = "Clevo NL5xRU", + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "SchenkerTechnologiesGmbH"), + DMI_MATCH(DMI_BOARD_NAME, "NL5xRU"), + }, + }, + { + .callback = video_detect_force_native, + .ident = "Clevo NL5xRU", + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "Notebook"), + DMI_MATCH(DMI_BOARD_NAME, "NL5xRU"), + }, + }, + { + .callback = video_detect_force_native, + .ident = "Clevo NL5xRU", + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "TUXEDO"), + DMI_MATCH(DMI_BOARD_NAME, "AURA1501"), + }, + }, + { + .callback = video_detect_force_native, + .ident = "Clevo NL5xRU", + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "TUXEDO"), + DMI_MATCH(DMI_BOARD_NAME, "EDUBOOK1502"), + }, + }, + { + .callback = video_detect_force_native, + .ident = "Clevo NL5xNU", + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "TUXEDO"), + DMI_MATCH(DMI_BOARD_NAME, "NL5xNU"), + }, + }, + { + .callback = video_detect_force_native, + .ident = "Clevo NL5xNU", + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "SchenkerTechnologiesGmbH"), + DMI_MATCH(DMI_BOARD_NAME, "NL5xNU"), + }, + }, + { + .callback = video_detect_force_native, + .ident = "Clevo NL5xNU", + .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "Notebook"), + DMI_MATCH(DMI_BOARD_NAME, "NL5xNU"), + }, + }, /* * Desktops which falsely report a backlight and which our heuristics -- 2.25.1 ^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] ACPI/backlight: Force backlight native for Clevo NL5xRU and NL5xNU 2022-03-15 19:02 ` [PATCH] ACPI/backlight: Force backlight native for Clevo NL5xRU and NL5xNU Werner Sembach @ 2022-03-17 13:30 ` Rafael J. Wysocki 0 siblings, 0 replies; 3+ messages in thread From: Rafael J. Wysocki @ 2022-03-17 13:30 UTC (permalink / raw) To: Werner Sembach Cc: Rafael J. Wysocki, Len Brown, ACPI Devel Maling List, Linux Kernel Mailing List On Tue, Mar 15, 2022 at 8:02 PM Werner Sembach <wse@tuxedocomputers.com> wrote: > > Clevo NL5xRU and NL5xNU/TUXEDO Aura 15 Gen1 and Gen2 have both a working > native and video interface. However the default detection mechanism first > registers the video interface before unregistering it again and switching > to the native interface during boot. This results in a dangling SBIOS > request for backlight change for some reason, causing the backlight to > switch to ~2% once per boot on the first power cord connect or disconnect > event. Setting the native interface explicitly circumvents this buggy > behaviour by avoiding the unregistering process. > > Signed-off-by: Werner Sembach <wse@tuxedocomputers.com> > Cc: stable@vger.kernel.org > --- > drivers/acpi/video_detect.c | 75 +++++++++++++++++++++++++++++++++++++ > 1 file changed, 75 insertions(+) > > diff --git a/drivers/acpi/video_detect.c b/drivers/acpi/video_detect.c > index 4f64713e9917..becc198e4c22 100644 > --- a/drivers/acpi/video_detect.c > +++ b/drivers/acpi/video_detect.c > @@ -415,6 +415,81 @@ static const struct dmi_system_id video_detect_dmi_table[] = { > DMI_MATCH(DMI_PRODUCT_NAME, "GA503"), > }, > }, > + /* > + * Clevo NL5xRU and NL5xNU/TUXEDO Aura 15 Gen1 and Gen2 have both a > + * working native and video interface. However the default detection > + * mechanism first registers the video interface before unregistering > + * it again and switching to the native interface during boot. This > + * results in a dangling SBIOS request for backlight change for some > + * reason, causing the backlight to switch to ~2% once per boot on the > + * first power cord connect or disconnect event. Setting the native > + * interface explicitly circumvents this buggy behaviour, by avoiding > + * the unregistering process. > + */ > + { > + .callback = video_detect_force_native, > + .ident = "Clevo NL5xRU", > + .matches = { > + DMI_MATCH(DMI_SYS_VENDOR, "TUXEDO"), > + DMI_MATCH(DMI_BOARD_NAME, "NL5xRU"), > + }, > + }, > + { > + .callback = video_detect_force_native, > + .ident = "Clevo NL5xRU", > + .matches = { > + DMI_MATCH(DMI_SYS_VENDOR, "SchenkerTechnologiesGmbH"), > + DMI_MATCH(DMI_BOARD_NAME, "NL5xRU"), > + }, > + }, > + { > + .callback = video_detect_force_native, > + .ident = "Clevo NL5xRU", > + .matches = { > + DMI_MATCH(DMI_SYS_VENDOR, "Notebook"), > + DMI_MATCH(DMI_BOARD_NAME, "NL5xRU"), > + }, > + }, > + { > + .callback = video_detect_force_native, > + .ident = "Clevo NL5xRU", > + .matches = { > + DMI_MATCH(DMI_SYS_VENDOR, "TUXEDO"), > + DMI_MATCH(DMI_BOARD_NAME, "AURA1501"), > + }, > + }, > + { > + .callback = video_detect_force_native, > + .ident = "Clevo NL5xRU", > + .matches = { > + DMI_MATCH(DMI_SYS_VENDOR, "TUXEDO"), > + DMI_MATCH(DMI_BOARD_NAME, "EDUBOOK1502"), > + }, > + }, > + { > + .callback = video_detect_force_native, > + .ident = "Clevo NL5xNU", > + .matches = { > + DMI_MATCH(DMI_SYS_VENDOR, "TUXEDO"), > + DMI_MATCH(DMI_BOARD_NAME, "NL5xNU"), > + }, > + }, > + { > + .callback = video_detect_force_native, > + .ident = "Clevo NL5xNU", > + .matches = { > + DMI_MATCH(DMI_SYS_VENDOR, "SchenkerTechnologiesGmbH"), > + DMI_MATCH(DMI_BOARD_NAME, "NL5xNU"), > + }, > + }, > + { > + .callback = video_detect_force_native, > + .ident = "Clevo NL5xNU", > + .matches = { > + DMI_MATCH(DMI_SYS_VENDOR, "Notebook"), > + DMI_MATCH(DMI_BOARD_NAME, "NL5xNU"), > + }, > + }, > > /* > * Desktops which falsely report a backlight and which our heuristics > -- Applied as 5.18 material, thanks! ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2022-03-17 13:31 UTC | newest] Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2022-03-15 19:02 [PATCH] ACPI/backlight: Force backlight native for Clevo NL5xRU and Werner Sembach 2022-03-15 19:02 ` [PATCH] ACPI/backlight: Force backlight native for Clevo NL5xRU and NL5xNU Werner Sembach 2022-03-17 13:30 ` Rafael J. Wysocki
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).