Skip to contentSkip to conversation

Input: goodix - fix inverted Y coordinate on SUPI S10

PATCH In review Yajat Kumar 2 participants 6 messages Dec 30, 2025 – Feb 17

Subsystems (5)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Input: goodix - fix inverted Y coordinate on SUPI S10

The touchscreen on the SUPI S10 reports inverted Y coordinates, causing touch input to be mirrored vertically relative to the display.

Add a DMI-based quirk to invert the Y coordinate on this device so that touch input matches the display orientation.

Tested on SUPI S10 tablet with Goodix touchscreen controller.

---
 drivers/input/touchscreen/goodix.c | 22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)
drivers/input/touchscreen/goodix.c +22 -0
index f8798d11ec03..d675a85a9312 100644
@@ -160,6 +160,22 @@ static const struct dmi_system_id inverted_x_screen[] = {
 	{}
 };
 
+/*
+ * Those tablets have their y coordinate inverted
+ */
+static const struct dmi_system_id inverted_y_screen[] = {
+#if defined(CONFIG_DMI) && defined(CONFIG_X86)
+	{
+		.ident = "SUPI S10",
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "SUPI"),
+			DMI_MATCH(DMI_PRODUCT_NAME, "S10")
+		},
+	},
+#endif
+	{}
+};
+
 /**
  * goodix_i2c_read - read data from a register of the i2c slave device.
  *
@@ -1212,6 +1228,12 @@ static int goodix_configure_dev(struct goodix_ts_data *ts)
 			"Applying 'inverted x screen' quirk\n");
 	}
 
+	if (dmi_check_system(inverted_y_screen)) {
+		ts->prop.invert_y = true;
+		dev_dbg(&ts->client->dev,
+			"Applying 'inverted y screen' quirk\n");
+	}
+
 	error = input_mt_init_slots(ts->input_dev, ts->max_touch_num,
 				    INPUT_MT_DIRECT | INPUT_MT_DROP_UNUSED);
 	if (error) {
Signature · 1 line
2.51.0
maintainer
#1 lore raw

Hi Yajat,

Quoted 9 lines · Yajat Kumar

The touchscreen on the SUPI S10 reports inverted Y coordinates, causing touch input to be mirrored vertically relative to the display.

Add a DMI-based quirk to invert the Y coordinate on this device so that touch input matches the display orientation.

Tested on SUPI S10 tablet with Goodix touchscreen controller.

Thank you for your patch. This kind of quirks really belong in drivers/platform/x86/touchscreen_dmi.c instead of in individual touchscreen drivers.

The inverted_x_screen[] DMI quirk is a left-over from before we moved these quirks to touchscreen_dmi.c and unfortunately we cannot move this because we've not been able to find someone to test this.

I've attached a patch which should fix the issue using touchscreen_dmi.c . Note you may need to change the GDIX1001 in the patch to GDIX1002, see "ls /sys/bus/i2c/devices" to see which ACPI HID your touchscreen is using.

Can you please test the attached patch ?

Regards,

Hans

Quoted 34 lines
---
 drivers/input/touchscreen/goodix.c | 22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)
drivers/input/touchscreen/goodix.c +16 -0
index f8798d11ec03..d675a85a9312 100644
@@ -160,6 +160,22 @@ static const struct dmi_system_id inverted_x_screen[] = {
 	{}
 };
 
+/*
+ * Those tablets have their y coordinate inverted
+ */
+static const struct dmi_system_id inverted_y_screen[] = {
+#if defined(CONFIG_DMI) && defined(CONFIG_X86)
+	{
+		.ident = "SUPI S10",
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "SUPI"),
+			DMI_MATCH(DMI_PRODUCT_NAME, "S10")
+		},
+	},
+#endif
+	{}
+};
+
 /**
  * goodix_i2c_read - read data from a register of the i2c slave device.
  *
@@ -1212,6 +1228,12 @@ static int goodix_configure_dev(struct goodix_ts_data *ts)
 			"Applying 'inverted x screen' quirk\n");
 	}

drivers/input/touchscreen/goodix.c static int goodix_configure_dev(struct goodix_ts_data *ts) · line 1239

Quoted 10 lines
drivers/input/touchscreen/goodix.c +6 -0
 
+	if (dmi_check_system(inverted_y_screen)) {
+		ts->prop.invert_y = true;
+		dev_dbg(&ts->client->dev,
+			"Applying 'inverted y screen' quirk\n");
+	}
+
 	error = input_mt_init_slots(ts->input_dev, ts->max_touch_num,
 				    INPUT_MT_DIRECT | INPUT_MT_DROP_UNUSED);
 	if (error) {

From 5df9d895db2ff3b3ec58a6b0c9c3a09d3c852b29 Mon Sep 17 00:00:00 2001
From: Hans de Goede <[email protected]>
Date: Sun, 11 Jan 2026 22:25:58 +0100
Subject: [PATCH] platform/x86: touchscreen_dmi: Add quirk for y-inverted
Goodix touchscreen on SUPI S10

The touchscreen on the SUPI S10 tablet reports inverted Y coordinates, causing touch input to be mirrored vertically relative to the display.

Add a quirk to set the "touchscreen-inverted-y" boolean device-property on the touchscreen device, so that the goodix_ts driver will fixup the coordinates.

---
 drivers/platform/x86/touchscreen_dmi.c | 18 ++++++++++++++++++
 1 file changed, 18 insertions(+)
drivers/platform/x86/touchscreen_dmi.c +18 -0
index bdc19cd8d3ed..d83c387821ea 100644
@@ -410,6 +410,16 @@ static const struct ts_dmi_data gdix1002_upside_down_data = {
 	.properties	= gdix1001_upside_down_props,
 };
 
+static const struct property_entry gdix1001_y_inverted_props[] = {
+	PROPERTY_ENTRY_BOOL("touchscreen-inverted-y"),
+	{ }
+};
+
+static const struct ts_dmi_data gdix1001_y_inverted_data = {
+	.acpi_name	= "GDIX1001",
+	.properties	= gdix1001_y_inverted_props,
+};
+
 static const struct property_entry gp_electronic_t701_props[] = {
 	PROPERTY_ENTRY_U32("touchscreen-size-x", 960),
 	PROPERTY_ENTRY_U32("touchscreen-size-y", 640),
@@ -1658,6 +1668,14 @@ const struct dmi_system_id touchscreen_dmi_table[] = {
 			DMI_MATCH(DMI_PRODUCT_SKU, "PN20170413488"),
 		},
 	},
+	{
+		/* SUPI S10 */
+		.driver_data = (void *)&gdix1001_y_inverted_data,
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "SUPI"),
+			DMI_MATCH(DMI_PRODUCT_NAME, "S10"),
+		},
+	},
 	{
 		/* Techbite Arc 11.6 */
 		.driver_data = (void *)&techbite_arc_11_6_data,
Signature · 1 line
2.52.0
author Tested-by
#2 lore raw

Subject: Re: [PATCH] touchscreen-dmi quirk for SUPI S10

Hi Hans,

I’ve tested the attached patch on the SUPI S10.

The touchscreen uses ACPI HID GDIX1001, so no change is needed there. With the patch applied, the Y axis is no longer inverted and touch input now matches the display orientation correctly.
You can add:

Thanks for the quick fix and explanation.

Regards,
Yajat Kumar

Quoted 79 lines · Hans de Goede

Hi Yajat,

Quoted 9 lines · Yajat Kumar

The touchscreen on the SUPI S10 reports inverted Y coordinates, causing touch input to be mirrored vertically relative to the display.

Add a DMI-based quirk to invert the Y coordinate on this device so that touch input matches the display orientation.

Tested on SUPI S10 tablet with Goodix touchscreen controller.

Thank you for your patch. This kind of quirks really belong in drivers/platform/x86/touchscreen_dmi.c instead of in individual touchscreen drivers.

The inverted_x_screen[] DMI quirk is a left-over from before we moved these quirks to touchscreen_dmi.c and unfortunately we cannot move this because we've not been able to find someone to test this.

I've attached a patch which should fix the issue using touchscreen_dmi.c . Note you may need to change the GDIX1001 in the patch to GDIX1002, see "ls /sys/bus/i2c/devices" to see which ACPI HID your touchscreen is using.

Can you please test the attached patch ?

Regards,

Hans

Quoted 44 lines
---
 drivers/input/touchscreen/goodix.c | 22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)
