diff options
author | Mauro Carvalho Chehab <mchehab@infradead.org> | 2007-05-22 00:34:25 -0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@infradead.org> | 2007-05-22 00:34:25 -0300 |
commit | 579625a94d4d4391eaea14e8899c10ff84c458c8 (patch) | |
tree | 618760ecbf356fd293c9cbef00f0ae590b27bacd /linux/drivers/media/video/cx88/cx88-input.c | |
parent | 282647fc6ca96307a1e740536bbe09d01185f33c (diff) | |
parent | cac5da1c7c1873320073fccdefc334fc34a745e3 (diff) | |
download | mediapointer-dvb-s2-579625a94d4d4391eaea14e8899c10ff84c458c8.tar.gz mediapointer-dvb-s2-579625a94d4d4391eaea14e8899c10ff84c458c8.tar.bz2 |
merge: http://linuxtv.org/hg/~mkrufky/cx88
From: Mauro Carvalho Chehab <mchehab@infradead.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'linux/drivers/media/video/cx88/cx88-input.c')
-rw-r--r-- | linux/drivers/media/video/cx88/cx88-input.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/linux/drivers/media/video/cx88/cx88-input.c b/linux/drivers/media/video/cx88/cx88-input.c index 6c712ecdd..a2e34e901 100644 --- a/linux/drivers/media/video/cx88/cx88-input.c +++ b/linux/drivers/media/video/cx88/cx88-input.c @@ -157,24 +157,20 @@ static void cx88_ir_work(struct work_struct *work) #else struct cx88_IR *ir = container_of(work, struct cx88_IR, work); #endif - unsigned long timeout; cx88_ir_handle_key(ir); - timeout = jiffies + (ir->polling * HZ / 1000); - mod_timer(&ir->timer, timeout); + mod_timer(&ir->timer, jiffies + msecs_to_jiffies(ir->polling)); } static void cx88_ir_start(struct cx88_core *core, struct cx88_IR *ir) { if (ir->polling) { + setup_timer(&ir->timer, ir_timer, (unsigned long)ir); #if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,20) INIT_WORK(&ir->work, cx88_ir_work, ir); #else INIT_WORK(&ir->work, cx88_ir_work); #endif - init_timer(&ir->timer); - ir->timer.function = ir_timer; - ir->timer.data = (unsigned long)ir; schedule_work(&ir->work); } if (ir->sampling) { |