wifi: mac80211: fix check for unusable RX result
authorJohannes Berg <johannes.berg@intel.com>
Mon, 25 Sep 2023 15:24:39 +0000 (17:24 +0200)
committerJohannes Berg <johannes.berg@intel.com>
Tue, 26 Sep 2023 07:16:11 +0000 (09:16 +0200)
commit583058542f46e3e2b0c536316fbd641f62d91dc6
tree0e6b7c86be3fa9a327e70597b988e77882f908bb
parente406f291501050e63a805d6b87a0d9bf198fedf9
wifi: mac80211: fix check for unusable RX result

If we just check "result & RX_DROP_UNUSABLE", this really only works
by accident, because SKB_DROP_REASON_SUBSYS_MAC80211_UNUSABLE got to
have the value 1, and SKB_DROP_REASON_SUBSYS_MAC80211_MONITOR is 2.

Fix this to really check the entire subsys mask for the value, so it
doesn't matter what the subsystem value is.

Fixes: 7f4e09700bdc ("wifi: mac80211: report all unusable beacon frames")
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
net/mac80211/drop.h
net/mac80211/rx.c