* [PATCH 1/5] dt-bindings: input: touchscreen: samsung,s6sy761: Introduce reset and mode-switch GPIOs
2026-12-04 22:13 [PATCH 0/5] Introduce Samsung S6SY761 (Google Pixel 3 XL) touchscreen Marco Mattiolo via B4 Relay
@ 2026-12-04 22:13 ` Marco Mattiolo via B4 Relay
2026-12-05 1:44 ` Dmitry Torokhov
2026-12-04 22:13 ` [PATCH 2/5] Input: s6sy761 - Add optional reset GPIO support Marco Mattiolo via B4 Relay
` (3 subsequent siblings)
4 siblings, 1 reply; 8+ messages in thread
From: Marco Mattiolo via B4 Relay @ 2026-12-04 22:13 UTC (permalink / raw)
To: Dmitry Torokhov, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Andi Shyti, Bjorn Andersson, Konrad Dybcio, Abel Vesa
Cc: linux-input, devicetree, linux-arm-msm, David Heidelberg,
Marco Mattiolo
From: Marco Mattiolo <marco.mattiolo@runbox.com>
Pixel 3 XL (google-crosshatch) features this touchscreen using reset and
mode-switch GPIO pins.
Suggested-by: David Heidelberg <david@ixit.cz>
Signed-off-by: Marco Mattiolo <marco.mattiolo@runbox.com>
---
.../devicetree/bindings/input/touchscreen/samsung,s6sy761.yaml | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/Documentation/devicetree/bindings/input/touchscreen/samsung,s6sy761.yaml b/Documentation/devicetree/bindings/input/touchscreen/samsung,s6sy761.yaml
index 1ffd17af3c53..6f9af51d8461 100644
--- a/Documentation/devicetree/bindings/input/touchscreen/samsung,s6sy761.yaml
+++ b/Documentation/devicetree/bindings/input/touchscreen/samsung,s6sy761.yaml
@@ -25,6 +25,16 @@ properties:
avdd-supply: true
vdd-supply: true
+ reset-gpios:
+ description: Reset GPIO (active-low)
+ maxItems: 1
+
+ mode-switch-gpios:
+ description:
+ Selects the I2C bus master on boards that share the touch bus between
+ the AP and the SLPI sensor DSP. Asserted gives the bus to the AP.
+ maxItems: 1
+
unevaluatedProperties: false
required:
--
2.53.0
^ permalink raw reply related [flat|nested] 8+ messages in thread* Re: [PATCH 1/5] dt-bindings: input: touchscreen: samsung,s6sy761: Introduce reset and mode-switch GPIOs
2026-12-04 22:13 ` [PATCH 1/5] dt-bindings: input: touchscreen: samsung,s6sy761: Introduce reset and mode-switch GPIOs Marco Mattiolo via B4 Relay
@ 2026-12-05 1:44 ` Dmitry Torokhov
0 siblings, 0 replies; 8+ messages in thread
From: Dmitry Torokhov @ 2026-12-05 1:44 UTC (permalink / raw)
To: marco.mattiolo
Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Andi Shyti,
Bjorn Andersson, Konrad Dybcio, Abel Vesa, linux-input,
devicetree, linux-arm-msm, David Heidelberg
Hi Marco,
On Fri, Dec 04, 2026 at 11:13:12PM +0100, Marco Mattiolo via B4 Relay wrote:
> From: Marco Mattiolo <marco.mattiolo@runbox.com>
>
> Pixel 3 XL (google-crosshatch) features this touchscreen using reset and
> mode-switch GPIO pins.
>
> Suggested-by: David Heidelberg <david@ixit.cz>
> Signed-off-by: Marco Mattiolo <marco.mattiolo@runbox.com>
> ---
> .../devicetree/bindings/input/touchscreen/samsung,s6sy761.yaml | 10 ++++++++++
> 1 file changed, 10 insertions(+)
>
> diff --git a/Documentation/devicetree/bindings/input/touchscreen/samsung,s6sy761.yaml b/Documentation/devicetree/bindings/input/touchscreen/samsung,s6sy761.yaml
> index 1ffd17af3c53..6f9af51d8461 100644
> --- a/Documentation/devicetree/bindings/input/touchscreen/samsung,s6sy761.yaml
> +++ b/Documentation/devicetree/bindings/input/touchscreen/samsung,s6sy761.yaml
> @@ -25,6 +25,16 @@ properties:
> avdd-supply: true
> vdd-supply: true
>
> + reset-gpios:
> + description: Reset GPIO (active-low)
> + maxItems: 1
> +
> + mode-switch-gpios:
> + description:
> + Selects the I2C bus master on boards that share the touch bus between
> + the AP and the SLPI sensor DSP. Asserted gives the bus to the AP.
> + maxItems: 1
Does this really belong to the touch controller binding? This seems a
board quirk, completely independent from the touch controller.
Maybe pinctrl can be leveraged here somehow?
Thanks.
--
Dmitry
^ permalink raw reply [flat|nested] 8+ messages in thread
* [PATCH 2/5] Input: s6sy761 - Add optional reset GPIO support
2026-12-04 22:13 [PATCH 0/5] Introduce Samsung S6SY761 (Google Pixel 3 XL) touchscreen Marco Mattiolo via B4 Relay
2026-12-04 22:13 ` [PATCH 1/5] dt-bindings: input: touchscreen: samsung,s6sy761: Introduce reset and mode-switch GPIOs Marco Mattiolo via B4 Relay
@ 2026-12-04 22:13 ` Marco Mattiolo via B4 Relay
2026-12-04 22:13 ` [PATCH 3/5] Input: s6sy761 - Add mode-switch support Marco Mattiolo via B4 Relay
` (2 subsequent siblings)
4 siblings, 0 replies; 8+ messages in thread
From: Marco Mattiolo via B4 Relay @ 2026-12-04 22:13 UTC (permalink / raw)
To: Dmitry Torokhov, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Andi Shyti, Bjorn Andersson, Konrad Dybcio, Abel Vesa
Cc: linux-input, devicetree, linux-arm-msm, David Heidelberg,
Marco Mattiolo
From: Marco Mattiolo <marco.mattiolo@runbox.com>
Add support for an optional "reset-gpios" property. If present, the
controller is held in reset from probe until its supplies are enabled,
released before the existing 140 ms boot wait, and put back into reset
before the supplies are disabled.
Suggested-by: David Heidelberg <david@ixit.cz>
Signed-off-by: Marco Mattiolo <marco.mattiolo@runbox.com>
---
drivers/input/touchscreen/s6sy761.c | 11 +++++++++++
1 file changed, 11 insertions(+)
diff --git a/drivers/input/touchscreen/s6sy761.c b/drivers/input/touchscreen/s6sy761.c
index c6cc5cba577a..5972a3194a7d 100644
--- a/drivers/input/touchscreen/s6sy761.c
+++ b/drivers/input/touchscreen/s6sy761.c
@@ -6,6 +6,7 @@
#include <linux/unaligned.h>
#include <linux/delay.h>
+#include <linux/gpio/consumer.h>
#include <linux/i2c.h>
#include <linux/input/mt.h>
#include <linux/input/touchscreen.h>
@@ -102,6 +103,7 @@ struct s6sy761_data {
struct i2c_client *client;
struct regulator_bulk_data regulators[2];
struct input_dev *input;
+ struct gpio_desc *reset_gpio;
struct touchscreen_properties prop;
u8 data[S6SY761_EVENT_SIZE * S6SY761_EVENT_COUNT];
@@ -301,6 +303,8 @@ static int s6sy761_power_on(struct s6sy761_data *sdata)
if (ret)
return ret;
+ /* release the optional reset line, then wait for the boot */
+ gpiod_set_value_cansleep(sdata->reset_gpio, 0);
msleep(140);
/* double check whether the touch is functional */
@@ -395,6 +399,7 @@ static void s6sy761_power_off(void *data)
if (!sdata->powered_up)
return;
+ gpiod_set_value_cansleep(sdata->reset_gpio, 1);
regulator_bulk_disable(ARRAY_SIZE(sdata->regulators), sdata->regulators);
sdata->powered_up = false;
}
@@ -425,6 +430,12 @@ static int s6sy761_probe(struct i2c_client *client)
if (err)
return err;
+ sdata->reset_gpio = devm_gpiod_get_optional(&client->dev, "reset",
+ GPIOD_OUT_HIGH);
+ if (IS_ERR(sdata->reset_gpio))
+ return dev_err_probe(&client->dev, PTR_ERR(sdata->reset_gpio),
+ "Failed to get reset GPIO\n");
+
err = devm_add_action_or_reset(&client->dev, s6sy761_power_off, sdata);
if (err)
return err;
--
2.53.0
^ permalink raw reply related [flat|nested] 8+ messages in thread* [PATCH 3/5] Input: s6sy761 - Add mode-switch support
2026-12-04 22:13 [PATCH 0/5] Introduce Samsung S6SY761 (Google Pixel 3 XL) touchscreen Marco Mattiolo via B4 Relay
2026-12-04 22:13 ` [PATCH 1/5] dt-bindings: input: touchscreen: samsung,s6sy761: Introduce reset and mode-switch GPIOs Marco Mattiolo via B4 Relay
2026-12-04 22:13 ` [PATCH 2/5] Input: s6sy761 - Add optional reset GPIO support Marco Mattiolo via B4 Relay
@ 2026-12-04 22:13 ` Marco Mattiolo via B4 Relay
2026-12-04 22:13 ` [PATCH 4/5] arm64: dts: qcom: sdm845-google: Group touchscreen pins, add mode-switch pin Marco Mattiolo via B4 Relay
2026-12-04 22:13 ` [PATCH 5/5] arm64: dts: qcom: sdm845-google-crosshatch: Add touchscreen support Marco Mattiolo via B4 Relay
4 siblings, 0 replies; 8+ messages in thread
From: Marco Mattiolo via B4 Relay @ 2026-12-04 22:13 UTC (permalink / raw)
To: Dmitry Torokhov, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Andi Shyti, Bjorn Andersson, Konrad Dybcio, Abel Vesa
Cc: linux-input, devicetree, linux-arm-msm, David Heidelberg,
Marco Mattiolo
From: Marco Mattiolo <marco.mattiolo@runbox.com>
On the Pixel 3 XL the touch I2C bus can be driven either by the AP or
by the SLPI sensor DSP, selected by a GPIO. Take the optional
"mode-switch-gpios" line and assert it at probe, before the first I2C
access, so the AP owns the bus. Handing the bus back to the SLPI for
low-power touch is not supported.
Suggested-by: David Heidelberg <david@ixit.cz>
Signed-off-by: Marco Mattiolo <marco.mattiolo@runbox.com>
---
drivers/input/touchscreen/s6sy761.c | 11 +++++++++++
1 file changed, 11 insertions(+)
diff --git a/drivers/input/touchscreen/s6sy761.c b/drivers/input/touchscreen/s6sy761.c
index 5972a3194a7d..7f2730e30699 100644
--- a/drivers/input/touchscreen/s6sy761.c
+++ b/drivers/input/touchscreen/s6sy761.c
@@ -407,6 +407,7 @@ static void s6sy761_power_off(void *data)
static int s6sy761_probe(struct i2c_client *client)
{
struct s6sy761_data *sdata;
+ struct gpio_desc *gpiod;
unsigned int max_x, max_y;
int err;
@@ -436,6 +437,16 @@ static int s6sy761_probe(struct i2c_client *client)
return dev_err_probe(&client->dev, PTR_ERR(sdata->reset_gpio),
"Failed to get reset GPIO\n");
+ /*
+ * Some boards share the touch I2C bus between the AP and the SLPI
+ * sensor DSP; make the AP the bus master before talking to the chip.
+ */
+ gpiod = devm_gpiod_get_optional(&client->dev, "mode-switch",
+ GPIOD_OUT_HIGH);
+ if (IS_ERR(gpiod))
+ return dev_err_probe(&client->dev, PTR_ERR(gpiod),
+ "Failed to get mode-switch GPIO\n");
+
err = devm_add_action_or_reset(&client->dev, s6sy761_power_off, sdata);
if (err)
return err;
--
2.53.0
^ permalink raw reply related [flat|nested] 8+ messages in thread* [PATCH 4/5] arm64: dts: qcom: sdm845-google: Group touchscreen pins, add mode-switch pin
2026-12-04 22:13 [PATCH 0/5] Introduce Samsung S6SY761 (Google Pixel 3 XL) touchscreen Marco Mattiolo via B4 Relay
` (2 preceding siblings ...)
2026-12-04 22:13 ` [PATCH 3/5] Input: s6sy761 - Add mode-switch support Marco Mattiolo via B4 Relay
@ 2026-12-04 22:13 ` Marco Mattiolo via B4 Relay
2026-12-04 22:32 ` David Heidelberg
2026-12-04 22:13 ` [PATCH 5/5] arm64: dts: qcom: sdm845-google-crosshatch: Add touchscreen support Marco Mattiolo via B4 Relay
4 siblings, 1 reply; 8+ messages in thread
From: Marco Mattiolo via B4 Relay @ 2026-12-04 22:13 UTC (permalink / raw)
To: Dmitry Torokhov, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Andi Shyti, Bjorn Andersson, Konrad Dybcio, Abel Vesa
Cc: linux-input, devicetree, linux-arm-msm, David Heidelberg,
Marco Mattiolo
From: Marco Mattiolo <marco.mattiolo@runbox.com>
Pixel 3 and Pixel 3 XL use different touchscreen controllers on the same
pins: reset on gpio99, interrupt on gpio125, and the AP/SLPI I2C bus
switch on gpio136. Move the reset and interrupt pin configuration into a
single touchscreen-default-state, add the switch pin to it, and use the
grouped state on blueline.
Suggested-by: David Heidelberg <david@ixit.cz>
Signed-off-by: Marco Mattiolo <marco.mattiolo@runbox.com>
---
.../arm64/boot/dts/qcom/sdm845-google-blueline.dts | 19 ++++++++++++-
arch/arm64/boot/dts/qcom/sdm845-google-common.dtsi | 31 ++++++++++++++--------
2 files changed, 38 insertions(+), 12 deletions(-)
diff --git a/arch/arm64/boot/dts/qcom/sdm845-google-blueline.dts b/arch/arm64/boot/dts/qcom/sdm845-google-blueline.dts
index a000c75494f1..a412d2e93850 100644
--- a/arch/arm64/boot/dts/qcom/sdm845-google-blueline.dts
+++ b/arch/arm64/boot/dts/qcom/sdm845-google-blueline.dts
@@ -26,7 +26,24 @@ &i2c2 {
status = "okay";
- /* ST,FTS @ 49 */
+ touchscreen@49 {
+ compatible = "st,stmfts5";
+ reg = <0x49>;
+
+ pinctrl-0 = <&touchscreen_default>;
+ pinctrl-names = "default";
+
+ interrupts-extended = <&tlmm 125 IRQ_TYPE_LEVEL_LOW>;
+
+ mode-switch-gpios = <&tlmm 136 GPIO_ACTIVE_HIGH>;
+ reset-gpios = <&tlmm 99 GPIO_ACTIVE_LOW>;
+
+ avdd-supply = <&vreg_l19a_3p3>;
+ vdd-supply = <&vreg_l14a_1p8>;
+
+ touchscreen-size-x = <1080>;
+ touchscreen-size-y = <2160>;
+ };
};
&mdss_dsi0 {
diff --git a/arch/arm64/boot/dts/qcom/sdm845-google-common.dtsi b/arch/arm64/boot/dts/qcom/sdm845-google-common.dtsi
index 3c9656b88b69..a706efec1b10 100644
--- a/arch/arm64/boot/dts/qcom/sdm845-google-common.dtsi
+++ b/arch/arm64/boot/dts/qcom/sdm845-google-common.dtsi
@@ -523,18 +523,27 @@ firmware-pins {
};
- touchscreen_reset: ts-reset-state {
- pins = "gpio99";
- function = "gpio";
- drive-strength = <8>;
- bias-pull-up;
- };
+ touchscreen_default: touchscreen-default-state {
+ reset-pins {
+ pins = "gpio99";
+ function = "gpio";
+ drive-strength = <8>;
+ bias-pull-up;
+ };
+
+ irq-pins {
+ pins = "gpio125";
+ function = "gpio";
+ drive-strength = <2>;
+ bias-disable;
+ };
- touchscreen_pins: ts-pins-gpio-state {
- pins = "gpio125";
- function = "gpio";
- drive-strength = <2>;
- bias-disable;
+ switch-pins {
+ pins = "gpio136";
+ function = "gpio";
+ drive-strength = <2>;
+ bias-disable;
+ };
};
};
--
2.53.0
^ permalink raw reply related [flat|nested] 8+ messages in thread* Re: [PATCH 4/5] arm64: dts: qcom: sdm845-google: Group touchscreen pins, add mode-switch pin
2026-12-04 22:13 ` [PATCH 4/5] arm64: dts: qcom: sdm845-google: Group touchscreen pins, add mode-switch pin Marco Mattiolo via B4 Relay
@ 2026-12-04 22:32 ` David Heidelberg
0 siblings, 0 replies; 8+ messages in thread
From: David Heidelberg @ 2026-12-04 22:32 UTC (permalink / raw)
To: marco.mattiolo, Dmitry Torokhov, Rob Herring, Krzysztof Kozlowski,
Conor Dooley, Andi Shyti, Bjorn Andersson, Konrad Dybcio,
Abel Vesa
Cc: linux-input, devicetree, linux-arm-msm
On 04/12/2026 23:13, Marco Mattiolo via B4 Relay wrote:
> From: Marco Mattiolo <marco.mattiolo@runbox.com>
>
> Pixel 3 and Pixel 3 XL use different touchscreen controllers on the same
> pins: reset on gpio99, interrupt on gpio125, and the AP/SLPI I2C bus
> switch on gpio136. Move the reset and interrupt pin configuration into a
> single touchscreen-default-state, add the switch pin to it, and use the
> grouped state on blueline.
>
> Suggested-by: David Heidelberg <david@ixit.cz>
> Signed-off-by: Marco Mattiolo <marco.mattiolo@runbox.com>
> ---
> .../arm64/boot/dts/qcom/sdm845-google-blueline.dts | 19 ++++++++++++-
> arch/arm64/boot/dts/qcom/sdm845-google-common.dtsi | 31 ++++++++++++++--------
> 2 files changed, 38 insertions(+), 12 deletions(-)
>
> diff --git a/arch/arm64/boot/dts/qcom/sdm845-google-blueline.dts b/arch/arm64/boot/dts/qcom/sdm845-google-blueline.dts
> index a000c75494f1..a412d2e93850 100644
> --- a/arch/arm64/boot/dts/qcom/sdm845-google-blueline.dts
> +++ b/arch/arm64/boot/dts/qcom/sdm845-google-blueline.dts
> @@ -26,7 +26,24 @@ &i2c2 {
>
> status = "okay";
>
> - /* ST,FTS @ 49 */
> + touchscreen@49 {
> + compatible = "st,stmfts5";
> + reg = <0x49>;
> +
> + pinctrl-0 = <&touchscreen_default>;
> + pinctrl-names = "default";
> +
> + interrupts-extended = <&tlmm 125 IRQ_TYPE_LEVEL_LOW>;
> +
> + mode-switch-gpios = <&tlmm 136 GPIO_ACTIVE_HIGH>;
> + reset-gpios = <&tlmm 99 GPIO_ACTIVE_LOW>;
> +
> + avdd-supply = <&vreg_l19a_3p3>;
> + vdd-supply = <&vreg_l14a_1p8>;
> +
> + touchscreen-size-x = <1080>;
> + touchscreen-size-y = <2160>;
> + };
It seems that during the rebases you accidentally included the stmfts5 changes,
which I sent as a separate change. Sadly these are not yet merged (but should be
unblocked now).
[PATCH v8 5/5] arm64: dts: qcom: sdm845-google: Add STM FTS touchscreen support
David
^ permalink raw reply [flat|nested] 8+ messages in thread
* [PATCH 5/5] arm64: dts: qcom: sdm845-google-crosshatch: Add touchscreen support
2026-12-04 22:13 [PATCH 0/5] Introduce Samsung S6SY761 (Google Pixel 3 XL) touchscreen Marco Mattiolo via B4 Relay
` (3 preceding siblings ...)
2026-12-04 22:13 ` [PATCH 4/5] arm64: dts: qcom: sdm845-google: Group touchscreen pins, add mode-switch pin Marco Mattiolo via B4 Relay
@ 2026-12-04 22:13 ` Marco Mattiolo via B4 Relay
4 siblings, 0 replies; 8+ messages in thread
From: Marco Mattiolo via B4 Relay @ 2026-12-04 22:13 UTC (permalink / raw)
To: Dmitry Torokhov, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Andi Shyti, Bjorn Andersson, Konrad Dybcio, Abel Vesa
Cc: linux-input, devicetree, linux-arm-msm, David Heidelberg,
Marco Mattiolo
From: Marco Mattiolo <marco.mattiolo@runbox.com>
Add support for the Samsung S6SY761X touchscreen controller connected
on I2C bus.
Suggested-by: David Heidelberg <david@ixit.cz>
Signed-off-by: Marco Mattiolo <marco.mattiolo@runbox.com>
---
.../boot/dts/qcom/sdm845-google-crosshatch.dts | 23 +++++++++++++++++++---
1 file changed, 20 insertions(+), 3 deletions(-)
diff --git a/arch/arm64/boot/dts/qcom/sdm845-google-crosshatch.dts b/arch/arm64/boot/dts/qcom/sdm845-google-crosshatch.dts
index 2a81ca1d00b1..7550a0b1041d 100644
--- a/arch/arm64/boot/dts/qcom/sdm845-google-crosshatch.dts
+++ b/arch/arm64/boot/dts/qcom/sdm845-google-crosshatch.dts
@@ -26,9 +26,26 @@ &framebuffer0 {
stride = <(1440 * 4)>;
};
-&mdss {
- /* Disable for now so simple-framebuffer continues working */
- status = "disabled";
+&i2c2 {
+ clock-frequency = <400000>;
+
+ status = "okay";
+
+ touchscreen@48 {
+ compatible = "samsung,s6sy761";
+ reg = <0x48>;
+
+ interrupts-extended = <&tlmm 125 IRQ_TYPE_LEVEL_LOW>;
+
+ pinctrl-0 = <&touchscreen_default>;
+ pinctrl-names = "default";
+
+ reset-gpios = <&tlmm 99 GPIO_ACTIVE_LOW>;
+ mode-switch-gpios = <&tlmm 136 GPIO_ACTIVE_HIGH>;
+
+ avdd-supply = <&vreg_l19a_3p3>;
+ vdd-supply = <&vreg_l14a_1p8>;
+ };
};
&wifi {
--
2.53.0
^ permalink raw reply related [flat|nested] 8+ messages in thread