diff mbox series

Laptop internal keyboard not working on LG UltraPC 17U70P

Message ID jzqzwdedY4SnVMhKdJpA2nv5eA7o6COWGesAYO0Th3IXK2Pu2UoYfKlhd0YJhospEusFM-qmJG5Mzo-vGhE9VzVWebfqbyYlDdk7ZeDUXCI=@proton.me
State New
Headers show
Series Laptop internal keyboard not working on LG UltraPC 17U70P | expand

Commit Message

Rubén Gómez May 8, 2023, 6:03 p.m. UTC
Hi,

This patch, destined to the specific laptop model LG UltraPC 17U70P, solves an already known problem happening with some devices where the keyboard IRQ is handled with the ActiveLow attribute. The kernel currently ignores that, and as a consequence the internal keyboard stops responding as soon it loads up. This has been extensively discussed in bug 213031 [1]. From the work done there an ad hoc list was introduced in the kernel to handle those devices, as seems like other broader solutions would cause problems to other devices. This patch just adds this laptop model to that list. I filled a bug specifically for this laptop model with number 216983 [2]. Patch is already tested against commit 7163a2111f6c in the linux-pm branch.

[1] https://bugzilla.kernel.org/show_bug.cgi?id=213031
[2] https://bugzilla.kernel.org/show_bug.cgi?id=216983

Signed-off-by: Rubén Gómez Agudo <mrgommer@proton.me>
---

Comments

Rafael J. Wysocki May 15, 2023, 12:24 p.m. UTC | #1
On Mon, May 8, 2023 at 8:03 PM Rubén Gómez <mrgommer@proton.me> wrote:
>
> Hi,
>
> This patch, destined to the specific laptop model LG UltraPC 17U70P, solves an already known problem happening with some devices where the keyboard IRQ is handled with the ActiveLow attribute. The kernel currently ignores that, and as a consequence the internal keyboard stops responding as soon it loads up. This has been extensively discussed in bug 213031 [1]. From the work done there an ad hoc list was introduced in the kernel to handle those devices, as seems like other broader solutions would cause problems to other devices. This patch just adds this laptop model to that list. I filled a bug specifically for this laptop model with number 216983 [2]. Patch is already tested against commit 7163a2111f6c in the linux-pm branch.
>
> [1] https://bugzilla.kernel.org/show_bug.cgi?id=213031
> [2] https://bugzilla.kernel.org/show_bug.cgi?id=216983
>
> Signed-off-by: Rubén Gómez Agudo <mrgommer@proton.me>
> ---
> diff --git a/drivers/acpi/resource.c b/drivers/acpi/resource.c
> index e8492b3a393a..0800a9d77558 100644
> --- a/drivers/acpi/resource.c
> +++ b/drivers/acpi/resource.c
> @@ -516,6 +516,17 @@ static const struct dmi_system_id maingear_laptop[] = {
>         { }
>  };
>
> +static const struct dmi_system_id lg_laptop[] = {
> +       {
> +               .ident = "LG Electronics 17U70P",
> +               .matches = {
> +                       DMI_MATCH(DMI_SYS_VENDOR, "LG Electronics"),
> +                       DMI_MATCH(DMI_BOARD_NAME, "17U70P"),
> +               },
> +       },
> +       { }
> +};
> +
>  struct irq_override_cmp {
>         const struct dmi_system_id *system;
>         unsigned char irq;
> @@ -532,6 +543,7 @@ static const struct irq_override_cmp override_table[] = {
>         { lenovo_laptop, 10, ACPI_LEVEL_SENSITIVE, ACPI_ACTIVE_LOW, 0, true },
>         { tongfang_gm_rg, 1, ACPI_EDGE_SENSITIVE, ACPI_ACTIVE_LOW, 1, true },
>         { maingear_laptop, 1, ACPI_EDGE_SENSITIVE, ACPI_ACTIVE_LOW, 1, true },
> +       { lg_laptop, 1, ACPI_LEVEL_SENSITIVE, ACPI_ACTIVE_LOW, 0, false },
>  };
>
>  static bool acpi_dev_irq_override(u32 gsi, u8 triggering, u8 polarity,

Fixed up (new subject, new changelog, white space damage fixes) and
applied as 6.4-rc material.

Thanks!
diff mbox series

Patch

diff --git a/drivers/acpi/resource.c b/drivers/acpi/resource.c
index e8492b3a393a..0800a9d77558 100644
--- a/drivers/acpi/resource.c
+++ b/drivers/acpi/resource.c
@@ -516,6 +516,17 @@  static const struct dmi_system_id maingear_laptop[] = {
        { }
 };

+static const struct dmi_system_id lg_laptop[] = {
+       {
+               .ident = "LG Electronics 17U70P",
+               .matches = {
+                       DMI_MATCH(DMI_SYS_VENDOR, "LG Electronics"),
+                       DMI_MATCH(DMI_BOARD_NAME, "17U70P"),
+               },
+       },
+       { }
+};
+
 struct irq_override_cmp {
        const struct dmi_system_id *system;
        unsigned char irq;
@@ -532,6 +543,7 @@  static const struct irq_override_cmp override_table[] = {
        { lenovo_laptop, 10, ACPI_LEVEL_SENSITIVE, ACPI_ACTIVE_LOW, 0, true },
        { tongfang_gm_rg, 1, ACPI_EDGE_SENSITIVE, ACPI_ACTIVE_LOW, 1, true },
        { maingear_laptop, 1, ACPI_EDGE_SENSITIVE, ACPI_ACTIVE_LOW, 1, true },
+       { lg_laptop, 1, ACPI_LEVEL_SENSITIVE, ACPI_ACTIVE_LOW, 0, false },
 };

 static bool acpi_dev_irq_override(u32 gsi, u8 triggering, u8 polarity,