dect
/
linux-2.6
Archived
13
0
Fork 0

mfd: arizona: Check errors from regcache_sync()

If the control bus is unrelabile we may hit errors during regcache_sync(),
especially given that it tends to be one the most dense bursts of I/O in
many systems.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
This commit is contained in:
Mark Brown 2013-01-04 17:16:12 +00:00 committed by Samuel Ortiz
parent 1f0529b4d8
commit 9270bdf540
1 changed files with 6 additions and 1 deletions

View File

@ -239,7 +239,12 @@ static int arizona_runtime_resume(struct device *dev)
return ret;
}
regcache_sync(arizona->regmap);
ret = regcache_sync(arizona->regmap);
if (ret != 0) {
dev_err(arizona->dev, "Failed to restore register cache\n");
regulator_disable(arizona->dcvdd);
return ret;
}
return 0;
}