[<prev] [next>] [day] [month] [year] [list]
Message-id: <002e01cd738e$50fcfdc0$f2f6f940$%han@samsung.com>
Date: Mon, 06 Aug 2012 13:45:34 +0900
From: Jingoo Han <jg1.han@...sung.com>
To: 'Andrew Morton' <akpm@...ux-foundation.org>,
'LKML' <linux-kernel@...r.kernel.org>
Cc: 'Richard Purdie' <rpurdie@...ys.net>,
'Claudio Nieder' <private@...udio.ch>,
'Jingoo Han' <jg1.han@...sung.com>
Subject: [PATCH 3/3] backlight: kb3886: 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.
Cc: Claudio Nieder <private@...udio.ch>
Cc: Richard Purdie <rpurdie@...ys.net>
Signed-off-by: Jingoo Han <jg1.han@...sung.com>
---
drivers/video/backlight/kb3886_bl.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/video/backlight/kb3886_bl.c b/drivers/video/backlight/kb3886_bl.c
index 72dd555..6c5ed6b 100644
--- a/drivers/video/backlight/kb3886_bl.c
+++ b/drivers/video/backlight/kb3886_bl.c
@@ -34,9 +34,9 @@ static void kb3886_bl_set_intensity(int intensity)
mutex_lock(&bl_mutex);
intensity = intensity&0xff;
outb(KB3886_ADC_DAC_PWM, KB3886_PARENT);
- msleep(10);
+ usleep_range(10000, 11000);
outb(KB3886_PWM0_WRITE, KB3886_IO);
- msleep(10);
+ usleep_range(10000, 11000);
outb(intensity, KB3886_IO);
mutex_unlock(&bl_mutex);
}
--
1.7.1
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists