diff options
author | Mauro Carvalho Chehab <m.chehab@samsung.com> | 2014-08-09 20:47:07 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <m.chehab@samsung.com> | 2014-08-21 16:25:06 -0400 |
commit | e9018af0b8897b02dc8e83e6cd75391afcadf894 (patch) | |
tree | 00beec06a81f9244d739151ac8aeb013accf0352 | |
parent | 2e0cc7ee75a218ad43b112164e87acb03f0fd9f0 (diff) |
[media] au0828: avoid race conditions at RC stop
As the RC kthread can re-enable IR int, we should first
cancel the kthread and then disable IR int.
While here, remove a temporary debug printk.
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
-rw-r--r-- | drivers/media/usb/au0828/au0828-input.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/media/usb/au0828/au0828-input.c b/drivers/media/usb/au0828/au0828-input.c index f0c5672e5f56..47ef07a693af 100644 --- a/drivers/media/usb/au0828/au0828-input.c +++ b/drivers/media/usb/au0828/au0828-input.c | |||
@@ -253,10 +253,10 @@ static void au0828_rc_stop(struct rc_dev *rc) | |||
253 | { | 253 | { |
254 | struct au0828_rc *ir = rc->priv; | 254 | struct au0828_rc *ir = rc->priv; |
255 | 255 | ||
256 | cancel_delayed_work_sync(&ir->work); | ||
257 | |||
256 | /* Disable IR */ | 258 | /* Disable IR */ |
257 | au8522_rc_clear(ir, 0xe0, 1 << 4); | 259 | au8522_rc_clear(ir, 0xe0, 1 << 4); |
258 | |||
259 | cancel_delayed_work_sync(&ir->work); | ||
260 | } | 260 | } |
261 | 261 | ||
262 | static int au0828_probe_i2c_ir(struct au0828_dev *dev) | 262 | static int au0828_probe_i2c_ir(struct au0828_dev *dev) |