Linux kernel staging patches
 help / color / mirror / Atom feed
* [PATCH v3 0/3] staging: rtl8723bs: fix error handling and memory leaks
@ 2026-01-30  0:16 Samasth Norway Ananda
  2026-01-30  0:16 ` [PATCH v3 1/3] staging: rtl8723bs: fix firmware memory leak on error Samasth Norway Ananda
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Samasth Norway Ananda @ 2026-01-30  0:16 UTC (permalink / raw)
  To: dan.carpenter, gregkh; +Cc: linux-staging, linux-kernel, samasth.norway.ananda

This series fixes memory leaks and missing error checks in rtl8723bs:

1. Firmware not released on error paths in rtl8723b_FirmwareDownload().
2. Buffer not freed when cfg80211_inform_bss_frame() fails.
3. Missing IS_ERR() check for kthread_run() in rtl8723b_start_thread().

Changes in v3:
-> Patch 3: remove rtl8723b_start_thread(), rtl8723b_stop_thread(), 
rtw_hal_start_thread() and rtw_hal_stop_thread() entirely, inlining 
the kthread handling directly to rtw_start_drv_threads() and 
rtw_stop_drv_threads() with proper IS_ERR() checking.


Changes in v2:
-> Patch 1: Call release_firmware() directly in error paths instead of
using intermediate goto label.
-> Dropped patch 4 (rtw_wdev_alloc) to study cleanup chain further.

Samasth Norway Ananda (3):
  staging: rtl8723bs: fix firmware memory leak on error
  staging: rtl8723bs: fix memory leak in rtw_cfg80211_inform_bss()
  staging: rtl8723bs: remove thread wraper functions and add IS_ERR()
    check

 drivers/staging/rtl8723bs/hal/hal_intf.c      | 11 ----------
 .../staging/rtl8723bs/hal/rtl8723b_hal_init.c | 21 ++-----------------
 drivers/staging/rtl8723bs/include/hal_intf.h  |  3 ---
 .../staging/rtl8723bs/include/rtl8723b_hal.h  |  3 ---
 .../staging/rtl8723bs/os_dep/ioctl_cfg80211.c |  4 +++-
 drivers/staging/rtl8723bs/os_dep/os_intfs.c   | 16 ++++++++++++--
 6 files changed, 19 insertions(+), 39 deletions(-)

-- 
2.50.1


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2026-02-07 12:34 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-01-30  0:16 [PATCH v3 0/3] staging: rtl8723bs: fix error handling and memory leaks Samasth Norway Ananda
2026-01-30  0:16 ` [PATCH v3 1/3] staging: rtl8723bs: fix firmware memory leak on error Samasth Norway Ananda
2026-01-30  0:16 ` [PATCH v3 2/3] staging: rtl8723bs: fix memory leak in rtw_cfg80211_inform_bss() Samasth Norway Ananda
2026-02-07 12:34   ` Greg KH
2026-01-30  0:16 ` [PATCH v3 3/3] staging: rtl8723bs: remove thread wraper functions and add IS_ERR() check Samasth Norway Ananda

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox