public inbox for linux-input@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH v4 0/2] Input: st1232 - add system wakeup support
@ 2026-03-09  0:03 phucduc.bui
  2026-03-09  0:03 ` [PATCH v4 1/2] dt-bindings: input: touchscreen: sitronix,st1232: Add wakeup-source phucduc.bui
                   ` (2 more replies)
  0 siblings, 3 replies; 10+ messages in thread
From: phucduc.bui @ 2026-03-09  0:03 UTC (permalink / raw)
  To: krzk+dt, geert+renesas
  Cc: krzk, krzysztof.kozlowski, conor+dt, devicetree, dmitry.torokhov,
	hechtb, javier.carrasco, jeff, phucduc.bui, linux-input,
	linux-kernel, linux-renesas-soc, magnus.damm, robh, wsa+renesas

From: bui duc phuc <phucduc.bui@gmail.com>

This patch series adds support for using the Sitronix ST1232
touchscreen as a wakeup source on the Armadillo800EVA board.

Patch 1 documents the generic wakeup-source property in the
Devicetree binding for the ST1232 touchscreen controller.

Patch 2 enables the wakeup-source property in the ST1232
touchscreen node for the Armadillo800EVA board, allowing touch
events to wake the system from suspend.

Verified functionality

* The "power/wakeup" sysfs attribute is present for the device.
* The system resumes correctly from 'mem' and 'freeze' states when the
  touchscreen is touched.

Additional test information

Demo video showing wakeup from suspend:
https://youtu.be/POJhbguiA7A

Kernel config and boot logs:
https://gist.github.com/BuiDucPhuc/ac7d5d732658ca293af4323ad04accca

Changes in v4:
*Drop patch 3 as the I2C core already performs the initialization, 
 registration, and management of the wakeup interrupt, making the 
 implementation in the driver redundant.
 The original intention of patch 3 was to expose active_count, 
 event_count, and wakeup_count to user space. However, this is not 
 necessary since the R8A7740 SoC has some specific characteristics 
 in its wakeup interrupt handling.
 Moreover, modifying this driver could potentially affect other SoCs 
 sharing the same driver, so the patch is removed.
*Going back to v1 design.
*Update the cover letter

Changes in v3:
* Patch 3: Removed debug dev_info() log messages for a cleaner
  production-ready implementation.
* No changes to Patch 1 and Patch 2.
* Link : 
  https://lore.kernel.org/all/20260306111912.58388-1-phucduc.bui@gmail.com/
  

Changes in v2
* Drop description for wakeup-source property as suggested by
  Krzysztof Kozlowski.
* Updated commit messages for clarity.
* Added driver-side wakeup handling in st1232.c.
* Link : 
  https://lore.kernel.org/all/20260306104025.43970-1-phucduc.bui@gmail.com/

v1 
 *Link: 
  https://lore.kernel.org/all/20260305113512.227269-1-phucduc.bui@gmail.com/

This series depends on the following patch which has been
submitted but not yet merged:

drm: shmobile: Fix blank screen after resume when LCDC is stopped
Link: https://lore.kernel.org/all/20260226054035.30330-1-phucduc.bui@gmail.com/



bui duc phuc (2):
  dt-bindings: input: touchscreen: sitronix,st1232: Add wakeup-source
  arm: dts: renesas: r8a7740-armadillo800eva: Add wakeup-source to
    st1232

 .../bindings/input/touchscreen/sitronix,st1232.yaml           | 4 ++++
 arch/arm/boot/dts/renesas/r8a7740-armadillo800eva.dts         | 1 +
 2 files changed, 5 insertions(+)

-- 
2.43.0


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

* [PATCH v4 1/2] dt-bindings: input: touchscreen: sitronix,st1232: Add wakeup-source
  2026-03-09  0:03 [PATCH v4 0/2] Input: st1232 - add system wakeup support phucduc.bui
@ 2026-03-09  0:03 ` phucduc.bui
  2026-03-10 23:35   ` Dmitry Torokhov
  2026-03-09  0:03 ` [PATCH v4 2/2] arm: dts: renesas: r8a7740-armadillo800eva: Add wakeup-source to st1232 phucduc.bui
  2026-03-10 23:09 ` [PATCH v4 0/2] Input: st1232 - add system wakeup support Wolfram Sang
  2 siblings, 1 reply; 10+ messages in thread
From: phucduc.bui @ 2026-03-09  0:03 UTC (permalink / raw)
  To: krzk+dt, geert+renesas
  Cc: krzk, krzysztof.kozlowski, conor+dt, devicetree, dmitry.torokhov,
	hechtb, javier.carrasco, jeff, phucduc.bui, linux-input,
	linux-kernel, linux-renesas-soc, magnus.damm, robh, wsa+renesas

