diff options
author | Nicholas Mc Guire <hofrat@osadl.org> | 2017-01-12 15:09:41 +0300 |
---|---|---|
committer | Ben Hutchings <ben@decadent.org.uk> | 2017-06-05 23:16:50 +0300 |
commit | 47a6229f47c22283335e0e9e236fba7fd6b82ba7 (patch) | |
tree | f50d8e336ad9eb80a546d15891837e73ba1ce277 /sound/soc/codecs | |
parent | c124df9e1528f6579050e484b303f9b11a540baf (diff) | |
download | linux-47a6229f47c22283335e0e9e236fba7fd6b82ba7.tar.xz |
ASoC: rt5640: use msleep() for long delays
commit 4a312c9c825adf74c0026c98fed4ab59ce190863 upstream.
ulseep_range() uses hrtimers and provides no advantage over msleep()
for larger delays. Fix up the 70/80ms delays here passing the "min"
value to msleep(). This reduces the load on the hrtimer subsystem.
Link: http://lkml.org/lkml/2017/1/11/377
Fixes: commit 246693ba7b0b ("ASoC: rt5640: change widget sequence for depop")
Signed-off-by: Nicholas Mc Guire <hofrat@osadl.org>
Signed-off-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Diffstat (limited to 'sound/soc/codecs')
-rw-r--r-- | sound/soc/codecs/rt5640.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sound/soc/codecs/rt5640.c b/sound/soc/codecs/rt5640.c index 7aeb69bace7a..c2cd770ec749 100644 --- a/sound/soc/codecs/rt5640.c +++ b/sound/soc/codecs/rt5640.c @@ -974,7 +974,7 @@ static int rt5640_hp_event(struct snd_soc_dapm_widget *w, case SND_SOC_DAPM_PRE_PMD: rt5640->hp_mute = 1; - usleep_range(70000, 75000); + msleep(70); break; default: @@ -1038,7 +1038,7 @@ static int rt5640_hp_post_event(struct snd_soc_dapm_widget *w, switch (event) { case SND_SOC_DAPM_POST_PMU: if (!rt5640->hp_mute) - usleep_range(80000, 85000); + msleep(80); break; |