diff options
author | Charles Keepax <ckeepax@opensource.wolfsonmicro.com> | 2013-04-03 04:45:29 -0400 |
---|---|---|
committer | Samuel Ortiz <sameo@linux.intel.com> | 2013-04-08 09:21:03 -0400 |
commit | d955cba86d32e9b4b6fe7611b4c41b7bbe286183 (patch) | |
tree | d821c5002ac3e49516a805560582f095931c0f26 | |
parent | c25feaa53cca696321540ca0f8564bf484224cac (diff) |
mfd: wm5102: Don't wait for boot when boot sequencer is disabled
As we are using a custom boot sequence we don't need to wait for the
standard boot sequence in device init when the normal write sequence is
disabled.
Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
-rw-r--r-- | drivers/mfd/arizona-core.c | 22 |
1 files changed, 18 insertions, 4 deletions
diff --git a/drivers/mfd/arizona-core.c b/drivers/mfd/arizona-core.c index 41856b4c0d17..6ab03043fd60 100644 --- a/drivers/mfd/arizona-core.c +++ b/drivers/mfd/arizona-core.c | |||
@@ -600,10 +600,24 @@ int arizona_dev_init(struct arizona *arizona) | |||
600 | } | 600 | } |
601 | } | 601 | } |
602 | 602 | ||
603 | ret = arizona_wait_for_boot(arizona); | 603 | switch (arizona->type) { |
604 | if (ret != 0) { | 604 | case WM5102: |
605 | dev_err(arizona->dev, "Device failed initial boot: %d\n", ret); | 605 | ret = regmap_read(arizona->regmap, 0x19, &val); |
606 | goto err_reset; | 606 | if (ret != 0) |
607 | dev_err(dev, | ||
608 | "Failed to check write sequencer state: %d\n", | ||
609 | ret); | ||
610 | else if (val & 0x01) | ||
611 | break; | ||
612 | /* Fall through */ | ||
613 | default: | ||
614 | ret = arizona_wait_for_boot(arizona); | ||
615 | if (ret != 0) { | ||
616 | dev_err(arizona->dev, | ||
617 | "Device failed initial boot: %d\n", ret); | ||
618 | goto err_reset; | ||
619 | } | ||
620 | break; | ||
607 | } | 621 | } |
608 | 622 | ||
609 | if (apply_patch) { | 623 | if (apply_patch) { |