提交 66c8569b 编写于 作者: S Samu Onkalo 提交者: Linus Torvalds

lis3lv02d: correct memory leak in module unload

polled input device itself was not free'd.
Signed-off-by: NSamu Onkalo <samu.p.onkalo@nokia.com>
Tested-by: NÉric Piel <eric.piel@tremplin-utc.net>
Acked-by: NÉric Piel <eric.piel@tremplin-utc.net>
Cc: Pavel Machek <pavel@ucw.cz>
Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
上级 d25a8c81
...@@ -333,6 +333,7 @@ void lis3lv02d_joystick_disable(void) ...@@ -333,6 +333,7 @@ void lis3lv02d_joystick_disable(void)
if (lis3_dev.irq) if (lis3_dev.irq)
misc_deregister(&lis3lv02d_misc_device); misc_deregister(&lis3lv02d_misc_device);
input_unregister_polled_device(lis3_dev.idev); input_unregister_polled_device(lis3_dev.idev);
input_free_polled_device(lis3_dev.idev);
lis3_dev.idev = NULL; lis3_dev.idev = NULL;
} }
EXPORT_SYMBOL_GPL(lis3lv02d_joystick_disable); EXPORT_SYMBOL_GPL(lis3lv02d_joystick_disable);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册