aboutsummaryrefslogtreecommitdiffstats
path: root/include/net/cfg80211.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/net/cfg80211.h')
-rw-r--r--include/net/cfg80211.h84
1 files changed, 84 insertions, 0 deletions
diff --git a/include/net/cfg80211.h b/include/net/cfg80211.h
index 23c0ab74ded6..dd1fd51638fc 100644
--- a/include/net/cfg80211.h
+++ b/include/net/cfg80211.h
@@ -112,12 +112,14 @@ struct beacon_parameters {
112 * @STATION_FLAG_SHORT_PREAMBLE: station is capable of receiving frames 112 * @STATION_FLAG_SHORT_PREAMBLE: station is capable of receiving frames
113 * with short preambles 113 * with short preambles
114 * @STATION_FLAG_WME: station is WME/QoS capable 114 * @STATION_FLAG_WME: station is WME/QoS capable
115 * @STATION_FLAG_MFP: station uses management frame protection
115 */ 116 */
116enum station_flags { 117enum station_flags {
117 STATION_FLAG_CHANGED = 1<<0, 118 STATION_FLAG_CHANGED = 1<<0,
118 STATION_FLAG_AUTHORIZED = 1<<NL80211_STA_FLAG_AUTHORIZED, 119 STATION_FLAG_AUTHORIZED = 1<<NL80211_STA_FLAG_AUTHORIZED,
119 STATION_FLAG_SHORT_PREAMBLE = 1<<NL80211_STA_FLAG_SHORT_PREAMBLE, 120 STATION_FLAG_SHORT_PREAMBLE = 1<<NL80211_STA_FLAG_SHORT_PREAMBLE,
120 STATION_FLAG_WME = 1<<NL80211_STA_FLAG_WME, 121 STATION_FLAG_WME = 1<<NL80211_STA_FLAG_WME,
122 STATION_FLAG_MFP = 1<<NL80211_STA_FLAG_MFP,
121}; 123};
122 124
123/** 125/**
@@ -355,6 +357,51 @@ enum reg_set_by {
355 REGDOM_SET_BY_COUNTRY_IE, 357 REGDOM_SET_BY_COUNTRY_IE,
356}; 358};
357 359
360/**
361 * enum environment_cap - Environment parsed from country IE
362 * @ENVIRON_ANY: indicates country IE applies to both indoor and
363 * outdoor operation.
364 * @ENVIRON_INDOOR: indicates country IE applies only to indoor operation
365 * @ENVIRON_OUTDOOR: indicates country IE applies only to outdoor operation
366 */
367enum environment_cap {
368 ENVIRON_ANY,
369 ENVIRON_INDOOR,
370 ENVIRON_OUTDOOR,
371};
372
373/**
374 * struct regulatory_request - receipt of last regulatory request
375 *
376 * @wiphy: this is set if this request's initiator is
377 * %REGDOM_SET_BY_COUNTRY_IE or %REGDOM_SET_BY_DRIVER. This
378 * can be used by the wireless core to deal with conflicts
379 * and potentially inform users of which devices specifically
380 * cased the conflicts.
381 * @initiator: indicates who sent this request, could be any of
382 * of those set in reg_set_by, %REGDOM_SET_BY_*
383 * @alpha2: the ISO / IEC 3166 alpha2 country code of the requested
384 * regulatory domain. We have a few special codes:
385 * 00 - World regulatory domain
386 * 99 - built by driver but a specific alpha2 cannot be determined
387 * 98 - result of an intersection between two regulatory domains
388 * @intersect: indicates whether the wireless core should intersect
389 * the requested regulatory domain with the presently set regulatory
390 * domain.
391 * @country_ie_checksum: checksum of the last processed and accepted
392 * country IE
393 * @country_ie_env: lets us know if the AP is telling us we are outdoor,
394 * indoor, or if it doesn't matter
395 */
396struct regulatory_request {
397 struct wiphy *wiphy;
398 enum reg_set_by initiator;
399 char alpha2[2];
400 bool intersect;
401 u32 country_ie_checksum;
402 enum environment_cap country_ie_env;
403};
404
358struct ieee80211_freq_range { 405struct ieee80211_freq_range {
359 u32 start_freq_khz; 406 u32 start_freq_khz;
360 u32 end_freq_khz; 407 u32 end_freq_khz;
@@ -431,6 +478,26 @@ struct ieee80211_txq_params {
431 u8 aifs; 478 u8 aifs;
432}; 479};
433 480
481/**
482 * struct mgmt_extra_ie_params - Extra management frame IE parameters
483 *
484 * Used to add extra IE(s) into management frames. If the driver cannot add the
485 * requested data into all management frames of the specified subtype that are
486 * generated in kernel or firmware/hardware, it must reject the configuration
487 * call. The IE data buffer is added to the end of the specified management
488 * frame body after all other IEs. This addition is not applied to frames that
489 * are injected through a monitor interface.
490 *
491 * @subtype: Management frame subtype
492 * @ies: IE data buffer or %NULL to remove previous data
493 * @ies_len: Length of @ies in octets
494 */
495struct mgmt_extra_ie_params {
496 u8 subtype;
497 u8 *ies;
498 int ies_len;
499};
500
434/* from net/wireless.h */ 501/* from net/wireless.h */
435struct wiphy; 502struct wiphy;
436 503
@@ -450,6 +517,9 @@ struct ieee80211_channel;
450 * wireless extensions but this is subject to reevaluation as soon as this 517 * wireless extensions but this is subject to reevaluation as soon as this
451 * code is used more widely and we have a first user without wext. 518 * code is used more widely and we have a first user without wext.
452 * 519 *
520 * @suspend: wiphy device needs to be suspended
521 * @resume: wiphy device needs to be resumed
522 *
453 * @add_virtual_intf: create a new virtual interface with the given name, 523 * @add_virtual_intf: create a new virtual interface with the given name,
454 * must set the struct wireless_dev's iftype. 524 * must set the struct wireless_dev's iftype.
455 * 525 *
@@ -471,6 +541,8 @@ struct ieee80211_channel;
471 * 541 *
472 * @set_default_key: set the default key on an interface 542 * @set_default_key: set the default key on an interface
473 * 543 *
544 * @set_default_mgmt_key: set the default management frame key on an interface
545 *
474 * @add_beacon: Add a beacon with given parameters, @head, @interval 546 * @add_beacon: Add a beacon with given parameters, @head, @interval
475 * and @dtim_period will be valid, @tail is optional. 547 * and @dtim_period will be valid, @tail is optional.
476 * @set_beacon: Change the beacon parameters for an access point mode 548 * @set_beacon: Change the beacon parameters for an access point mode
@@ -497,8 +569,13 @@ struct ieee80211_channel;
497 * @set_txq_params: Set TX queue parameters 569 * @set_txq_params: Set TX queue parameters
498 * 570 *
499 * @set_channel: Set channel 571 * @set_channel: Set channel
572 *
573 * @set_mgmt_extra_ie: Set extra IE data for management frames
500 */ 574 */
501struct cfg80211_ops { 575struct cfg80211_ops {
576 int (*suspend)(struct wiphy *wiphy);
577 int (*resume)(struct wiphy *wiphy);
578
502 int (*add_virtual_intf)(struct wiphy *wiphy, char *name, 579 int (*add_virtual_intf)(struct wiphy *wiphy, char *name,
503 enum nl80211_iftype type, u32 *flags, 580 enum nl80211_iftype type, u32 *flags,
504 struct vif_params *params); 581 struct vif_params *params);
@@ -518,6 +595,9 @@ struct cfg80211_ops {
518 int (*set_default_key)(struct wiphy *wiphy, 595 int (*set_default_key)(struct wiphy *wiphy,
519 struct net_device *netdev, 596 struct net_device *netdev,
520 u8 key_index); 597 u8 key_index);
598 int (*set_default_mgmt_key)(struct wiphy *wiphy,
599 struct net_device *netdev,
600 u8 key_index);
521 601
522 int (*add_beacon)(struct wiphy *wiphy, struct net_device *dev, 602 int (*add_beacon)(struct wiphy *wiphy, struct net_device *dev,
523 struct beacon_parameters *info); 603 struct beacon_parameters *info);
@@ -564,6 +644,10 @@ struct cfg80211_ops {
564 int (*set_channel)(struct wiphy *wiphy, 644 int (*set_channel)(struct wiphy *wiphy,
565 struct ieee80211_channel *chan, 645 struct ieee80211_channel *chan,
566 enum nl80211_channel_type channel_type); 646 enum nl80211_channel_type channel_type);
647
648 int (*set_mgmt_extra_ie)(struct wiphy *wiphy,
649 struct net_device *dev,
650 struct mgmt_extra_ie_params *params);
567}; 651};
568 652
569/* temporary wext handlers */ 653/* temporary wext handlers */