Skip to content
Commit 48c98b1b authored by Mark Brown's avatar Mark Brown Committed by Dmitry Torokhov
Browse files

Input: samsung-keypad - implement runtime power management support



When runtime power management is enabled put the Samsung keypad driver
into suspend mode with wakeups disabled whenever the device is open but
a key is not actually been pressed. As well as saving a trivial amount of
power this will support the use of SoC wide idle modes which put the entire
device into a retention mode and use explicit wakeup sources to exit.

Since not all of the interrupt controllers used with the driver support
set_irq_wake() (though they all do the right thing) and there's a nasty
WARN() when we disable wake after failing to enable it keep track of the
current wake status from runtime PM and only disable wake if we managed
to enable it; I'm not entirely sure why this doesn't affect the existing
uses of the API in the driver.

System suspend is unaffected as the driver core will runtime resume any
suspended devices prior to system suspend.

Signed-off-by: default avatarMark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: default avatarDmitry Torokhov <dtor@mail.ru>

Conflicts:

	drivers/input/keyboard/samsung-keypad.c
parent fd0fc213
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment