diff options
author | Du Cheng <ducheng2@gmail.com> | 2021-04-08 00:27:56 +0800 |
---|---|---|
committer | Johannes Berg <johannes.berg@intel.com> | 2021-04-08 10:14:55 +0200 |
commit | 1b5ab825d9acc0f27d2f25c6252f3526832a9626 (patch) | |
tree | e7d7abc18959e5c741c430d84550a4fc465b4586 /net/wireless | |
parent | 7d73cd946d4bc7d44cdc5121b1c61d5d71425dea (diff) | |
download | linux-stable-1b5ab825d9acc0f27d2f25c6252f3526832a9626.tar.gz linux-stable-1b5ab825d9acc0f27d2f25c6252f3526832a9626.tar.bz2 linux-stable-1b5ab825d9acc0f27d2f25c6252f3526832a9626.zip |
cfg80211: remove WARN_ON() in cfg80211_sme_connect
A WARN_ON(wdev->conn) would trigger in cfg80211_sme_connect(), if multiple
send_msg(NL80211_CMD_CONNECT) system calls are made from the userland, which
should be anticipated and handled by the wireless driver. Remove this WARN_ON()
to prevent kernel panic if kernel is configured to "panic_on_warn".
Bug reported by syzbot.
Reported-by: syzbot+5f9392825de654244975@syzkaller.appspotmail.com
Signed-off-by: Du Cheng <ducheng2@gmail.com>
Link: https://lore.kernel.org/r/20210407162756.6101-1-ducheng2@gmail.com
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/wireless')
-rw-r--r-- | net/wireless/sme.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/wireless/sme.c b/net/wireless/sme.c index 07756ca5e3b5..08a70b4f090c 100644 --- a/net/wireless/sme.c +++ b/net/wireless/sme.c @@ -529,7 +529,7 @@ static int cfg80211_sme_connect(struct wireless_dev *wdev, cfg80211_sme_free(wdev); } - if (WARN_ON(wdev->conn)) + if (wdev->conn) return -EINPROGRESS; wdev->conn = kzalloc(sizeof(*wdev->conn), GFP_KERNEL); |