Skip to contentSkip to conversation

nl80211: Indicate driver-based offchannel TX on mgmt_tx_cancel_wait

PATCH In review Jouni Malinen 2 participants 3 messages Aug 8, 2011 802.11 (including cfg80211/NL80211)

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 nl80211: Indicate driver-based offchannel TX on mgmt_tx_cancel_wait

Drivers that support frame transmission with mgmt_tx() may not support driver-based offchannel TX. Use mgmt_tx_cancel_wait instead of mgmt_tx when figuring out whether to indicate support for this with NL80211_ATTR_OFFCHANNEL_TX_OK.

---
 net/wireless/nl80211.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)
net/wireless/nl80211.c +1 -2
index ec8444e..ca76977 100644
@@ -871,8 +871,7 @@ static int nl80211_send_wiphy(struct sk_buff *msg, u32 pid, u32 seq, int flags,
 		NLA_PUT_U32(msg, NL80211_ATTR_MAX_REMAIN_ON_CHANNEL_DURATION,
 			    dev->wiphy.max_remain_on_channel_duration);
 
-	/* for now at least assume all drivers have it */
-	if (dev->ops->mgmt_tx)
+	if (dev->ops->mgmt_tx_cancel_wait)
 		NLA_PUT_FLAG(msg, NL80211_ATTR_OFFCHANNEL_TX_OK);
 
 	if (mgmt_stypes) {
Signature · 5 lines
1.7.4.1


-- 
Jouni Malinen                                            PGP id EFC895FA
maintainer Acked-by on v1 1/1
#1 lore raw
Quoted 4 lines · Jouni Malinen

Drivers that support frame transmission with mgmt_tx() may not support driver-based offchannel TX. Use mgmt_tx_cancel_wait instead of mgmt_tx when figuring out whether to indicate support for this with NL80211_ATTR_OFFCHANNEL_TX_OK.

Seems fine to me, I guess the driver in question isn't in the tree yet so no need for Cc: stable?

Quoted 23 lines
---
 net/wireless/nl80211.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)
net/wireless/nl80211.c +1 -2
index ec8444e..ca76977 100644
@@ -871,8 +871,7 @@ static int nl80211_send_wiphy(struct sk_buff *msg, u32 pid, u32 seq, int flags,
 		NLA_PUT_U32(msg, NL80211_ATTR_MAX_REMAIN_ON_CHANNEL_DURATION,
 			    dev->wiphy.max_remain_on_channel_duration);
 
-	/* for now at least assume all drivers have it */
-	if (dev->ops->mgmt_tx)
+	if (dev->ops->mgmt_tx_cancel_wait)
 		NLA_PUT_FLAG(msg, NL80211_ATTR_OFFCHANNEL_TX_OK);
 
 	if (mgmt_stypes) {
Signature · 1 line
1.7.4.1
#2 lore raw
Quoted 2 lines · Johannes Berg

Seems fine to me, I guess the driver in question isn't in the tree yet so no need for Cc: stable?

Well, the driver (ath6kl) is, but it does not yet have this functionality in the main tree, so no need for stable.

Signature · 1 line
Jouni Malinen                                            PGP id EFC895FA