All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] platform/x86: touchscreen_dmi: Add TrekStor SurfTab duo W1 touchscreen info
@ 2021-11-24 17:51 Hans de Goede
  2021-11-25 15:36 ` Hans de Goede
  0 siblings, 1 reply; 2+ messages in thread
From: Hans de Goede @ 2021-11-24 17:51 UTC (permalink / raw)
  To: Mark Gross, Andy Shevchenko; +Cc: Hans de Goede, platform-driver-x86

The TrekStor SurfTab duo W1 (ST10432-10b) has a Goodix touchscreen which
has its x-axis mirrored.

Add a quirk to fix this.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
 drivers/platform/x86/touchscreen_dmi.c | 18 ++++++++++++++++++
 1 file changed, 18 insertions(+)

diff --git a/drivers/platform/x86/touchscreen_dmi.c b/drivers/platform/x86/touchscreen_dmi.c
index 8e7d42df02da..1c3d2dca420d 100644
--- a/drivers/platform/x86/touchscreen_dmi.c
+++ b/drivers/platform/x86/touchscreen_dmi.c
@@ -914,6 +914,16 @@ static const struct ts_dmi_data trekstor_primetab_t13b_data = {
 	.properties = trekstor_primetab_t13b_props,
 };
 
+static const struct property_entry trekstor_surftab_duo_w1_props[] = {
+	PROPERTY_ENTRY_BOOL("touchscreen-inverted-x"),
+	{ }
+};
+
+static const struct ts_dmi_data trekstor_surftab_duo_w1_data = {
+	.acpi_name	= "GDIX1001:00",
+	.properties	= trekstor_surftab_duo_w1_props,
+};
+
 static const struct property_entry trekstor_surftab_twin_10_1_props[] = {
 	PROPERTY_ENTRY_U32("touchscreen-min-x", 20),
 	PROPERTY_ENTRY_U32("touchscreen-min-y", 0),
@@ -1511,6 +1521,14 @@ const struct dmi_system_id touchscreen_dmi_table[] = {
 			DMI_MATCH(DMI_PRODUCT_NAME, "Primetab T13B"),
 		},
 	},
+	{
+		/* TrekStor SurfTab duo W1 10.1 ST10432-10b */
+		.driver_data = (void *)&trekstor_surftab_duo_w1_data,
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "TrekStor"),
+			DMI_MATCH(DMI_PRODUCT_NAME, "SurfTab duo W1 10.1 (VT4)"),
+		},
+	},
 	{
 		/* TrekStor SurfTab twin 10.1 ST10432-8 */
 		.driver_data = (void *)&trekstor_surftab_twin_10_1_data,
-- 
2.33.1


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

* Re: [PATCH] platform/x86: touchscreen_dmi: Add TrekStor SurfTab duo W1 touchscreen info
  2021-11-24 17:51 [PATCH] platform/x86: touchscreen_dmi: Add TrekStor SurfTab duo W1 touchscreen info Hans de Goede
@ 2021-11-25 15:36 ` Hans de Goede
  0 siblings, 0 replies; 2+ messages in thread
From: Hans de Goede @ 2021-11-25 15:36 UTC (permalink / raw)
  To: Mark Gross, Andy Shevchenko; +Cc: platform-driver-x86

Hi,

On 11/24/21 18:51, Hans de Goede wrote:
> The TrekStor SurfTab duo W1 (ST10432-10b) has a Goodix touchscreen which
> has its x-axis mirrored.
> 
> Add a quirk to fix this.
> 
> Signed-off-by: Hans de Goede <hdegoede@redhat.com>

I've added this patch to my review-hans branch now.

Regards,

Hans

> ---
>  drivers/platform/x86/touchscreen_dmi.c | 18 ++++++++++++++++++
>  1 file changed, 18 insertions(+)
> 
> diff --git a/drivers/platform/x86/touchscreen_dmi.c b/drivers/platform/x86/touchscreen_dmi.c
> index 8e7d42df02da..1c3d2dca420d 100644
> --- a/drivers/platform/x86/touchscreen_dmi.c
> +++ b/drivers/platform/x86/touchscreen_dmi.c
> @@ -914,6 +914,16 @@ static const struct ts_dmi_data trekstor_primetab_t13b_data = {
>  	.properties = trekstor_primetab_t13b_props,
>  };
>  
> +static const struct property_entry trekstor_surftab_duo_w1_props[] = {
> +	PROPERTY_ENTRY_BOOL("touchscreen-inverted-x"),
> +	{ }
> +};
> +
> +static const struct ts_dmi_data trekstor_surftab_duo_w1_data = {
> +	.acpi_name	= "GDIX1001:00",
> +	.properties	= trekstor_surftab_duo_w1_props,
> +};
> +
>  static const struct property_entry trekstor_surftab_twin_10_1_props[] = {
>  	PROPERTY_ENTRY_U32("touchscreen-min-x", 20),
>  	PROPERTY_ENTRY_U32("touchscreen-min-y", 0),
> @@ -1511,6 +1521,14 @@ const struct dmi_system_id touchscreen_dmi_table[] = {
>  			DMI_MATCH(DMI_PRODUCT_NAME, "Primetab T13B"),
>  		},
>  	},
> +	{
> +		/* TrekStor SurfTab duo W1 10.1 ST10432-10b */
> +		.driver_data = (void *)&trekstor_surftab_duo_w1_data,
> +		.matches = {
> +			DMI_MATCH(DMI_SYS_VENDOR, "TrekStor"),
> +			DMI_MATCH(DMI_PRODUCT_NAME, "SurfTab duo W1 10.1 (VT4)"),
> +		},
> +	},
>  	{
>  		/* TrekStor SurfTab twin 10.1 ST10432-8 */
>  		.driver_data = (void *)&trekstor_surftab_twin_10_1_data,
> 


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

end of thread, other threads:[~2021-11-25 15:38 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-11-24 17:51 [PATCH] platform/x86: touchscreen_dmi: Add TrekStor SurfTab duo W1 touchscreen info Hans de Goede
2021-11-25 15:36 ` Hans de Goede

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.