From patchwork Mon May 8 18:03:07 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?UnViw6luIEfDs21leg==?= X-Patchwork-Id: 680920 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 04131C77B7F for ; Mon, 8 May 2023 18:03:29 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229577AbjEHSD1 (ORCPT ); Mon, 8 May 2023 14:03:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54356 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232428AbjEHSD1 (ORCPT ); Mon, 8 May 2023 14:03:27 -0400 Received: from mail-0301.mail-europe.com (mail-0301.mail-europe.com [188.165.51.139]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id EF44AE5A for ; Mon, 8 May 2023 11:03:22 -0700 (PDT) Date: Mon, 08 May 2023 18:03:07 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=proton.me; s=protonmail; t=1683568993; x=1683828193; bh=tnQrUpBjZ5FWw23LcCAZJiqdu8dL9KhQ+9q8BrAIc88=; h=Date:To:From:Subject:Message-ID:Feedback-ID:From:To:Cc:Date: Subject:Reply-To:Feedback-ID:Message-ID:BIMI-Selector; b=WesZj9t/SdqGrmMkq/eotDjug9THB0eN/dClw1wgVQ56mZaxBQpxJsc/TYX8Mo8Mr wD3eRPP1FWpnvX7eU66T3DZ7NANTwQ4zVYUtebGxyHpqp2LNy/3JZa88h2xgkL43fx Lp7GjXqGVdruNmVE2xZaZFyfx073WBZaesr6BRL46y4a9dgD5WrV9UV3pTYPLO4aVD ERrx2mc5j8OpaXD+8fgAs3NY2Qw9PNPTZPZufeAPLqUf5qJIi6oZgdjItSj8vyR/K9 J0o9EhPy0EGL2PVJ/+EJ2y+H27YcsN0HbaT6Ad2hGDpNWhjEu6noXEVEl637cIwzgJ ACrTCyAxwOfUg== To: linux-acpi@vger.kernel.org From: =?utf-8?b?UnViw6luIEfDs21leg==?= Subject: [PATCH] Laptop internal keyboard not working on LG UltraPC 17U70P Message-ID: Feedback-ID: 66491317:user:proton MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-acpi@vger.kernel.org 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 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,