All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] ACPI: Add DMI quirk for Lenovo Yoga 9 (14INTL5)
@ 2021-08-24 12:57 Ulrich Huber
  2021-08-25 17:58 ` Rafael J. Wysocki
  0 siblings, 1 reply; 2+ messages in thread
From: Ulrich Huber @ 2021-08-24 12:57 UTC (permalink / raw)
  To: rjw, linux-acpi; +Cc: Ulrich Huber

The Lenovo Yoga 9 (14INTL5)'s ACPI _LID is bugged:

After hibernation the lid is initially reported as closed.
Once closing and then reopening the lid reports the lid as
open again. This leads to the conclusion that the initial
notification of the lid is missing but subsequent
notifications are correct.

In order fo the Linux LID code to handle this device properly
the lid_init_state must be set to ACPI_BUTTON_LID_INIT_OPEN.

Signed-off-by: Ulrich Huber <ulrich@huberulrich.de>
---
 drivers/acpi/button.c | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/drivers/acpi/button.c b/drivers/acpi/button.c
index f25bd336113b..1f9b9a4c38c7 100644
--- a/drivers/acpi/button.c
+++ b/drivers/acpi/button.c
@@ -77,6 +77,17 @@ static const struct dmi_system_id dmi_lid_quirks[] = {
 		},
 		.driver_data = (void *)(long)ACPI_BUTTON_LID_INIT_DISABLED,
 	},
+	{
+		/*
+		 * Lenovo Yoga 9 14ITL5, initial notification of the LID device
+		 * never happens.
+		 */
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
+			DMI_MATCH(DMI_PRODUCT_NAME, "82BG"),
+		},
+		.driver_data = (void *)(long)ACPI_BUTTON_LID_INIT_OPEN,
+	},
 	{
 		/*
 		 * Medion Akoya E2215T, notification of the LID device only
-- 
2.33.0


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] ACPI: Add DMI quirk for Lenovo Yoga 9 (14INTL5)
  2021-08-24 12:57 [PATCH] ACPI: Add DMI quirk for Lenovo Yoga 9 (14INTL5) Ulrich Huber
@ 2021-08-25 17:58 ` Rafael J. Wysocki
  0 siblings, 0 replies; 2+ messages in thread
From: Rafael J. Wysocki @ 2021-08-25 17:58 UTC (permalink / raw)
  To: Ulrich Huber; +Cc: Rafael J. Wysocki, ACPI Devel Maling List

On Tue, Aug 24, 2021 at 3:03 PM Ulrich Huber <ulrich@huberulrich.de> wrote:
>
> The Lenovo Yoga 9 (14INTL5)'s ACPI _LID is bugged:
>
> After hibernation the lid is initially reported as closed.
> Once closing and then reopening the lid reports the lid as
> open again. This leads to the conclusion that the initial
> notification of the lid is missing but subsequent
> notifications are correct.
>
> In order fo the Linux LID code to handle this device properly
> the lid_init_state must be set to ACPI_BUTTON_LID_INIT_OPEN.
>
> Signed-off-by: Ulrich Huber <ulrich@huberulrich.de>
> ---
>  drivers/acpi/button.c | 11 +++++++++++
>  1 file changed, 11 insertions(+)
>
> diff --git a/drivers/acpi/button.c b/drivers/acpi/button.c
> index f25bd336113b..1f9b9a4c38c7 100644
> --- a/drivers/acpi/button.c
> +++ b/drivers/acpi/button.c
> @@ -77,6 +77,17 @@ static const struct dmi_system_id dmi_lid_quirks[] = {
>                 },
>                 .driver_data = (void *)(long)ACPI_BUTTON_LID_INIT_DISABLED,
>         },
> +       {
> +               /*
> +                * Lenovo Yoga 9 14ITL5, initial notification of the LID device
> +                * never happens.
> +                */
> +               .matches = {
> +                       DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
> +                       DMI_MATCH(DMI_PRODUCT_NAME, "82BG"),
> +               },
> +               .driver_data = (void *)(long)ACPI_BUTTON_LID_INIT_OPEN,
> +       },
>         {
>                 /*
>                  * Medion Akoya E2215T, notification of the LID device only
> --

Applied as 5.15 material, thanks!

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-08-25 17:58 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-24 12:57 [PATCH] ACPI: Add DMI quirk for Lenovo Yoga 9 (14INTL5) Ulrich Huber
2021-08-25 17:58 ` Rafael J. Wysocki

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.