提交 3ab7c7d4 编写于 作者: D Darshana Padmadas 提交者: Greg Kroah-Hartman

Staging: iio: accel: Replace msleep with usleep for given range

This patch fixes checkpatch.pl warning:
WARNING: msleep < 20ms can sleep for up to 20ms; see Documentation/timers/timers-howto.txt

As per Documentation/timers/timers-howto.txt usleep_range should be used
for sleeping for 10us-20ms
Signed-off-by: NDarshana Padmadas <darshanapadmadas@gmail.com>
Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
上级 5b12d0ac
...@@ -70,7 +70,7 @@ static int adis16220_capture(struct iio_dev *indio_dev) ...@@ -70,7 +70,7 @@ static int adis16220_capture(struct iio_dev *indio_dev)
if (ret) if (ret)
dev_err(&indio_dev->dev, "problem beginning capture"); dev_err(&indio_dev->dev, "problem beginning capture");
msleep(10); /* delay for capture to finish */ usleep_range(10000, 11000); /* delay for capture to finish */
return ret; return ret;
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册