nl80211: modify TID-config API
Make some changes to the TID-config API: * use u16 in nl80211 (only, and restrict to using 8 bits for now), to avoid issues in the future if we ever want to use higher TIDs. * reject empty TIDs mask (via netlink policy) * change feature advertising to not use extended feature flags but have own mechanism for this, which simplifies the code * fix all variable names from 'tid' to 'tids' since it's a mask * change to cfg80211_ name prefixes, not ieee80211_ * fix some minor docs/spelling things. Change-Id: Ia234d464b3f914cdeab82f540e018855be580dce Signed-off-by: Johannes Berg <johannes.berg@intel.com>
This commit is contained in:
@@ -626,36 +626,32 @@ struct cfg80211_chan_def {
|
||||
struct ieee80211_edmg edmg;
|
||||
};
|
||||
|
||||
enum ieee80211_tid_conf_mask {
|
||||
IEEE80211_TID_CONF_NOACK = BIT(NL80211_TID_CONFIG_ATTR_NOACK),
|
||||
};
|
||||
|
||||
/**
|
||||
* struct ieee80211_tid_cfg - TID specific configuration
|
||||
* struct cfg80211_tid_cfg - TID specific configuration
|
||||
* @config_override: Flag to notify driver to reset TID configuration
|
||||
* of the peer.
|
||||
* @tid: TID number
|
||||
* @tid_conf_mask: bitmap indicating which parameter changed
|
||||
* see &enum ieee80211_tid_conf_mask
|
||||
* @tids: bitmap of TIDs to modify
|
||||
* @mask: bitmap of attributes indicating which parameter changed,
|
||||
* similar to &nl80211_tid_config_supp.
|
||||
* @noack: noack configuration value for the TID
|
||||
*/
|
||||
struct ieee80211_tid_cfg {
|
||||
struct cfg80211_tid_cfg {
|
||||
bool config_override;
|
||||
u8 tid;
|
||||
u32 tid_conf_mask;
|
||||
u8 tids;
|
||||
u32 mask;
|
||||
enum nl80211_tid_config noack;
|
||||
};
|
||||
|
||||
/**
|
||||
* struct ieee80211_tid_config - TID configuration
|
||||
* struct cfg80211_tid_config - TID configuration
|
||||
* @peer: Station's MAC address
|
||||
* @n_tid_conf: Number of TID specific configurations to be applied
|
||||
* @tid_conf: Configuration change info
|
||||
*/
|
||||
struct ieee80211_tid_config {
|
||||
struct cfg80211_tid_config {
|
||||
const u8 *peer;
|
||||
u32 n_tid_conf;
|
||||
struct ieee80211_tid_cfg tid_conf[];
|
||||
struct cfg80211_tid_cfg tid_conf[];
|
||||
};
|
||||
|
||||
/**
|
||||
@@ -3705,8 +3701,8 @@ struct cfg80211_update_owe_info {
|
||||
* and overrule HWMP path selection algorithm.
|
||||
* @set_tid_config: TID specific configuration, this can be peer or BSS specific
|
||||
* This callback may sleep.
|
||||
* @reset_tid_config: Reset TID specific configuration for the peer.
|
||||
* This callback may sleep.
|
||||
* @reset_tid_config: Reset TID specific configuration for the peer, for the
|
||||
* given TIDs. This callback may sleep.
|
||||
*/
|
||||
struct cfg80211_ops {
|
||||
int (*suspend)(struct wiphy *wiphy, struct cfg80211_wowlan *wow);
|
||||
@@ -4031,9 +4027,9 @@ struct cfg80211_ops {
|
||||
int (*probe_mesh_link)(struct wiphy *wiphy, struct net_device *dev,
|
||||
const u8 *buf, size_t len);
|
||||
int (*set_tid_config)(struct wiphy *wiphy, struct net_device *dev,
|
||||
struct ieee80211_tid_config *tid_conf);
|
||||
struct cfg80211_tid_config *tid_conf);
|
||||
int (*reset_tid_config)(struct wiphy *wiphy, struct net_device *dev,
|
||||
const u8 *peer, u8 tid);
|
||||
const u8 *peer, u8 tids);
|
||||
};
|
||||
|
||||
/*
|
||||
@@ -4641,6 +4637,13 @@ struct wiphy_iftype_akm_suites {
|
||||
* @support_mbssid must be set for this to have any effect.
|
||||
*
|
||||
* @pmsr_capa: peer measurement capabilities
|
||||
*
|
||||
* @tid_config_support: describes the per-TID config support that the
|
||||
* device has
|
||||
* @tid_config_support.vif: bitmap of attributes (configurations)
|
||||
* supported by the driver for each vif
|
||||
* @tid_config_support.peer: bitmap of attributes (configurations)
|
||||
* supported by the driver for each peer
|
||||
*/
|
||||
struct wiphy {
|
||||
/* assign these fields before you register the wiphy */
|
||||
@@ -4772,6 +4775,10 @@ struct wiphy {
|
||||
|
||||
const struct cfg80211_pmsr_capabilities *pmsr_capa;
|
||||
|
||||
struct {
|
||||
u64 peer, vif;
|
||||
} tid_config_support;
|
||||
|
||||
char priv[0] __aligned(NETDEV_ALIGN);
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user