diff options
author | Sean Young <sean@mess.org> | 2017-05-17 20:32:50 +0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@s-opensource.com> | 2017-06-06 15:14:23 +0300 |
commit | 1beb5a7d1b17f187491599410709fd0544ea1c16 (patch) | |
tree | c1268f8cd66ea7ed8de4220255d26b991396a1c9 /drivers/media/rc | |
parent | da731edb5b7667d0752eeaf473896fc123b8e95f (diff) | |
download | linux-1beb5a7d1b17f187491599410709fd0544ea1c16.tar.xz |
[media] sir_ir: attempt to free already free_irq
If the probe fails (e.g. port already in use), rmmod causes null deref.
Signed-off-by: Sean Young <sean@mess.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Diffstat (limited to 'drivers/media/rc')
-rw-r--r-- | drivers/media/rc/sir_ir.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/media/rc/sir_ir.c b/drivers/media/rc/sir_ir.c index 90a5f8fd5eea..c27d6b406d7c 100644 --- a/drivers/media/rc/sir_ir.c +++ b/drivers/media/rc/sir_ir.c @@ -381,6 +381,8 @@ static int sir_ir_probe(struct platform_device *dev) static int sir_ir_remove(struct platform_device *dev) { + drop_hardware(); + drop_port(); return 0; } @@ -421,8 +423,6 @@ pdev_alloc_fail: static void __exit sir_ir_exit(void) { - drop_hardware(); - drop_port(); platform_device_unregister(sir_ir_dev); platform_driver_unregister(&sir_ir_driver); } |