Skip to content

Commit

Permalink
mfd: arizona: Wait for internal clocks to startup after reset
Browse files Browse the repository at this point in the history
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
  • Loading branch information
Charles Keepax authored and Samuel Ortiz committed Apr 8, 2013
1 parent 87d3af4 commit c25feaa
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion drivers/mfd/arizona-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -529,8 +529,10 @@ int arizona_dev_init(struct arizona *arizona)
goto err_enable;
}

if (arizona->pdata.reset)
if (arizona->pdata.reset) {
gpio_set_value_cansleep(arizona->pdata.reset, 1);
msleep(1);
}

regcache_cache_only(arizona->regmap, false);

Expand Down Expand Up @@ -589,6 +591,8 @@ int arizona_dev_init(struct arizona *arizona)
goto err_reset;
}

msleep(1);

ret = regcache_sync(arizona->regmap);
if (ret != 0) {
dev_err(dev, "Failed to sync device: %d\n", ret);
Expand Down

0 comments on commit c25feaa

Please sign in to comment.