mirror of
https://github.com/torvalds/linux.git
synced 2024-11-16 00:52:01 +00:00
68bda47c57
The rockchip pinctrl driver was using irq_gc_set_wake() as its implementation of irq_set_wake() but was totally ignoring everything that irq_gc_set_wake() did (which is to upkeep gc->wake_active). Let's fix that by setting gc->wake_active as GPIO_INTEN at suspend time and restoring GPIO_INTEN at resume time. NOTE a few quirks when thinking about this patch: - Rockchip pinctrl hardware supports both "disable/enable" and "mask/unmask". Right now we only use "disable/enable" and present those to Linux as "mask/unmask". This should be OK because enable/disable is optional and Linux will implement it in terms of mask/unmask. At the moment we always tell hardware all interrupts are unmasked (the boot default). - At suspend time Linux tries to call "disable" on all interrupts and also enables wakeup on all wakeup interrupts. One would think that since "disable" is implemented as "mask" when "disable" isn't provided and that since we were ignoring gc->wake_active that nothing would have woken us up. That's not the case since Linux "optimizes" things and just leaves interrutps unmasked, assuming it could mask them later when they go off. That meant that at suspend time all interrupts were actually being left enabled. With this patch random non-wakeup interrupts no longer wake the system up. Wakeup interrupts still wake the system up. Signed-off-by: Doug Anderson <dianders@chromium.org> Reviewed-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Reviewed-by: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> |
||
---|---|---|
.. | ||
berlin | ||
freescale | ||
intel | ||
mvebu | ||
nomadik | ||
qcom | ||
samsung | ||
sh-pfc | ||
sirf | ||
spear | ||
sunxi | ||
vt8500 | ||
core.c | ||
core.h | ||
devicetree.c | ||
devicetree.h | ||
Kconfig | ||
Makefile | ||
pinconf-generic.c | ||
pinconf.c | ||
pinconf.h | ||
pinctrl-adi2-bf54x.c | ||
pinctrl-adi2-bf60x.c | ||
pinctrl-adi2.c | ||
pinctrl-adi2.h | ||
pinctrl-as3722.c | ||
pinctrl-at91.c | ||
pinctrl-at91.h | ||
pinctrl-bcm281xx.c | ||
pinctrl-bcm2835.c | ||
pinctrl-coh901.c | ||
pinctrl-coh901.h | ||
pinctrl-falcon.c | ||
pinctrl-lantiq.c | ||
pinctrl-lantiq.h | ||
pinctrl-palmas.c | ||
pinctrl-rockchip.c | ||
pinctrl-single.c | ||
pinctrl-st.c | ||
pinctrl-tb10x.c | ||
pinctrl-tegra20.c | ||
pinctrl-tegra30.c | ||
pinctrl-tegra114.c | ||
pinctrl-tegra124.c | ||
pinctrl-tegra-xusb.c | ||
pinctrl-tegra.c | ||
pinctrl-tegra.h | ||
pinctrl-tz1090-pdc.c | ||
pinctrl-tz1090.c | ||
pinctrl-u300.c | ||
pinctrl-utils.c | ||
pinctrl-utils.h | ||
pinctrl-xway.c | ||
pinmux.c | ||
pinmux.h |