From: Miri Korenblit <miriam.rachel.korenblit@intel.com>
To: linux-wireless@vger.kernel.org
Cc: Avraham Stern <avraham.stern@intel.com>, Ilan Peer <ilan.peer@intel.com>
Subject: [PATCH v2 wireless-next 15/15] wifi: mac80211: allow add_key on NAN interfaces
Date: Thu, 26 Mar 2026 12:14:45 +0200 [thread overview]
Message-ID: <20260326121156.34961ba9a0c4.I5b7c646c456d4112e5ab8663026153ace9b6b7d6@changeid> (raw)
In-Reply-To: <20260326101445.1443198-1-miriam.rachel.korenblit@intel.com>
From: Avraham Stern <avraham.stern@intel.com>
Keys may be added to the NAN interfaces to protect
NAN management frames and data, allow that.
Signed-off-by: Avraham Stern <avraham.stern@intel.com>
Reviewed-by: Ilan Peer <ilan.peer@intel.com>
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
---
net/mac80211/cfg.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/net/mac80211/cfg.c b/net/mac80211/cfg.c
index 8cdbefac1bee..210f0030f228 100644
--- a/net/mac80211/cfg.c
+++ b/net/mac80211/cfg.c
@@ -702,6 +702,8 @@ static int ieee80211_add_key(struct wiphy *wiphy, struct wireless_dev *wdev,
break;
case NL80211_IFTYPE_AP:
case NL80211_IFTYPE_AP_VLAN:
+ case NL80211_IFTYPE_NAN:
+ case NL80211_IFTYPE_NAN_DATA:
/* Keys without a station are used for TX only */
if (sta && test_sta_flag(sta, WLAN_STA_MFP))
key->conf.flags |= IEEE80211_KEY_FLAG_RX_MGMT;
@@ -718,13 +720,11 @@ static int ieee80211_add_key(struct wiphy *wiphy, struct wireless_dev *wdev,
case NL80211_IFTYPE_WDS:
case NL80211_IFTYPE_MONITOR:
case NL80211_IFTYPE_P2P_DEVICE:
- case NL80211_IFTYPE_NAN:
case NL80211_IFTYPE_UNSPECIFIED:
case NUM_NL80211_IFTYPES:
case NL80211_IFTYPE_P2P_CLIENT:
case NL80211_IFTYPE_P2P_GO:
case NL80211_IFTYPE_OCB:
- case NL80211_IFTYPE_NAN_DATA:
/* shouldn't happen */
WARN_ON_ONCE(1);
break;
--
2.34.1
prev parent reply other threads:[~2026-03-26 10:15 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-26 10:14 [PATCH v2 wireless-next 00/15] wifi: mac80211: add NAN support Miri Korenblit
2026-03-26 10:14 ` [PATCH v2 wireless-next 01/15] wifi: mac80211: add a TXQ for management frames on NAN devices Miri Korenblit
2026-03-26 10:14 ` [PATCH v2 wireless-next 02/15] wifi: ieee80211: add more NAN definitions Miri Korenblit
2026-03-26 10:14 ` [PATCH v2 wireless-next 03/15] wifi: mac80211: export ieee80211_calculate_rx_timestamp Miri Korenblit
2026-03-26 10:14 ` [PATCH v2 wireless-next 04/15] wifi: mac80211: run NAN DE code only when appropriate Miri Korenblit
2026-03-26 10:14 ` [PATCH v2 wireless-next 05/15] wifi: mac80211: add NAN local schedule support Miri Korenblit
2026-03-26 10:14 ` [PATCH v2 wireless-next 06/15] wifi: mac80211: support open and close for NAN_DATA interfaces Miri Korenblit
2026-03-26 10:14 ` [PATCH v2 wireless-next 07/15] wifi: mac80211: handle reconfig for NAN DATA interfaces Miri Korenblit
2026-03-26 10:14 ` [PATCH v2 wireless-next 08/15] wifi: mac80211: support NAN stations Miri Korenblit
2026-03-26 10:14 ` [PATCH v2 wireless-next 09/15] wifi: mac80211: add NAN peer schedule support Miri Korenblit
2026-03-26 10:14 ` [PATCH v2 wireless-next 10/15] wifi: mac80211: update NAN data path state on schedule changes Miri Korenblit
2026-03-26 10:14 ` [PATCH v2 wireless-next 11/15] wifi: mac80211: add support for TX over NAN_DATA interfaces Miri Korenblit
2026-03-26 10:14 ` [PATCH v2 wireless-next 12/15] wifi: mac80211: Accept frames on NAN DATA interfaces Miri Korenblit
2026-03-26 10:14 ` [PATCH v2 wireless-next 13/15] wifi: mac80211: allow block ack agreements in NAN Data Miri Korenblit
2026-03-26 10:14 ` [PATCH v2 wireless-next 14/15] wifi: mac80211: report and drop spurious NAN Data frames Miri Korenblit
2026-03-26 10:14 ` Miri Korenblit [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260326121156.34961ba9a0c4.I5b7c646c456d4112e5ab8663026153ace9b6b7d6@changeid \
--to=miriam.rachel.korenblit@intel.com \
--cc=avraham.stern@intel.com \
--cc=ilan.peer@intel.com \
--cc=linux-wireless@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox