Skip to contentSkip to conversation

mfd: Put WM8994 into reset when suspending

PATCH In review Mark Brown 2 participants 2 messages Feb 21, 2011

Subsystems (2)
lore
Share & tools
lore

Mark Brown

author
#0 lore raw

PATCH 1/1 mfd: Put WM8994 into reset when suspending

Ensure that the chip is in the lowest power mode possible when suspended by performing a soft reset on it. On early silicon revisions the lowest power modes can't be entered without using reset so we can't achieve equivalent results within the individual drivers.

---
 drivers/mfd/wm8994-core.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)
drivers/mfd/wm8994-core.c +5 -0
index f4016a0..e673bda2 100644
@@ -271,6 +271,11 @@ static int wm8994_suspend(struct device *dev)
 	if (ret < 0)
 		dev_err(dev, "Failed to save LDO registers: %d\n", ret);
 
+	/* Explicitly put the device into reset in case regulators
+	 * don't get disabled in order to ensure consistent restart.
+	 */
+	wm8994_reg_write(wm8994, WM8994_SOFTWARE_RESET, 0x8994);
+
 	wm8994->suspended = true;
 
 	ret = regulator_bulk_disable(wm8994->num_supplies,
Signature · 1 line
1.7.2.3
#1 lore raw

Hi Mark,

Quoted 4 lines · Mark Brown

Ensure that the chip is in the lowest power mode possible when suspended by performing a soft reset on it. On early silicon revisions the lowest power modes can't be entered without using reset so we can't achieve equivalent results within the individual drivers.

Patch applied, thanks.

Cheers,
Samuel.

Signature · 2 lines
Intel Open Source Technology Centre
http://oss.intel.com/