pinctrl: samsung: Document hidden requirement about one external wakeup
authorKrzysztof Kozlowski <krzk@kernel.org>
Mon, 23 Jul 2018 17:52:55 +0000 (19:52 +0200)
committerKrzysztof Kozlowski <krzk@kernel.org>
Tue, 24 Jul 2018 19:44:22 +0000 (21:44 +0200)
commit615a673ce9a99122a3a44e5dee2f61bae82a757c
treeaedeeca1e8a3ae4af8ffb6b03a7db304d319981c
parent00d6fff37066e96814796d05e1c6e8131f38576a
pinctrl: samsung: Document hidden requirement about one external wakeup

ARMv7 hardware (S5Pv210 and Exynos SoCs) provides only 32 external
interrupts which can wakeup device from deep sleep modes.  On S5Pv210
these are gph0-gph3.  On all ARMv7 Exynos designs these are gpx0-gpx3.
There is only one 32-bit register for controlling the external wakeup
interrupt mask (masking and unmasking waking capability of these
interrupts).

This lead to implementation in pinctrl driver and machine code which was
using static memory for storing the mask value and not caring about
multiple devices of pin controller... because only one pin controller
device will be handling this.

Since each pin controller node in Device Tree maps onto one device, this
corresponds to hidden assumption in parsing the Device Tree: external
wakeup interrupts can be defined only once.  Make this assumption an
explicit requirement.

ARMv8 Exynos5433 and Exynos7 bring additional 32 external wakeup
interrupts (up to 64 total, banks gpa0-gpa3 and gpf1-gpf5) and another
32-bit wide register for controlling them.  Existing code does not
support it but anyway these additional interrupts will be belonging to
the same pin controller device/node.

Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
Cc: Tomasz Figa <tomasz.figa@gmail.com>
Cc: Sylwester Nawrocki <snawrocki@kernel.org>
Acked-by: Tomasz Figa <tomasz.figa@gmail.com>
Tested-by: Marek Szyprowski <m.szyprowski@samsung.com>
Documentation/devicetree/bindings/pinctrl/samsung-pinctrl.txt