]> git.itanic.dy.fi Git - linux-stable/commitdiff
platform/x86: touchscreen_dmi: Add upside-down quirk for GDIX1002 ts on the Juno...
authorHans de Goede <hdegoede@redhat.com>
Fri, 5 May 2023 21:03:23 +0000 (23:03 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 17 May 2023 09:50:22 +0000 (11:50 +0200)
commit 6abfa99ce52f61a31bcfc2aaaae09006f5665495 upstream.

The Juno Computers Juno Tablet has an upside-down mounted Goodix
touchscreen. Add a quirk to invert both axis to correct for this.

Link: https://junocomputers.com/us/product/juno-tablet/
Cc: stable@vger.kernel.org
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Link: https://lore.kernel.org/r/20230505210323.43177-1-hdegoede@redhat.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/platform/x86/touchscreen_dmi.c

index 69ba2c518261005b2788b7143091a8c9acf92496..8ac70819d1425781eb458ecbce32f1275e6e21d4 100644 (file)
@@ -381,6 +381,11 @@ static const struct ts_dmi_data glavey_tm800a550l_data = {
        .properties     = glavey_tm800a550l_props,
 };
 
+static const struct ts_dmi_data gdix1002_00_upside_down_data = {
+       .acpi_name      = "GDIX1002:00",
+       .properties     = gdix1001_upside_down_props,
+};
+
 static const struct property_entry gp_electronic_t701_props[] = {
        PROPERTY_ENTRY_U32("touchscreen-size-x", 960),
        PROPERTY_ENTRY_U32("touchscreen-size-y", 640),
@@ -1280,6 +1285,18 @@ const struct dmi_system_id touchscreen_dmi_table[] = {
                        DMI_MATCH(DMI_BIOS_VERSION, "jumperx.T87.KFBNEEA"),
                },
        },
+       {
+               /* Juno Tablet */
+               .driver_data = (void *)&gdix1002_00_upside_down_data,
+               .matches = {
+                       DMI_MATCH(DMI_SYS_VENDOR, "Default string"),
+                       /* Both product- and board-name being "Default string" is somewhat rare */
+                       DMI_MATCH(DMI_PRODUCT_NAME, "Default string"),
+                       DMI_MATCH(DMI_BOARD_NAME, "Default string"),
+                       /* Above matches are too generic, add partial bios-version match */
+                       DMI_MATCH(DMI_BIOS_VERSION, "JP2V1."),
+               },
+       },
        {
                /* Mediacom WinPad 7.0 W700 (same hw as Wintron surftab 7") */
                .driver_data = (void *)&trekstor_surftab_wintron70_data,