summaryrefslogtreecommitdiffstats
path: root/drivers/mfd/sec-core.c
diff options
context:
space:
mode:
authorChanwoo Choi <cw00.choi@samsung.com>2014-06-25 09:14:47 +0200
committerLee Jones <lee.jones@linaro.org>2014-07-09 15:58:12 +0200
commitb7cde7078d2344073c310aa65fc2b0a845d2cb5b (patch)
treecea3062fcf908fed85cf3d4aad78367567a4171e /drivers/mfd/sec-core.c
parentdt-bindings: mfd: s2mps11: Add support S2MPU02 PMIC (diff)
downloadlinux-b7cde7078d2344073c310aa65fc2b0a845d2cb5b.tar.xz
linux-b7cde7078d2344073c310aa65fc2b0a845d2cb5b.zip
mfd: sec-core: Prepare regulators for suspend state to reduce power-consumption
This patch use regulator_suspend_prepare() function to prepare the proper state of regulators for suspend state to remove un-necessary leakage power-consumption. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com> Signed-off-by: Lee Jones <lee.jones@linaro.org>
Diffstat (limited to 'drivers/mfd/sec-core.c')
-rw-r--r--drivers/mfd/sec-core.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/mfd/sec-core.c b/drivers/mfd/sec-core.c
index 2621328851ba..fb8ba6438268 100644
--- a/drivers/mfd/sec-core.c
+++ b/drivers/mfd/sec-core.c
@@ -31,6 +31,7 @@
#include <linux/mfd/samsung/s2mpu02.h>
#include <linux/mfd/samsung/s5m8763.h>
#include <linux/mfd/samsung/s5m8767.h>
+#include <linux/regulator/machine.h>
#include <linux/regmap.h>
static const struct mfd_cell s5m8751_devs[] = {
@@ -430,6 +431,15 @@ static int sec_pmic_suspend(struct device *dev)
*/
disable_irq(sec_pmic->irq);
+ switch (sec_pmic->device_type) {
+ case S2MPS14X:
+ case S2MPU02:
+ regulator_suspend_prepare(PM_SUSPEND_MEM);
+ break;
+ default:
+ break;
+ }
+
return 0;
}