فهرست منبع

MIPS: APRP: Unregister rtlx interrupt hook at module exit

If the aprp_hook is not assigned back to NULL, it will still be called
after module exits. This is not wanted.

Reviewed-by: Steven J. Hill <Steven.Hill@imgtec.com>
Signed-off-by: Deng-Cheng Zhu <dengcheng.zhu@imgtec.com>
Cc: linux-mips@linux-mips.org
Cc: john@phrozen.org
Patchwork: https://patchwork.linux-mips.org/patch/6590/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Deng-Cheng Zhu 11 سال پیش
والد
کامیت
eee5794881
2فایلهای تغییر یافته به همراه6 افزوده شده و 0 حذف شده
  1. 3 0
      arch/mips/kernel/rtlx-cmp.c
  2. 3 0
      arch/mips/kernel/rtlx-mt.c

+ 3 - 0
arch/mips/kernel/rtlx-cmp.c

@@ -112,5 +112,8 @@ void __exit rtlx_module_exit(void)
 
 	for (i = 0; i < RTLX_CHANNELS; i++)
 		device_destroy(mt_class, MKDEV(major, i));
+
 	unregister_chrdev(major, RTLX_MODULE_NAME);
+
+	aprp_hook = NULL;
 }

+ 3 - 0
arch/mips/kernel/rtlx-mt.c

@@ -144,5 +144,8 @@ void __exit rtlx_module_exit(void)
 
 	for (i = 0; i < RTLX_CHANNELS; i++)
 		device_destroy(mt_class, MKDEV(major, i));
+
 	unregister_chrdev(major, RTLX_MODULE_NAME);
+
+	aprp_hook = NULL;
 }