mirror of
https://github.com/torvalds/linux.git
synced 2026-12-03 03:52:37 +00:00
Watchdog task might end between send_sig() and kthread_stop() calls, what results in the use-after-free issue. Fix this by increasing watchdog task reference count before calling send_sig() and dropping it by switching to kthread_stop_put(). Cc: [email protected] Fixes:373c83a801("brcmfmac: stop watchdog before detach and free everything") Fixes:a9ffda88be("brcm80211: fmac: abstract bus_stop interface function pointer") Signed-off-by: Marek Szyprowski <[email protected]> Acked-by: Arend van Spriel <[email protected]> Link: https://patch.msgid.link/[email protected] Signed-off-by: Johannes Berg <[email protected]>