Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=09df5cbe46511611410274f09571ada229231ddb
Commit:     09df5cbe46511611410274f09571ada229231ddb
Parent:     a2d66a37c743ba201e85c93c4ec29d58ca94b728
Author:     Mauro Carvalho Chehab <[EMAIL PROTECTED]>
AuthorDate: Tue Jul 17 16:25:38 2007 -0300
Committer:  Mauro Carvalho Chehab <[EMAIL PROTECTED]>
CommitDate: Fri Jul 20 17:35:49 2007 -0300

    V4L/DVB (5858): Use msecs_to_jiffies instead of HZ on media/video I2C 
drivers
    
    Signed-off-by: Mauro Carvalho Chehab <[EMAIL PROTECTED]>
---
 drivers/media/video/bt866.c   |    2 +-
 drivers/media/video/saa5249.c |    8 ++++----
 drivers/media/video/saa7110.c |    4 ++--
 drivers/media/video/tvaudio.c |    4 ++--
 4 files changed, 9 insertions(+), 9 deletions(-)

diff --git a/drivers/media/video/bt866.c b/drivers/media/video/bt866.c
index 2e4cf1e..b767b09 100644
--- a/drivers/media/video/bt866.c
+++ b/drivers/media/video/bt866.c
@@ -257,7 +257,7 @@ static int bt866_write(struct bt866 *encoder,
                printk(KERN_WARNING "%s: I/O error #%d "
                       "(write 0x%02x/0x%02x)\n",
                       encoder->i2c->name, err, encoder->addr, subaddr);
-               schedule_timeout_interruptible(HZ/10);
+               schedule_timeout_interruptible(msecs_to_jiffies(100));
        }
        if (err == 3) {
                printk(KERN_WARNING "%s: giving up\n",
diff --git a/drivers/media/video/saa5249.c b/drivers/media/video/saa5249.c
index f2a2f34..17f1e2e 100644
--- a/drivers/media/video/saa5249.c
+++ b/drivers/media/video/saa5249.c
@@ -86,9 +86,9 @@ static const int disp_modes[8][3] =
 
 
 
-#define PAGE_WAIT (300*HZ/1000)                        /* Time between 
requesting page and */
+#define PAGE_WAIT    msecs_to_jiffies(300)     /* Time between requesting page 
and */
                                                /* checking status bits */
-#define PGBUF_EXPIRE (15*HZ)                   /* Time to wait before 
retransmitting */
+#define PGBUF_EXPIRE msecs_to_jiffies(15000)   /* Time to wait before 
retransmitting */
                                                /* page regardless of infobits 
*/
 typedef struct {
        u8 pgbuf[VTX_VIRTUALSIZE];              /* Page-buffer */
@@ -115,8 +115,8 @@ struct saa5249_device
 #define CCTWR 34               /* I�C write/read-address of vtx-chip */
 #define CCTRD 35
 #define NOACK_REPEAT 10                /* Retry access this many times on 
failure */
-#define CLEAR_DELAY (HZ/20)    /* Time required to clear a page */
-#define READY_TIMEOUT (30*HZ/1000)     /* Time to wait for ready signal of 
I�C-bus interface */
+#define CLEAR_DELAY   msecs_to_jiffies(50)     /* Time required to clear a 
page */
+#define READY_TIMEOUT msecs_to_jiffies(30)     /* Time to wait for ready 
signal of I2C-bus interface */
 #define INIT_DELAY 500         /* Time in usec to wait at initialization of 
CEA interface */
 #define START_DELAY 10         /* Time in usec to wait before starting 
write-cycle (CEA) */
 
diff --git a/drivers/media/video/saa7110.c b/drivers/media/video/saa7110.c
index 676b997..061134a 100644
--- a/drivers/media/video/saa7110.c
+++ b/drivers/media/video/saa7110.c
@@ -208,7 +208,7 @@ determine_norm (struct i2c_client *client)
        saa7110_write_block(client, initseq, sizeof(initseq));
        saa7110_selmux(client, decoder->input);
        prepare_to_wait(&decoder->wq, &wait, TASK_UNINTERRUPTIBLE);
-       schedule_timeout(HZ/4);
+       schedule_timeout(msecs_to_jiffies(250));
        finish_wait(&decoder->wq, &wait);
        status = saa7110_read(client);
        if (status & 0x40) {
@@ -249,7 +249,7 @@ determine_norm (struct i2c_client *client)
        //saa7110_write(client,0x2E,0x9A);
 
        prepare_to_wait(&decoder->wq, &wait, TASK_UNINTERRUPTIBLE);
-       schedule_timeout(HZ/4);
+       schedule_timeout(msecs_to_jiffies(250));
        finish_wait(&decoder->wq, &wait);
 
        status = saa7110_read(client);
diff --git a/drivers/media/video/tvaudio.c b/drivers/media/video/tvaudio.c
index 9da338d..cffb011 100644
--- a/drivers/media/video/tvaudio.c
+++ b/drivers/media/video/tvaudio.c
@@ -290,7 +290,7 @@ static int chip_thread(void *data)
                desc->checkmode(chip);
 
                /* schedule next check */
-               mod_timer(&chip->wt, jiffies+2*HZ);
+               mod_timer(&chip->wt, jiffies+msecs_to_jiffies(2000));
        }
 
        v4l_dbg(1, debug, &chip->c, "%s: thread exiting\n", chip->c.name);
@@ -1770,7 +1770,7 @@ static int chip_command(struct i2c_client *client,
                        desc->setmode(chip,VIDEO_SOUND_MONO);
                        if (chip->prevmode != VIDEO_SOUND_MONO)
                                chip->prevmode = -1; /* reset previous mode */
-                       mod_timer(&chip->wt, jiffies+2*HZ);
+                       mod_timer(&chip->wt, jiffies+msecs_to_jiffies(2000));
                        /* the thread will call checkmode() later */
                }
                break;
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to