Skip to content

Commit 137c492

Browse files
afordcirrusLucas Tanure
authored andcommitted
mfd: clsic: Increase post-reset delay and add one for runtime_resume
It can take up to 2ms for the codec to become responsive after reset has been release or DCVDD has risen. The current sleeps were on the optimistic side, so increase them, and also add one after DCVDD has been enabled in runtime_resume. Reference tacna change id I72fd445892769f20532bc187a66357582072bb4b Change-Id: I381b3ff0edea3fd275c45930586878e1d25a5f0d Signed-off-by: Andrew Ford <[email protected]>
1 parent 9f555a0 commit 137c492

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

drivers/mfd/clsic/clsic-core.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ static void clsic_disable_hard_reset(struct clsic *clsic)
6060
{
6161
if (clsic->reset_gpio) {
6262
gpiod_set_value_cansleep(clsic->reset_gpio, 1);
63-
usleep_range(1000, 2000);
63+
usleep_range(2000, 3000);
6464
}
6565
}
6666

@@ -90,6 +90,7 @@ static bool clsic_wait_for_boot_done(struct clsic *clsic)
9090
void clsic_soft_reset(struct clsic *clsic)
9191
{
9292
regmap_write(clsic->regmap, TACNA_SFT_RESET, CLSIC_SOFTWARE_RESET_CODE);
93+
usleep_range(2000, 3000);
9394
clsic_wait_for_boot_done(clsic);
9495
}
9596

@@ -1003,6 +1004,8 @@ static int clsic_runtime_resume(struct device *dev)
10031004
return ret;
10041005
}
10051006

1007+
usleep_range(2000, 3000);
1008+
10061009
if (force_reset) {
10071010
if (clsic->reset_gpio)
10081011
clsic_hard_reset(clsic);

0 commit comments

Comments
 (0)