summaryrefslogtreecommitdiffstats
path: root/drivers/media/usb
diff options
context:
space:
mode:
authorPhilipp Zabel2018-12-14 17:40:24 +0100
committerMauro Carvalho Chehab2019-01-16 19:48:12 +0100
commit4d4abf064d676dcc27952ed90f4f50d7087318c7 (patch)
tree3be999e8e4987bb466ca5db0e1aea29899afa54d /drivers/media/usb
parentmedia: vim2m: the v4l2_m2m_buf_copy_data args were swapped (diff)
downloadkernel-qcow2-linux-4d4abf064d676dcc27952ed90f4f50d7087318c7.tar.gz
kernel-qcow2-linux-4d4abf064d676dcc27952ed90f4f50d7087318c7.tar.xz
kernel-qcow2-linux-4d4abf064d676dcc27952ed90f4f50d7087318c7.zip
media: gspca: ov534: replace msleep(10) with usleep_range
For short waits, usleep_range should be used instead of msleep, see Documentation/timers/timers-howto.txt. Signed-off-by: Philipp Zabel <philipp.zabel@gmail.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
Diffstat (limited to 'drivers/media/usb')
-rw-r--r--drivers/media/usb/gspca/ov534.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/media/usb/gspca/ov534.c b/drivers/media/usb/gspca/ov534.c
index d06dc0755b9a..44f06a58bb67 100644
--- a/drivers/media/usb/gspca/ov534.c
+++ b/drivers/media/usb/gspca/ov534.c
@@ -679,7 +679,7 @@ static int sccb_check_status(struct gspca_dev *gspca_dev)
int i;
for (i = 0; i < 5; i++) {
- msleep(10);
+ usleep_range(10000, 20000);
data = ov534_reg_read(gspca_dev, OV534_REG_STATUS);
switch (data) {
@@ -1277,7 +1277,7 @@ static int sd_init(struct gspca_dev *gspca_dev)
/* reset sensor */
sccb_reg_write(gspca_dev, 0x12, 0x80);
- msleep(10);
+ usleep_range(10000, 20000);
/* probe the sensor */
sccb_reg_read(gspca_dev, 0x0a);