diff options
| author | Ilan Peer <ilan.peer@intel.com> | 2025-07-09 23:37:55 +0300 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2025-08-20 18:36:04 +0200 |
| commit | a32439561ffb4e4e36cd4b9e13161a030069f81d (patch) | |
| tree | a6a8b8bfa0f42130683528714b0ee5ac71fbb0d8 /include | |
| parent | caf515b7b6403ab39a380e2506f1300387ee8a79 (diff) | |
wifi: cfg80211: Fix interface type validation
[ Upstream commit 14450be2332a49445106403492a367412b8c23f4 ]
Fix a condition that verified valid values of interface types.
Signed-off-by: Ilan Peer <ilan.peer@intel.com>
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Link: https://patch.msgid.link/20250709233537.7ad199ca5939.I0ac1ff74798bf59a87a57f2e18f2153c308b119b@changeid
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'include')
| -rw-r--r-- | include/net/cfg80211.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/net/cfg80211.h b/include/net/cfg80211.h index 75f2e5782887..71db571617ba 100644 --- a/include/net/cfg80211.h +++ b/include/net/cfg80211.h @@ -633,7 +633,7 @@ ieee80211_get_sband_iftype_data(const struct ieee80211_supported_band *sband, const struct ieee80211_sband_iftype_data *data; int i; - if (WARN_ON(iftype >= NL80211_IFTYPE_MAX)) + if (WARN_ON(iftype >= NUM_NL80211_IFTYPES)) return NULL; if (iftype == NL80211_IFTYPE_AP_VLAN) |
