mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH v2 0/2] Input: gpio-keys - support wakeup pinctrl state
@ 2026-09-25 21:52 Kendall Willis
  2026-09-25 21:52 ` [PATCH v2 1/2] dt-bindings: input: gpio-keys: add pinctrl states Kendall Willis
  2026-09-25 21:52 ` [PATCH v2 2/2] Input: gpio-keys - support wakeup pinctrl state on suspend Kendall Willis
  0 siblings, 2 replies; 5+ messages in thread
From: Kendall Willis @ 2026-09-25 21:52 UTC (permalink / raw)
  To: Dmitry Torokhov, Rob Herring, Krzysztof Kozlowski, Conor Dooley
  Cc: msp, s-kochidanadu, a-kaur, s-tripathi1, vishalm, k-willis,
	linux-input, linux-kernel, devicetree

Add 'wakeup' pinctrl state to support separate pin wakeup
configurations for GPIO. Upon suspend the 'wakeup' pinctrl state is
chosen if it exists. On resume the 'default' pinctrl state is selected.
The 'wakeup' pinctrl state allows wakeup from low-power states if a
specific pin configuration is needed.

On TI K3 AM62 family of devices, the GPIO controller is turned off in
suspend to RAM states, so no interrupt can be received by the
controller. This prevents system wakeup from low-power states.
Alternatively, the pins can wakeup the system if a wakeup flag is set on
the pin by using pinctrl.

A corresponding device tree patch using the 'wakeup' pinctrl state can
be found under "arm64: dts: ti: k3-am62l3-evm: add wakeup-source for GPIO
button" [1].

Tested GPIO wakeup from suspend on AM62L EVM and AM62P EVM.

[1] https://lore.kernel.org/all/20260912-upstream-gpio-wakeup-dts-v1-1-2057d76c63aa@ti.com/

Signed-off-by: Kendall Willis <k-willis@ti.com>
---
Changes in v2:
- Update gpio-keys dt bindings commit message for better explanation of
  wakeup state.
- Fix error pathways for if switching to the "wakeup" pinctrl state
  fails.
- Link to v1: https://lore.kernel.org/r/20260912-upstream-gpio-wakeup-v1-0-f0e12484b836@ti.com

---
Kendall Willis (2):
      dt-bindings: input: gpio-keys: add pinctrl states
      Input: gpio-keys - support wakeup pinctrl state on suspend

 .../devicetree/bindings/input/gpio-keys.yaml          | 16 ++++++++++++++++
 drivers/input/keyboard/gpio_keys.c                    | 19 +++++++++++++++++++
 2 files changed, 35 insertions(+)
---
base-commit: 93f51579e7df248780214094418f205253383cc5
change-id: 20260904-upstream-gpio-wakeup-52a54080c948

Best regards,
-- 
Kendall Willis <k-willis@ti.com>


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

end of thread, other threads:[~2026-09-30 20:31 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-09-25 21:52 [PATCH v2 0/2] Input: gpio-keys - support wakeup pinctrl state Kendall Willis
2026-09-25 21:52 ` [PATCH v2 1/2] dt-bindings: input: gpio-keys: add pinctrl states Kendall Willis
2026-09-25 21:52 ` [PATCH v2 2/2] Input: gpio-keys - support wakeup pinctrl state on suspend Kendall Willis
2026-09-30 12:11   ` Markus Schneider-Pargmann
2026-09-30 20:30     ` Kendall Willis

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

all inboxes | Powered by JetHome®