57078a3c2e
The init and exit functions are not releasing resource properly. An error can be observed when we load/unload/load r8192u_usb module due to this issue. This patch rework init and exit functions to do proper resource release on init error and module unload. The __exit attribute is stripped from some functions since they are now being used by module init functions. [ 493.068012] proc_dir_entry 'net/ieee80211' already registered [ 493.271973] proc_mkdir+0x18/0x20 [ 493.272136] ieee80211_debug_init+0x28/0xde8 [r8192u_usb] [ 493.272404] rtl8192_usb_module_init+0x10/0x161 [r8192u_usb] [ 13.910616] proc_dir_entry 'net/rtl819xU' already registered [ 13.918931] proc_mkdir+0x18/0x20 [ 13.919098] rtl8192_usb_module_init+0x142/0x16d [r8192u_usb] Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Tong Zhang <ztong0001@gmail.com> Link: https://lore.kernel.org/r/20220224064033.1530924-3-ztong0001@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
||
---|---|---|
.. | ||
ieee80211 | ||
Kconfig | ||
Makefile | ||
authors | ||
changes | ||
r819xU_cmdpkt.c | ||
r819xU_cmdpkt.h | ||
r819xU_firmware.c | ||
r819xU_firmware.h | ||
r819xU_firmware_img.c | ||
r819xU_firmware_img.h | ||
r819xU_phy.c | ||
r819xU_phy.h | ||
r819xU_phyreg.h | ||
r8180_93cx6.c | ||
r8180_93cx6.h | ||
r8190_rtl8256.c | ||
r8190_rtl8256.h | ||
r8192U.h | ||
r8192U_core.c | ||
r8192U_dm.c | ||
r8192U_dm.h | ||
r8192U_hw.h | ||
r8192U_wx.c | ||
r8192U_wx.h |