From: bui duc phuc <phucduc.bui@gmail.com>

Document the 'wakeup-source' property for Sitronix ST1232 touchscreen
controllers to allow the device to wake the system from suspend.

Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
Signed-off-by: bui duc phuc <phucduc.bui@gmail.com>
---
 .../bindings/input/touchscreen/sitronix,st1232.yaml           | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/Documentation/devicetree/bindings/input/touchscreen/sitronix,st1232.yaml b/Documentation/devicetree/bindings/input/touchscreen/sitronix,st1232.yaml
index 978afaa4fcef..fe1fa217d842 100644
--- a/Documentation/devicetree/bindings/input/touchscreen/sitronix,st1232.yaml
+++ b/Documentation/devicetree/bindings/input/touchscreen/sitronix,st1232.yaml
@@ -32,6 +32,9 @@ properties:
     description: A phandle to the reset GPIO
     maxItems: 1
 
+  wakeup-source:
+    type: boolean
+
 required:
   - compatible
   - reg
@@ -51,6 +54,7 @@ examples:
                     reg = <0x55>;
                     interrupts = <2 0>;
                     gpios = <&gpio1 166 0>;
+                    wakeup-source;
 
                     touch-overlay {
                             segment-0 {
-- 
2.43.0


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

* [PATCH v4 2/2] arm: dts: renesas: r8a7740-armadillo800eva: Add wakeup-source to st1232
  2026-03-09  0:03 [PATCH v4 0/2] Input: st1232 - add system wakeup support phucduc.bui
  2026-03-09  0:03 ` [PATCH v4 1/2] dt-bindings: input: touchscreen: sitronix,st1232: Add wakeup-source phucduc.bui
@ 2026-03-09  0:03 ` phucduc.bui
  2026-03-10 23:08   ` Wolfram Sang
  2026-03-13  8:41   ` [PATCH v4 2/2] arm: dts: renesas: r8a7740-armadillo800eva: Add wakeup-source to st1232 Geert Uytterhoeven
  2026-03-10 23:09 ` [PATCH v4 0/2] Input: st1232 - add system wakeup support Wolfram Sang
  2 siblings, 2 replies; 10+ messages in thread
From: phucduc.bui @ 2026-03-09  0:03 UTC (permalink / raw)
  To: krzk+dt, geert+renesas
  Cc: krzk, krzysztof.kozlowski, conor+dt, devicetree, dmitry.torokhov,
	hechtb, javier.carrasco, jeff, phucduc.bui, linux-input,
	linux-kernel, linux-renesas-soc, magnus.damm, robh, wsa+renesas

From: bui duc phuc <phucduc.bui@gmail.com>

Add the wakeup-source property to the ST1232 touchscreen node
in the device tree so that the touchscreen interrupt can wake
the system from suspend when the panel is touched.

Signed-off-by: bui duc phuc <phucduc.bui@gmail.com>
---
 arch/arm/boot/dts/renesas/r8a7740-armadillo800eva.dts | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm/boot/dts/renesas/r8a7740-armadillo800eva.dts b/arch/arm/boot/dts/renesas/r8a7740-armadillo800eva.dts
index 04d24b6d8056..d47a6cc3e756 100644
--- a/arch/arm/boot/dts/renesas/r8a7740-armadillo800eva.dts
+++ b/arch/arm/boot/dts/renesas/r8a7740-armadillo800eva.dts
@@ -228,6 +228,7 @@ touchscreen@55 {
 		pinctrl-0 = <&st1232_pins>;
 		pinctrl-names = "default";
 		gpios = <&pfc 166 GPIO_ACTIVE_LOW>;
+		wakeup-source;
 	};
 };
 
-- 
2.43.0


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

* Re: [PATCH v4 2/2] arm: dts: renesas: r8a7740-armadillo800eva: Add wakeup-source to st1232
  2026-03-09  0:03 ` [PATCH v4 2/2] arm: dts: renesas: r8a7740-armadillo800eva: Add wakeup-source to st1232 phucduc.bui
@ 2026-03-10 23:08   ` Wolfram Sang
  2026-03-11  4:22     ` [PATCH v4 2/2] arm: dts: renesas: r8a7740-armadillo800eva: phucduc.bui
  2026-03-13  8:41   ` [PATCH v4 2/2] arm: dts: renesas: r8a7740-armadillo800eva: Add wakeup-source to st1232 Geert Uytterhoeven
  1 sibling, 1 reply; 10+ messages in thread
From: Wolfram Sang @ 2026-03-10 23:08 UTC (permalink / raw)
  To: phucduc.bui
  Cc: krzk+dt, geert+renesas, krzk, krzysztof.kozlowski, conor+dt,
	devicetree, dmitry.torokhov, hechtb, javier.carrasco, jeff,
	linux-input, linux-kernel, linux-renesas-soc, magnus.damm, robh

[-- Attachment #1: Type: text/plain, Size: 431 bytes --]

On Mon, Mar 09, 2026 at 07:03:19AM +0700, phucduc.bui@gmail.com wrote:
> From: bui duc phuc <phucduc.bui@gmail.com>
> 
> Add the wakeup-source property to the ST1232 touchscreen node
> in the device tree so that the touchscreen interrupt can wake
> the system from suspend when the panel is touched.
> 
> Signed-off-by: bui duc phuc <phucduc.bui@gmail.com>

Reviewed-by: Wolfram Sang <wsa+renesas@sang-engineering.com>


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

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

* Re: [PATCH v4 0/2] Input: st1232 - add system wakeup support
  2026-03-09  0:03 [PATCH v4 0/2] Input: st1232 - add system wakeup support phucduc.bui
  2026-03-09  0:03 ` [PATCH v4 1/2] dt-bindings: input: touchscreen: sitronix,st1232: Add wakeup-source phucduc.bui
  2026-03-09  0:03 ` [PATCH v4 2/2] arm: dts: renesas: r8a7740-armadillo800eva: Add wakeup-source to st1232 phucduc.bui
@ 2026-03-10 23:09 ` Wolfram Sang
  2026-03-11 10:38   ` phucduc.bui
  2 siblings, 1 reply; 10+ messages in thread
From: Wolfram Sang @ 2026-03-10 23:09 UTC (permalink / raw)
  To: phucduc.bui
  Cc: krzk+dt, geert+renesas, krzk, krzysztof.kozlowski, conor+dt,
	devicetree, dmitry.torokhov, hechtb, javier.carrasco, jeff,
	linux-input, linux-kernel, linux-renesas-soc, magnus.damm, robh

[-- Attachment #1: Type: text/plain, Size: 215 bytes --]

Hi,

> Demo video showing wakeup from suspend:
> https://youtu.be/POJhbguiA7A

Nice video! You really put some effort here, kudos.

Really awesome seeing Linux 7 on this old platform :)

Happy hacking,

   Wolfram


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

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

* Re: [PATCH v4 1/2] dt-bindings: input: touchscreen: sitronix,st1232: Add wakeup-source
  2026-03-09  0:03 ` [PATCH v4 1/2] dt-bindings: input: touchscreen: sitronix,st1232: Add wakeup-source phucduc.bui
@ 2026-03-10 23:35   ` Dmitry Torokhov
  2026-03-11  4:25     ` [PATCH v4 1/2] dt-bindings: input: touchscreen: phucduc.bui
  0 siblings, 1 reply; 10+ messages in thread
From: Dmitry Torokhov @ 2026-03-10 23:35 UTC (permalink / raw)
  To: phucduc.bui
  Cc: krzk+dt, geert+renesas, krzk, krzysztof.kozlowski, conor+dt,
	devicetree, hechtb, javier.carrasco, jeff, linux-input,
	linux-kernel, linux-renesas-soc, magnus.damm, robh, wsa+renesas

On Mon, Mar 09, 2026 at 07:03:18AM +0700, phucduc.bui@gmail.com wrote:
> From: bui duc phuc <phucduc.bui@gmail.com>
> 
> Document the 'wakeup-source' property for Sitronix ST1232 touchscreen
> controllers to allow the device to wake the system from suspend.
> 
> Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
> Signed-off-by: bui duc phuc <phucduc.bui@gmail.com>

Applied, thank you.

-- 
Dmitry

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

* Re: [PATCH v4 2/2] arm: dts: renesas: r8a7740-armadillo800eva:
  2026-03-10 23:08   ` Wolfram Sang
@ 2026-03-11  4:22     ` phucduc.bui
  0 siblings, 0 replies; 10+ messages in thread
From: phucduc.bui @ 2026-03-11  4:22 UTC (permalink / raw)
  To: wsa+renesas
  Cc: conor+dt, devicetree, dmitry.torokhov, geert+renesas, hechtb,
	javier.carrasco, jeff, krzk+dt, krzk, krzysztof.kozlowski,
	linux-input, linux-kernel, linux-renesas-soc, magnus.damm,
	phucduc.bui, robh

Hi Wolfram,

Thank you for your review.

Best regards,
Phuc

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

* Re: [PATCH v4 1/2] dt-bindings: input: touchscreen:
  2026-03-10 23:35   ` Dmitry Torokhov
@ 2026-03-11  4:25     ` phucduc.bui
  0 siblings, 0 replies; 10+ messages in thread
From: phucduc.bui @ 2026-03-11  4:25 UTC (permalink / raw)
  To: dmitry.torokhov
  Cc: conor+dt, devicetree, geert+renesas, hechtb, javier.carrasco,
	jeff, krzk+dt, krzk, krzysztof.kozlowski, linux-input,
	linux-kernel, linux-renesas-soc, magnus.damm, phucduc.bui, robh,
	wsa+renesas

Hi Dmitry,

Thank you for applying the patch.

Best regards,
Phuc

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

* Re: [PATCH v4 0/2] Input: st1232 - add system wakeup support
  2026-03-10 23:09 ` [PATCH v4 0/2] Input: st1232 - add system wakeup support Wolfram Sang
@ 2026-03-11 10:38   ` phucduc.bui
  0 siblings, 0 replies; 10+ messages in thread
From: phucduc.bui @ 2026-03-11 10:38 UTC (permalink / raw)
  To: wsa+renesas
  Cc: conor+dt, devicetree, dmitry.torokhov, geert+renesas, hechtb,
	javier.carrasco, jeff, krzk+dt, krzk, krzysztof.kozlowski,
	linux-input, linux-kernel, linux-renesas-soc, magnus.damm,
	phucduc.bui, robh

Hi,

> > Demo video showing wakeup from suspend:
> > https://youtu.be/POJhbguiA7A
> 
> Nice video! You really put some effort here, kudos.
> 
> Really awesome seeing Linux 7 on this old platform :)
> 
> Happy hacking,

Thanks for the kind words and encouragement.
I'll keep learning from the feedback here and 
continue hacking on it.

Best regards,
Phuc

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

* Re: [PATCH v4 2/2] arm: dts: renesas: r8a7740-armadillo800eva: Add wakeup-source to st1232
  2026-03-09  0:03 ` [PATCH v4 2/2] arm: dts: renesas: r8a7740-armadillo800eva: Add wakeup-source to st1232 phucduc.bui
  2026-03-10 23:08   ` Wolfram Sang
@ 2026-03-13  8:41   ` Geert Uytterhoeven
  1 sibling, 0 replies; 10+ messages in thread
From: Geert Uytterhoeven @ 2026-03-13  8:41 UTC (permalink / raw)
  To: phucduc.bui
  Cc: krzk+dt, krzk, krzysztof.kozlowski, conor+dt, devicetree,
	dmitry.torokhov, hechtb, javier.carrasco, jeff, linux-input,
	linux-kernel, linux-renesas-soc, magnus.damm, robh, wsa+renesas

On Mon, 9 Mar 2026 at 01:04, <phucduc.bui@gmail.com> wrote:
> From: bui duc phuc <phucduc.bui@gmail.com>
>
> Add the wakeup-source property to the ST1232 touchscreen node
> in the device tree so that the touchscreen interrupt can wake
> the system from suspend when the panel is touched.
>
> Signed-off-by: bui duc phuc <phucduc.bui@gmail.com>

Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
Tested-by: Geert Uytterhoeven <geert+renesas@glider.be>
i.e. will queue in renesas-devel for v7.1.

Gr{oetje,eeting}s,

                        Geert

-- 
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

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

end of thread, other threads:[~2026-03-13  8:41 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-09  0:03 [PATCH v4 0/2] Input: st1232 - add system wakeup support phucduc.bui
2026-03-09  0:03 ` [PATCH v4 1/2] dt-bindings: input: touchscreen: sitronix,st1232: Add wakeup-source phucduc.bui
2026-03-10 23:35   ` Dmitry Torokhov
2026-03-11  4:25     ` [PATCH v4 1/2] dt-bindings: input: touchscreen: phucduc.bui
2026-03-09  0:03 ` [PATCH v4 2/2] arm: dts: renesas: r8a7740-armadillo800eva: Add wakeup-source to st1232 phucduc.bui
2026-03-10 23:08   ` Wolfram Sang
2026-03-11  4:22     ` [PATCH v4 2/2] arm: dts: renesas: r8a7740-armadillo800eva: phucduc.bui
2026-03-13  8:41   ` [PATCH v4 2/2] arm: dts: renesas: r8a7740-armadillo800eva: Add wakeup-source to st1232 Geert Uytterhoeven
2026-03-10 23:09 ` [PATCH v4 0/2] Input: st1232 - add system wakeup support Wolfram Sang
2026-03-11 10:38   ` phucduc.bui

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox