diff options
Diffstat (limited to 'net/mac80211/ieee80211_i.h')
-rw-r--r-- | net/mac80211/ieee80211_i.h | 67 |
1 files changed, 31 insertions, 36 deletions
diff --git a/net/mac80211/ieee80211_i.h b/net/mac80211/ieee80211_i.h index 02a8753a4eca..cbea0154ee3a 100644 --- a/net/mac80211/ieee80211_i.h +++ b/net/mac80211/ieee80211_i.h | |||
@@ -237,8 +237,6 @@ struct ieee80211_if_ap { | |||
237 | struct sk_buff_head ps_bc_buf; | 237 | struct sk_buff_head ps_bc_buf; |
238 | atomic_t num_sta_ps; /* number of stations in PS mode */ | 238 | atomic_t num_sta_ps; /* number of stations in PS mode */ |
239 | int dtim_count; | 239 | int dtim_count; |
240 | int force_unicast_rateidx; /* forced TX rateidx for unicast frames */ | ||
241 | int max_ratectrl_rateidx; /* max TX rateidx for rate control */ | ||
242 | int num_beacons; /* number of TXed beacon frames for this BSS */ | 240 | int num_beacons; /* number of TXed beacon frames for this BSS */ |
243 | }; | 241 | }; |
244 | 242 | ||
@@ -248,7 +246,6 @@ struct ieee80211_if_wds { | |||
248 | }; | 246 | }; |
249 | 247 | ||
250 | struct ieee80211_if_vlan { | 248 | struct ieee80211_if_vlan { |
251 | struct ieee80211_sub_if_data *ap; | ||
252 | struct list_head list; | 249 | struct list_head list; |
253 | }; | 250 | }; |
254 | 251 | ||
@@ -422,8 +419,6 @@ struct ieee80211_sub_if_data { | |||
422 | */ | 419 | */ |
423 | u64 basic_rates; | 420 | u64 basic_rates; |
424 | 421 | ||
425 | u16 sequence; | ||
426 | |||
427 | /* Fragment table for host-based reassembly */ | 422 | /* Fragment table for host-based reassembly */ |
428 | struct ieee80211_fragment_entry fragments[IEEE80211_FRAGMENT_MAX]; | 423 | struct ieee80211_fragment_entry fragments[IEEE80211_FRAGMENT_MAX]; |
429 | unsigned int fragment_next; | 424 | unsigned int fragment_next; |
@@ -432,16 +427,18 @@ struct ieee80211_sub_if_data { | |||
432 | struct ieee80211_key *keys[NUM_DEFAULT_KEYS]; | 427 | struct ieee80211_key *keys[NUM_DEFAULT_KEYS]; |
433 | struct ieee80211_key *default_key; | 428 | struct ieee80211_key *default_key; |
434 | 429 | ||
430 | /* BSS configuration for this interface. */ | ||
431 | struct ieee80211_bss_conf bss_conf; | ||
432 | |||
435 | /* | 433 | /* |
436 | * BSS configuration for this interface. | 434 | * AP this belongs to: self in AP mode and |
437 | * | 435 | * corresponding AP in VLAN mode, NULL for |
438 | * FIXME: I feel bad putting this here when we already have a | 436 | * all others (might be needed later in IBSS) |
439 | * bss pointer, but the bss pointer is just wrong when | ||
440 | * you have multiple virtual STA mode interfaces... | ||
441 | * This needs to be fixed. | ||
442 | */ | 437 | */ |
443 | struct ieee80211_bss_conf bss_conf; | 438 | struct ieee80211_if_ap *bss; |
444 | struct ieee80211_if_ap *bss; /* BSS that this device belongs to */ | 439 | |
440 | int force_unicast_rateidx; /* forced TX rateidx for unicast frames */ | ||
441 | int max_ratectrl_rateidx; /* max TX rateidx for rate control */ | ||
445 | 442 | ||
446 | union { | 443 | union { |
447 | struct ieee80211_if_ap ap; | 444 | struct ieee80211_if_ap ap; |
@@ -533,8 +530,6 @@ struct ieee80211_sub_if_data *vif_to_sdata(struct ieee80211_vif *p) | |||
533 | return container_of(p, struct ieee80211_sub_if_data, vif); | 530 | return container_of(p, struct ieee80211_sub_if_data, vif); |
534 | } | 531 | } |
535 | 532 | ||
536 | #define IEEE80211_DEV_TO_SUB_IF(dev) netdev_priv(dev) | ||
537 | |||
538 | enum { | 533 | enum { |
539 | IEEE80211_RX_MSG = 1, | 534 | IEEE80211_RX_MSG = 1, |
540 | IEEE80211_TX_STATUS_MSG = 2, | 535 | IEEE80211_TX_STATUS_MSG = 2, |
@@ -561,12 +556,6 @@ struct ieee80211_local { | |||
561 | bool tim_in_locked_section; /* see ieee80211_beacon_get() */ | 556 | bool tim_in_locked_section; /* see ieee80211_beacon_get() */ |
562 | int tx_headroom; /* required headroom for hardware/radiotap */ | 557 | int tx_headroom; /* required headroom for hardware/radiotap */ |
563 | 558 | ||
564 | enum { | ||
565 | IEEE80211_DEV_UNINITIALIZED = 0, | ||
566 | IEEE80211_DEV_REGISTERED, | ||
567 | IEEE80211_DEV_UNREGISTERED, | ||
568 | } reg_state; | ||
569 | |||
570 | /* Tasklet and skb queue to process calls from IRQ mode. All frames | 559 | /* Tasklet and skb queue to process calls from IRQ mode. All frames |
571 | * added to skb_queue will be processed, but frames in | 560 | * added to skb_queue will be processed, but frames in |
572 | * skb_queue_unreliable may be dropped if the total length of these | 561 | * skb_queue_unreliable may be dropped if the total length of these |
@@ -760,6 +749,16 @@ static inline int ieee80211_is_multiqueue(struct ieee80211_local *local) | |||
760 | #endif | 749 | #endif |
761 | } | 750 | } |
762 | 751 | ||
752 | static inline struct ieee80211_sub_if_data * | ||
753 | IEEE80211_DEV_TO_SUB_IF(struct net_device *dev) | ||
754 | { | ||
755 | struct ieee80211_local *local = wdev_priv(dev->ieee80211_ptr); | ||
756 | |||
757 | BUG_ON(!local || local->mdev == dev); | ||
758 | |||
759 | return netdev_priv(dev); | ||
760 | } | ||
761 | |||
763 | /* this struct represents 802.11n's RA/TID combination */ | 762 | /* this struct represents 802.11n's RA/TID combination */ |
764 | struct ieee80211_ra_tid { | 763 | struct ieee80211_ra_tid { |
765 | u8 ra[ETH_ALEN]; | 764 | u8 ra[ETH_ALEN]; |
@@ -853,10 +852,8 @@ static inline int ieee80211_bssid_match(const u8 *raddr, const u8 *addr) | |||
853 | 852 | ||
854 | /* ieee80211.c */ | 853 | /* ieee80211.c */ |
855 | int ieee80211_hw_config(struct ieee80211_local *local); | 854 | int ieee80211_hw_config(struct ieee80211_local *local); |
856 | int ieee80211_if_config(struct net_device *dev); | 855 | int ieee80211_if_config(struct ieee80211_sub_if_data *sdata, u32 changed); |
857 | int ieee80211_if_config_beacon(struct net_device *dev); | ||
858 | void ieee80211_tx_set_protected(struct ieee80211_tx_data *tx); | 856 | void ieee80211_tx_set_protected(struct ieee80211_tx_data *tx); |
859 | void ieee80211_if_setup(struct net_device *dev); | ||
860 | u32 ieee80211_handle_ht(struct ieee80211_local *local, int enable_ht, | 857 | u32 ieee80211_handle_ht(struct ieee80211_local *local, int enable_ht, |
861 | struct ieee80211_ht_info *req_ht_cap, | 858 | struct ieee80211_ht_info *req_ht_cap, |
862 | struct ieee80211_ht_bss_info *req_bss_cap); | 859 | struct ieee80211_ht_bss_info *req_bss_cap); |
@@ -883,8 +880,8 @@ int ieee80211_sta_scan_results(struct net_device *dev, | |||
883 | ieee80211_rx_result ieee80211_sta_rx_scan( | 880 | ieee80211_rx_result ieee80211_sta_rx_scan( |
884 | struct net_device *dev, struct sk_buff *skb, | 881 | struct net_device *dev, struct sk_buff *skb, |
885 | struct ieee80211_rx_status *rx_status); | 882 | struct ieee80211_rx_status *rx_status); |
886 | void ieee80211_rx_bss_list_init(struct net_device *dev); | 883 | void ieee80211_rx_bss_list_init(struct ieee80211_local *local); |
887 | void ieee80211_rx_bss_list_deinit(struct net_device *dev); | 884 | void ieee80211_rx_bss_list_deinit(struct ieee80211_local *local); |
888 | int ieee80211_sta_set_extra_ie(struct net_device *dev, char *ie, size_t len); | 885 | int ieee80211_sta_set_extra_ie(struct net_device *dev, char *ie, size_t len); |
889 | struct sta_info *ieee80211_ibss_add_sta(struct net_device *dev, | 886 | struct sta_info *ieee80211_ibss_add_sta(struct net_device *dev, |
890 | struct sk_buff *skb, u8 *bssid, | 887 | struct sk_buff *skb, u8 *bssid, |
@@ -925,17 +922,15 @@ static inline void ieee80211_start_mesh(struct net_device *dev) | |||
925 | {} | 922 | {} |
926 | #endif | 923 | #endif |
927 | 924 | ||
928 | /* ieee80211_iface.c */ | 925 | /* interface handling */ |
929 | int ieee80211_if_add(struct net_device *dev, const char *name, | 926 | void ieee80211_if_setup(struct net_device *dev); |
930 | struct net_device **new_dev, int type, | 927 | int ieee80211_if_add(struct ieee80211_local *local, const char *name, |
928 | struct net_device **new_dev, enum ieee80211_if_types type, | ||
931 | struct vif_params *params); | 929 | struct vif_params *params); |
932 | void ieee80211_if_set_type(struct net_device *dev, int type); | 930 | int ieee80211_if_change_type(struct ieee80211_sub_if_data *sdata, |
933 | void ieee80211_if_reinit(struct net_device *dev); | 931 | enum ieee80211_if_types type); |
934 | void __ieee80211_if_del(struct ieee80211_local *local, | 932 | void ieee80211_if_remove(struct net_device *dev); |
935 | struct ieee80211_sub_if_data *sdata); | 933 | void ieee80211_remove_interfaces(struct ieee80211_local *local); |
936 | int ieee80211_if_remove(struct net_device *dev, const char *name, int id); | ||
937 | void ieee80211_if_free(struct net_device *dev); | ||
938 | void ieee80211_if_sdata_init(struct ieee80211_sub_if_data *sdata); | ||
939 | 934 | ||
940 | /* tx handling */ | 935 | /* tx handling */ |
941 | void ieee80211_clear_tx_pending(struct ieee80211_local *local); | 936 | void ieee80211_clear_tx_pending(struct ieee80211_local *local); |