diff options
author | Jouni Malinen <jouni.malinen@atheros.com> | 2009-01-13 09:03:29 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-01-29 16:00:35 -0500 |
commit | 9aed3cc124343d92be6697e9af3928bdfe8eb03e (patch) | |
tree | 6a49a68422656790f944f37e3f34379b753d1dab /include/net/cfg80211.h | |
parent | 0c1aa495961f03c964b3287cf5800217cf6f2cee (diff) |
nl80211: New command for adding extra IE(s) into management frames
A new nl80211 command, NL80211_CMD_SET_MGMT_EXTRA_IE, can be used to
add arbitrary IE data into the end of management frames. The interface
allows extra IEs to be configured for each management frame subtype, but
only some of them (ProbeReq, ProbeResp, Auth, (Re)AssocReq, Deauth,
Disassoc) are currently accepted in mac80211 implementation.
This makes it easier to implement IEEE 802.11 extensions like WPS and
FT that add IE(s) into some management frames. In addition, this can
be useful for testing and experimentation purposes.
Signed-off-by: Jouni Malinen <jouni.malinen@atheros.com>
Acked-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'include/net/cfg80211.h')
-rw-r--r-- | include/net/cfg80211.h | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/include/net/cfg80211.h b/include/net/cfg80211.h index df78abc496f1..c7da88fb15b7 100644 --- a/include/net/cfg80211.h +++ b/include/net/cfg80211.h | |||
@@ -433,6 +433,26 @@ struct ieee80211_txq_params { | |||
433 | u8 aifs; | 433 | u8 aifs; |
434 | }; | 434 | }; |
435 | 435 | ||
436 | /** | ||
437 | * struct mgmt_extra_ie_params - Extra management frame IE parameters | ||
438 | * | ||
439 | * Used to add extra IE(s) into management frames. If the driver cannot add the | ||
440 | * requested data into all management frames of the specified subtype that are | ||
441 | * generated in kernel or firmware/hardware, it must reject the configuration | ||
442 | * call. The IE data buffer is added to the end of the specified management | ||
443 | * frame body after all other IEs. This addition is not applied to frames that | ||
444 | * are injected through a monitor interface. | ||
445 | * | ||
446 | * @subtype: Management frame subtype | ||
447 | * @ies: IE data buffer or %NULL to remove previous data | ||
448 | * @ies_len: Length of @ies in octets | ||
449 | */ | ||
450 | struct mgmt_extra_ie_params { | ||
451 | u8 subtype; | ||
452 | u8 *ies; | ||
453 | int ies_len; | ||
454 | }; | ||
455 | |||
436 | /* from net/wireless.h */ | 456 | /* from net/wireless.h */ |
437 | struct wiphy; | 457 | struct wiphy; |
438 | 458 | ||
@@ -501,6 +521,8 @@ struct ieee80211_channel; | |||
501 | * @set_txq_params: Set TX queue parameters | 521 | * @set_txq_params: Set TX queue parameters |
502 | * | 522 | * |
503 | * @set_channel: Set channel | 523 | * @set_channel: Set channel |
524 | * | ||
525 | * @set_mgmt_extra_ie: Set extra IE data for management frames | ||
504 | */ | 526 | */ |
505 | struct cfg80211_ops { | 527 | struct cfg80211_ops { |
506 | int (*add_virtual_intf)(struct wiphy *wiphy, char *name, | 528 | int (*add_virtual_intf)(struct wiphy *wiphy, char *name, |
@@ -571,6 +593,10 @@ struct cfg80211_ops { | |||
571 | int (*set_channel)(struct wiphy *wiphy, | 593 | int (*set_channel)(struct wiphy *wiphy, |
572 | struct ieee80211_channel *chan, | 594 | struct ieee80211_channel *chan, |
573 | enum nl80211_channel_type channel_type); | 595 | enum nl80211_channel_type channel_type); |
596 | |||
597 | int (*set_mgmt_extra_ie)(struct wiphy *wiphy, | ||
598 | struct net_device *dev, | ||
599 | struct mgmt_extra_ie_params *params); | ||
574 | }; | 600 | }; |
575 | 601 | ||
576 | /* temporary wext handlers */ | 602 | /* temporary wext handlers */ |