drivers/input/touchscreen/goodix.c +22 -0
index f8798d11ec03..d675a85a9312 100644
@@ -160,6 +160,22 @@ static const struct dmi_system_id inverted_x_screen[] = {
      {}
 };
 
+/*
+ * Those tablets have their y coordinate inverted
+ */
+static const struct dmi_system_id inverted_y_screen[] = {
+#if defined(CONFIG_DMI) && defined(CONFIG_X86)
+     {
+             .ident = "SUPI S10",
+             .matches = {
+                     DMI_MATCH(DMI_SYS_VENDOR, "SUPI"),
+                     DMI_MATCH(DMI_PRODUCT_NAME, "S10")
+             },
+     },
+#endif
+     {}
+};
+
 /**
  * goodix_i2c_read - read data from a register of the i2c slave device.
  *
@@ -1212,6 +1228,12 @@ static int goodix_configure_dev(struct goodix_ts_data *ts)
                      "Applying 'inverted x screen' quirk\n");
      }
 
+     if (dmi_check_system(inverted_y_screen)) {
+             ts->prop.invert_y = true;
+             dev_dbg(&ts->client->dev,
+                     "Applying 'inverted y screen' quirk\n");
+     }
+
      error = input_mt_init_slots(ts->input_dev, ts->max_touch_num,
                                  INPUT_MT_DIRECT | INPUT_MT_DROP_UNUSED);
      if (error) {
maintainer
#3 lore raw
In reply to Hans de Goede

Hi Yajat,

Quoted 21 lines · Hans de Goede

Hi Yajat,

Quoted 9 lines · Yajat Kumar

The touchscreen on the SUPI S10 reports inverted Y coordinates, causing touch input to be mirrored vertically relative to the display.

Add a DMI-based quirk to invert the Y coordinate on this device so that touch input matches the display orientation.

Tested on SUPI S10 tablet with Goodix touchscreen controller.

Thank you for your patch. This kind of quirks really belong in drivers/platform/x86/touchscreen_dmi.c instead of in individual touchscreen drivers.

The inverted_x_screen[] DMI quirk is a left-over from before we moved these quirks to touchscreen_dmi.c and unfortunately we cannot move this because we've not been able to find someone to test this.

Quoted 6 lines

I've attached a patch which should fix the issue using touchscreen_dmi.c . Note you may need to change the GDIX1001 in the patch to GDIX1002, see "ls /sys/bus/i2c/devices" to see which ACPI HID your touchscreen is using.

Can you please test the attached patch ?

Can you please confirm if the attached patch works, or at a minimum check if the touchscreen is listed as i2c-GDIX1001:* or i2c-GDIX1002:* under /sys/bus/i2c/devices ?

Regards,

Hans

Quoted 35 lines
Quoted 35 lines
---
 drivers/input/touchscreen/goodix.c | 22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)
drivers/input/touchscreen/goodix.c +16 -0
index f8798d11ec03..d675a85a9312 100644
@@ -160,6 +160,22 @@ static const struct dmi_system_id inverted_x_screen[] = {
 	{}
 };
 
+/*
+ * Those tablets have their y coordinate inverted
+ */
+static const struct dmi_system_id inverted_y_screen[] = {
+#if defined(CONFIG_DMI) && defined(CONFIG_X86)
+	{
+		.ident = "SUPI S10",
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "SUPI"),
+			DMI_MATCH(DMI_PRODUCT_NAME, "S10")
+		},
+	},
+#endif
+	{}
+};
+
 /**
  * goodix_i2c_read - read data from a register of the i2c slave device.
  *
@@ -1212,6 +1228,12 @@ static int goodix_configure_dev(struct goodix_ts_data *ts)
 			"Applying 'inverted x screen' quirk\n");
 	}
 
Quoted 9 lines

drivers/input/touchscreen/goodix.c static int goodix_configure_dev(struct goodix_ts_data *ts) · line 1239

Quoted 9 lines
drivers/input/touchscreen/goodix.c +6 -0
+	if (dmi_check_system(inverted_y_screen)) {
+		ts->prop.invert_y = true;
+		dev_dbg(&ts->client->dev,
+			"Applying 'inverted y screen' quirk\n");
+	}
+
 	error = input_mt_init_slots(ts->input_dev, ts->max_touch_num,
 				    INPUT_MT_DIRECT | INPUT_MT_DROP_UNUSED);
 	if (error) {

From 43aae0a5451031943836516ff541c9ab1232e6b9 Mon Sep 17 00:00:00 2001
From: Hans de Goede <[email protected]>
Date: Sun, 11 Jan 2026 22:25:58 +0100
Subject: [PATCH] platform/x86: touchscreen_dmi: Add quirk for y-inverted
Goodix touchscreen on SUPI S10

The touchscreen on the SUPI S10 tablet reports inverted Y coordinates, causing touch input to be mirrored vertically relative to the display.

Add a quirk to set the "touchscreen-inverted-y" boolean device-property on the touchscreen device, so that the goodix_ts driver will fixup the coordinates.

---
 drivers/platform/x86/touchscreen_dmi.c | 18 ++++++++++++++++++
 1 file changed, 18 insertions(+)
drivers/platform/x86/touchscreen_dmi.c +18 -0
index bdc19cd8d3ed..d83c387821ea 100644
@@ -410,6 +410,16 @@ static const struct ts_dmi_data gdix1002_upside_down_data = {
 	.properties	= gdix1001_upside_down_props,
 };
 
+static const struct property_entry gdix1001_y_inverted_props[] = {
+	PROPERTY_ENTRY_BOOL("touchscreen-inverted-y"),
+	{ }
+};
+
+static const struct ts_dmi_data gdix1001_y_inverted_data = {
+	.acpi_name	= "GDIX1001",
+	.properties	= gdix1001_y_inverted_props,
+};
+
 static const struct property_entry gp_electronic_t701_props[] = {
 	PROPERTY_ENTRY_U32("touchscreen-size-x", 960),
 	PROPERTY_ENTRY_U32("touchscreen-size-y", 640),
@@ -1658,6 +1668,14 @@ const struct dmi_system_id touchscreen_dmi_table[] = {
 			DMI_MATCH(DMI_PRODUCT_SKU, "PN20170413488"),
 		},
 	},
+	{
+		/* SUPI S10 */
+		.driver_data = (void *)&gdix1001_y_inverted_data,
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "SUPI"),
+			DMI_MATCH(DMI_PRODUCT_NAME, "S10"),
+		},
+	},
 	{
 		/* Techbite Arc 11.6 */
 		.driver_data = (void *)&techbite_arc_11_6_data,
Signature · 1 line
2.52.0
author Tested-by
#4 lore raw

Re: [PATCH] touchscreen-dmi quirk for SUPI S10

Hi Hans,

Sorry for the threading issue — Gmail broke my previous reply. Reposting confirmation below.

I’ve tested the attached patch on the SUPI S10.

The touchscreen uses ACPI HID GDIX1001, so no change is needed there. With the patch applied, the Y axis is no longer inverted and touch input now matches the display orientation correctly.
You can add:

Thanks for the quick fix and explanation.

Regards,
Yajat Kumar

maintainer
#5 lore raw

Re: [PATCH] touchscreen-dmi quirk for SUPI S10

Hi,

Quoted 6 lines · Yajat Kumar

Hi Hans,

Sorry for the threading issue — Gmail broke my previous reply. Reposting confirmation below.

I’ve tested the attached patch on the SUPI S10.

Quoted 8 lines

The touchscreen uses ACPI HID GDIX1001, so no change is needed there. With the patch applied, the Y axis is no longer inverted and touch input now matches the display orientation correctly.
You can add:

Thanks for the quick fix and explanation.

Thank you for testing. Now that its been confirmed this works I've posted the patch upstream:

https://lore.kernel.org/platform-driver-x86/[email protected]/

Regards,

Hans