diff options
Diffstat (limited to 'net/mac80211/ieee80211_i.h')
-rw-r--r-- | net/mac80211/ieee80211_i.h | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/net/mac80211/ieee80211_i.h b/net/mac80211/ieee80211_i.h index 8c804550465b..9a058e58d53e 100644 --- a/net/mac80211/ieee80211_i.h +++ b/net/mac80211/ieee80211_i.h | |||
@@ -658,6 +658,30 @@ enum ieee80211_sdata_state_bits { | |||
658 | SDATA_STATE_OFFCHANNEL, | 658 | SDATA_STATE_OFFCHANNEL, |
659 | }; | 659 | }; |
660 | 660 | ||
661 | /** | ||
662 | * enum ieee80211_chanctx_mode - channel context configuration mode | ||
663 | * | ||
664 | * @IEEE80211_CHANCTX_SHARED: channel context may be used by | ||
665 | * multiple interfaces | ||
666 | * @IEEE80211_CHANCTX_EXCLUSIVE: channel context can be used | ||
667 | * only by a single interface. This can be used for example for | ||
668 | * non-fixed channel IBSS. | ||
669 | */ | ||
670 | enum ieee80211_chanctx_mode { | ||
671 | IEEE80211_CHANCTX_SHARED, | ||
672 | IEEE80211_CHANCTX_EXCLUSIVE | ||
673 | }; | ||
674 | |||
675 | struct ieee80211_chanctx { | ||
676 | struct list_head list; | ||
677 | struct rcu_head rcu_head; | ||
678 | |||
679 | enum ieee80211_chanctx_mode mode; | ||
680 | int refcount; | ||
681 | |||
682 | struct ieee80211_chanctx_conf conf; | ||
683 | }; | ||
684 | |||
661 | struct ieee80211_sub_if_data { | 685 | struct ieee80211_sub_if_data { |
662 | struct list_head list; | 686 | struct list_head list; |
663 | 687 | ||
@@ -987,6 +1011,10 @@ struct ieee80211_local { | |||
987 | struct ieee80211_channel *tmp_channel; | 1011 | struct ieee80211_channel *tmp_channel; |
988 | enum nl80211_channel_type tmp_channel_type; | 1012 | enum nl80211_channel_type tmp_channel_type; |
989 | 1013 | ||
1014 | /* channel contexts */ | ||
1015 | struct list_head chanctx_list; | ||
1016 | struct mutex chanctx_mtx; | ||
1017 | |||
990 | /* SNMP counters */ | 1018 | /* SNMP counters */ |
991 | /* dot11CountersTable */ | 1019 | /* dot11CountersTable */ |
992 | u32 dot11TransmittedFragmentCount; | 1020 | u32 dot11TransmittedFragmentCount; |
@@ -1510,6 +1538,13 @@ bool ieee80211_set_channel_type(struct ieee80211_local *local, | |||
1510 | enum nl80211_channel_type | 1538 | enum nl80211_channel_type |
1511 | ieee80211_ht_oper_to_channel_type(struct ieee80211_ht_operation *ht_oper); | 1539 | ieee80211_ht_oper_to_channel_type(struct ieee80211_ht_operation *ht_oper); |
1512 | 1540 | ||
1541 | int __must_check | ||
1542 | ieee80211_vif_use_channel(struct ieee80211_sub_if_data *sdata, | ||
1543 | struct ieee80211_channel *channel, | ||
1544 | enum nl80211_channel_type channel_type, | ||
1545 | enum ieee80211_chanctx_mode mode); | ||
1546 | void ieee80211_vif_release_channel(struct ieee80211_sub_if_data *sdata); | ||
1547 | |||
1513 | #ifdef CONFIG_MAC80211_NOINLINE | 1548 | #ifdef CONFIG_MAC80211_NOINLINE |
1514 | #define debug_noinline noinline | 1549 | #define debug_noinline noinline |
1515 | #else | 1550 | #else |