Commit b7cde707 authored by Chanwoo Choi's avatar Chanwoo Choi Committed by Lee Jones

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: default avatarChanwoo Choi <cw00.choi@samsung.com>
Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
parent b264fc70
...@@ -587,6 +587,7 @@ config MFD_SEC_CORE ...@@ -587,6 +587,7 @@ config MFD_SEC_CORE
select MFD_CORE select MFD_CORE
select REGMAP_I2C select REGMAP_I2C
select REGMAP_IRQ select REGMAP_IRQ
select REGULATOR
help help
Support for the Samsung Electronics MFD series. Support for the Samsung Electronics MFD series.
This driver provides common support for accessing the device, This driver provides common support for accessing the device,
......
...@@ -31,6 +31,7 @@ ...@@ -31,6 +31,7 @@
#include <linux/mfd/samsung/s2mpu02.h> #include <linux/mfd/samsung/s2mpu02.h>
#include <linux/mfd/samsung/s5m8763.h> #include <linux/mfd/samsung/s5m8763.h>
#include <linux/mfd/samsung/s5m8767.h> #include <linux/mfd/samsung/s5m8767.h>
#include <linux/regulator/machine.h>
#include <linux/regmap.h> #include <linux/regmap.h>
static const struct mfd_cell s5m8751_devs[] = { static const struct mfd_cell s5m8751_devs[] = {
...@@ -430,6 +431,15 @@ static int sec_pmic_suspend(struct device *dev) ...@@ -430,6 +431,15 @@ static int sec_pmic_suspend(struct device *dev)
*/ */
disable_irq(sec_pmic->irq); 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; return 0;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment