diff options
author | Johannes Berg <johannes.berg@intel.com> | 2023-12-20 18:19:49 +0300 |
---|---|---|
committer | Johannes Berg <johannes.berg@intel.com> | 2024-01-03 17:35:09 +0300 |
commit | 0738e55c384828ccd61170e2d6f1c11196d848e6 (patch) | |
tree | adde8387097ddabc123a133bba629ae8e61a31cb /net/mac80211/rx.c | |
parent | b3231d353a51ddfb6ef7d17877d029790190f746 (diff) | |
download | linux-0738e55c384828ccd61170e2d6f1c11196d848e6.tar.xz |
wifi: mac80211: add kunit tests for public action handling
Check the logic in ieee80211_drop_unencrypted_mgmt()
according to a list of test cases derived from the
spec.
Reviewed-by: Benjamin Berg <benjamin.berg@intel.com>
Link: https://msgid.link/20231220151952.415232-4-benjamin@sipsolutions.net
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/mac80211/rx.c')
-rw-r--r-- | net/mac80211/rx.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/net/mac80211/rx.c b/net/mac80211/rx.c index a57c8272c1dc..0bf72928ccfc 100644 --- a/net/mac80211/rx.c +++ b/net/mac80211/rx.c @@ -19,6 +19,7 @@ #include <linux/export.h> #include <linux/kcov.h> #include <linux/bitops.h> +#include <kunit/visibility.h> #include <net/mac80211.h> #include <net/ieee80211_radiotap.h> #include <asm/unaligned.h> @@ -2414,7 +2415,7 @@ static int ieee80211_drop_unencrypted(struct ieee80211_rx_data *rx, __le16 fc) return 0; } -static ieee80211_rx_result +VISIBLE_IF_MAC80211_KUNIT ieee80211_rx_result ieee80211_drop_unencrypted_mgmt(struct ieee80211_rx_data *rx) { struct ieee80211_rx_status *status = IEEE80211_SKB_RXCB(rx->skb); @@ -2493,6 +2494,7 @@ ieee80211_drop_unencrypted_mgmt(struct ieee80211_rx_data *rx) return RX_CONTINUE; } +EXPORT_SYMBOL_IF_MAC80211_KUNIT(ieee80211_drop_unencrypted_mgmt); static ieee80211_rx_result __ieee80211_data_to_8023(struct ieee80211_rx_data *rx, bool *port_control) |