diff options
author | Rajkumar Manoharan <rmanohar@qca.qualcomm.com> | 2011-09-25 05:23:30 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2011-09-27 14:34:10 -0400 |
commit | e9f935e3e8dc0bddd0df6d148165d95925422502 (patch) | |
tree | bbb5de5434d0dd0aa7a1b5894320b17ebee434b8 /include | |
parent | 8ebafde00ed0c682fed8c34ac5ba90160ea0bb30 (diff) |
nl80211/cfg80211: Add support to disable CCK rate for management frame
Add a new nl80211 attribute to specify whether to send the management
frames in CCK rate or not. As of now the wpa_supplicant is disabling
CCK rate at P2P init itself. So this patch helps to send P2P probe
request/probe response/action frames being sent at non CCK rate in 2GHz
without disabling 11b rates.
This attribute is used with NL80211_CMD_TRIGGER_SCAN and
NL80211_CMD_FRAME commands to disable CCK rate for management frame
transmission.
Cc: Jouni Malinen <jouni@qca.qualcomm.com>
Signed-off-by: Rajkumar Manoharan <rmanohar@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/nl80211.h | 13 | ||||
-rw-r--r-- | include/net/cfg80211.h | 5 |
2 files changed, 17 insertions, 1 deletions
diff --git a/include/linux/nl80211.h b/include/linux/nl80211.h index 460b12a8ef66..c73582fb9d20 100644 --- a/include/linux/nl80211.h +++ b/include/linux/nl80211.h | |||
@@ -238,6 +238,8 @@ | |||
238 | * | 238 | * |
239 | * @NL80211_CMD_GET_SCAN: get scan results | 239 | * @NL80211_CMD_GET_SCAN: get scan results |
240 | * @NL80211_CMD_TRIGGER_SCAN: trigger a new scan with the given parameters | 240 | * @NL80211_CMD_TRIGGER_SCAN: trigger a new scan with the given parameters |
241 | * %NL80211_ATTR_TX_NO_CCK_RATE is used to decide whether to send the | ||
242 | * probe requests at CCK rate or not. | ||
241 | * @NL80211_CMD_NEW_SCAN_RESULTS: scan notification (as a reply to | 243 | * @NL80211_CMD_NEW_SCAN_RESULTS: scan notification (as a reply to |
242 | * NL80211_CMD_GET_SCAN and on the "scan" multicast group) | 244 | * NL80211_CMD_GET_SCAN and on the "scan" multicast group) |
243 | * @NL80211_CMD_SCAN_ABORTED: scan was aborted, for unspecified reasons, | 245 | * @NL80211_CMD_SCAN_ABORTED: scan was aborted, for unspecified reasons, |
@@ -432,6 +434,8 @@ | |||
432 | * specified using %NL80211_ATTR_DURATION. When called, this operation | 434 | * specified using %NL80211_ATTR_DURATION. When called, this operation |
433 | * returns a cookie (%NL80211_ATTR_COOKIE) that will be included with the | 435 | * returns a cookie (%NL80211_ATTR_COOKIE) that will be included with the |
434 | * TX status event pertaining to the TX request. | 436 | * TX status event pertaining to the TX request. |
437 | * %NL80211_ATTR_TX_NO_CCK_RATE is used to decide whether to send the | ||
438 | * management frames at CCK rate or not in 2GHz band. | ||
435 | * @NL80211_CMD_FRAME_WAIT_CANCEL: When an off-channel TX was requested, this | 439 | * @NL80211_CMD_FRAME_WAIT_CANCEL: When an off-channel TX was requested, this |
436 | * command may be used with the corresponding cookie to cancel the wait | 440 | * command may be used with the corresponding cookie to cancel the wait |
437 | * time if it is known that it is no longer necessary. | 441 | * time if it is known that it is no longer necessary. |
@@ -1078,6 +1082,13 @@ enum nl80211_commands { | |||
1078 | * @NL80211_ATTR_PMKSA_CANDIDATE: Nested attribute containing the PMKSA caching | 1082 | * @NL80211_ATTR_PMKSA_CANDIDATE: Nested attribute containing the PMKSA caching |
1079 | * candidate information, see &enum nl80211_pmksa_candidate_attr. | 1083 | * candidate information, see &enum nl80211_pmksa_candidate_attr. |
1080 | * | 1084 | * |
1085 | * @NL80211_ATTR_TX_NO_CCK_RATE: Indicates whether to use CCK rate or not | ||
1086 | * for management frames transmission. In order to avoid p2p probe/action | ||
1087 | * frames are being transmitted at CCK rate in 2GHz band, the user space | ||
1088 | * applications use this attribute. | ||
1089 | * This attribute is used with %NL80211_CMD_TRIGGER_SCAN and | ||
1090 | * %NL80211_CMD_FRAME commands. | ||
1091 | * | ||
1081 | * @NL80211_ATTR_MAX: highest attribute number currently defined | 1092 | * @NL80211_ATTR_MAX: highest attribute number currently defined |
1082 | * @__NL80211_ATTR_AFTER_LAST: internal use | 1093 | * @__NL80211_ATTR_AFTER_LAST: internal use |
1083 | */ | 1094 | */ |
@@ -1298,6 +1309,8 @@ enum nl80211_attrs { | |||
1298 | 1309 | ||
1299 | NL80211_ATTR_PMKSA_CANDIDATE, | 1310 | NL80211_ATTR_PMKSA_CANDIDATE, |
1300 | 1311 | ||
1312 | NL80211_ATTR_TX_NO_CCK_RATE, | ||
1313 | |||
1301 | /* add attributes here, update the policy in nl80211.c */ | 1314 | /* add attributes here, update the policy in nl80211.c */ |
1302 | 1315 | ||
1303 | __NL80211_ATTR_AFTER_LAST, | 1316 | __NL80211_ATTR_AFTER_LAST, |
diff --git a/include/net/cfg80211.h b/include/net/cfg80211.h index ccfdf3f63ce5..c1dd56b7cce5 100644 --- a/include/net/cfg80211.h +++ b/include/net/cfg80211.h | |||
@@ -860,6 +860,7 @@ struct cfg80211_ssid { | |||
860 | * @wiphy: the wiphy this was for | 860 | * @wiphy: the wiphy this was for |
861 | * @dev: the interface | 861 | * @dev: the interface |
862 | * @aborted: (internal) scan request was notified as aborted | 862 | * @aborted: (internal) scan request was notified as aborted |
863 | * @no_cck: used to send probe requests at non CCK rate in 2GHz band | ||
863 | */ | 864 | */ |
864 | struct cfg80211_scan_request { | 865 | struct cfg80211_scan_request { |
865 | struct cfg80211_ssid *ssids; | 866 | struct cfg80211_ssid *ssids; |
@@ -874,6 +875,7 @@ struct cfg80211_scan_request { | |||
874 | struct wiphy *wiphy; | 875 | struct wiphy *wiphy; |
875 | struct net_device *dev; | 876 | struct net_device *dev; |
876 | bool aborted; | 877 | bool aborted; |
878 | bool no_cck; | ||
877 | 879 | ||
878 | /* keep last */ | 880 | /* keep last */ |
879 | struct ieee80211_channel *channels[0]; | 881 | struct ieee80211_channel *channels[0]; |
@@ -1560,7 +1562,8 @@ struct cfg80211_ops { | |||
1560 | struct ieee80211_channel *chan, bool offchan, | 1562 | struct ieee80211_channel *chan, bool offchan, |
1561 | enum nl80211_channel_type channel_type, | 1563 | enum nl80211_channel_type channel_type, |
1562 | bool channel_type_valid, unsigned int wait, | 1564 | bool channel_type_valid, unsigned int wait, |
1563 | const u8 *buf, size_t len, u64 *cookie); | 1565 | const u8 *buf, size_t len, bool no_cck, |
1566 | u64 *cookie); | ||
1564 | int (*mgmt_tx_cancel_wait)(struct wiphy *wiphy, | 1567 | int (*mgmt_tx_cancel_wait)(struct wiphy *wiphy, |
1565 | struct net_device *dev, | 1568 | struct net_device *dev, |
1566 | u64 cookie); | 1569 | u64 cookie); |