summaryrefslogtreecommitdiff
path: root/scripts/macro_checker.py
diff options
context:
space:
mode:
authorMurad Masimov <m.masimov@mt-integration.ru>2025-03-21 21:52:26 +0300
committerJohannes Berg <johannes.berg@intel.com>2025-07-18 14:23:23 +0200
commit3fe79a25c3cd54d25d30bc235c0c57f8a123d9d5 (patch)
tree3307d12262d1ab254115f9d7b4c58efd77d2fa0f /scripts/macro_checker.py
parentf8bf97ad19c48f5e66cf99bd390356ffa1189d62 (diff)
wifi: plfxlc: Fix error handling in usb driver probe
If probe fails before ieee80211_register_hw() is successfully done, ieee80211_unregister_hw() will be called anyway. This may lead to various bugs as the implementation of ieee80211_unregister_hw() assumes that ieee80211_register_hw() has been called. Divide error handling section into relevant subsections, so that ieee80211_unregister_hw() is called only when it is appropriate. Correct the order of the calls: ieee80211_unregister_hw() should go before plfxlc_mac_release(). Also move ieee80211_free_hw() to plfxlc_mac_release() as it supposed to be the opposite to plfxlc_mac_alloc_hw() that calls ieee80211_alloc_hw(). Found by Linux Verification Center (linuxtesting.org) with Syzkaller. Fixes: 68d57a07bfe5 ("wireless: add plfxlc driver for pureLiFi X, XL, XC devices") Signed-off-by: Murad Masimov <m.masimov@mt-integration.ru> Link: https://patch.msgid.link/20250321185226.71-3-m.masimov@mt-integration.ru Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'scripts/macro_checker.py')
0 files changed, 0 insertions, 0 deletions