V4L/DVB (10939): ir-kbd-i2c: Prevent general protection fault on rmmod

The removal of the timer which polls the infrared input is racy.
Replacing the timer with a delayed work solves the problem.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
This commit is contained in:
Jean Delvare
2009-03-07 07:43:43 -03:00
committed by Mauro Carvalho Chehab
parent f263bac9f7
commit c1089bdc07
2 changed files with 6 additions and 17 deletions
+1 -2
View File
@@ -14,8 +14,7 @@ struct IR_i2c {
/* Used to avoid fast repeating */
unsigned char old;
struct work_struct work;
struct timer_list timer;
struct delayed_work work;
char phys[32];
int (*get_key)(struct IR_i2c*, u32*, u32*);
};