mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-16 08:44:21 +08:00
drivers/video/backlight/da9052_bl.c: use usleep_range() instead of msleep() for small sleeps
Since msleep() might not sleep for the desired amount when less than 20ms, use usleep_range(). Signed-off-by: Jingoo Han <jg1.han@samsung.com> Cc: Ashish Jangam <ashish.jangam@kpitcummins.com> Cc: Richard Purdie <rpurdie@rpsys.net> Cc: Sachin Kamat <sachin.kamat@linaro.org> Cc: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
055e72fe62
commit
5333e254ab
@ -72,7 +72,7 @@ static int da9052_adjust_wled_brightness(struct da9052_bl *wleds)
|
||||
if (ret < 0)
|
||||
return ret;
|
||||
|
||||
msleep(10);
|
||||
usleep_range(10000, 11000);
|
||||
|
||||
if (wleds->brightness) {
|
||||
ret = da9052_reg_write(wleds->da9052, wled_bank[wleds->led_reg],
|
||||
|
Loading…
Reference in New Issue
Block a user