diff options
author | Mauro Carvalho Chehab <mchehab@redhat.com> | 2013-04-10 14:48:02 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2013-04-16 20:31:42 -0400 |
commit | 9cc2570a1dd74c22b4644b325257cf92d4cdb031 (patch) | |
tree | 9b676d329c1aa9a4b3f3a85daad5b9a1645a0c8e /drivers/media | |
parent | 226471a18f5458d42aac52bca62ebd8edeb37a96 (diff) |
[media] r820t: use usleep_range()
Instead of using msleep(), use sleep_range(), as it provides
a closer sleep time.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Tested-by: Antti Palosaari <crope@iki.fi>
Diffstat (limited to 'drivers/media')
-rw-r--r-- | drivers/media/tuners/r820t.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/media/tuners/r820t.c b/drivers/media/tuners/r820t.c index e9367d896a07..279be4f78e7a 100644 --- a/drivers/media/tuners/r820t.c +++ b/drivers/media/tuners/r820t.c | |||
@@ -657,7 +657,7 @@ static int r820t_set_pll(struct r820t_priv *priv, u32 freq) | |||
657 | * FIXME: Rafael chips R620D, R828D and R828 seems to | 657 | * FIXME: Rafael chips R620D, R828D and R828 seems to |
658 | * need 20 ms for analog TV | 658 | * need 20 ms for analog TV |
659 | */ | 659 | */ |
660 | msleep(10); | 660 | usleep_range(10000, 11000); |
661 | 661 | ||
662 | /* Check if PLL has locked */ | 662 | /* Check if PLL has locked */ |
663 | rc = r820t_read(priv, 0x00, data, 3); | 663 | rc = r820t_read(priv, 0x00, data, 3); |
@@ -1007,7 +1007,7 @@ static int r820t_set_tv_standard(struct r820t_priv *priv, | |||
1007 | rc = r820t_write_reg_mask(priv, 0x1d, 0x00, 0x38); | 1007 | rc = r820t_write_reg_mask(priv, 0x1d, 0x00, 0x38); |
1008 | if (rc < 0) | 1008 | if (rc < 0) |
1009 | return rc; | 1009 | return rc; |
1010 | msleep(1); | 1010 | usleep_range(1000, 2000); |
1011 | } | 1011 | } |
1012 | priv->int_freq = if_khz * 1000; | 1012 | priv->int_freq = if_khz * 1000; |
1013 | 1013 | ||
@@ -1049,7 +1049,7 @@ static int r820t_set_tv_standard(struct r820t_priv *priv, | |||
1049 | if (rc < 0) | 1049 | if (rc < 0) |
1050 | return rc; | 1050 | return rc; |
1051 | 1051 | ||
1052 | msleep(1); | 1052 | usleep_range(1000, 2000); |
1053 | 1053 | ||
1054 | /* Stop Trigger */ | 1054 | /* Stop Trigger */ |
1055 | rc = r820t_write_reg_mask(priv, 0x0b, 0x00, 0x10); | 1055 | rc = r820t_write_reg_mask(priv, 0x0b, 0x00, 0x10); |
@@ -1347,7 +1347,7 @@ static int r820t_xtal_check(struct r820t_priv *priv) | |||
1347 | if (rc < 0) | 1347 | if (rc < 0) |
1348 | return rc; | 1348 | return rc; |
1349 | 1349 | ||
1350 | msleep(5); | 1350 | usleep_range(5000, 6000); |
1351 | 1351 | ||
1352 | rc = r820t_read(priv, 0x00, data, sizeof(data)); | 1352 | rc = r820t_read(priv, 0x00, data, sizeof(data)); |
1353 | if (rc < 0) | 1353 | if (rc < 0) |