@@ -485,13 +485,15 @@ struct vif_params {
485485 * with the get_key() callback, must be in little endian,
486486 * length given by @seq_len.
487487 * @seq_len: length of @seq.
488+ * @mode: key install mode (RX_TX, NO_TX or SET_TX)
488489 */
489490struct key_params {
490491 const u8 * key ;
491492 const u8 * seq ;
492493 int key_len ;
493494 int seq_len ;
494495 u32 cipher ;
496+ enum nl80211_key_mode mode ;
495497};
496498
497499/**
@@ -973,6 +975,27 @@ enum station_parameters_apply_mask {
973975 STATION_PARAM_APPLY_UAPSD = BIT (0 ),
974976 STATION_PARAM_APPLY_CAPABILITY = BIT (1 ),
975977 STATION_PARAM_APPLY_PLINK_STATE = BIT (2 ),
978+ STATION_PARAM_APPLY_STA_TXPOWER = BIT (3 ),
979+ };
980+
981+ /**
982+ * struct sta_txpwr - station txpower configuration
983+ *
984+ * Used to configure txpower for station.
985+ *
986+ * @power: tx power (in dBm) to be used for sending data traffic. If tx power
987+ * is not provided, the default per-interface tx power setting will be
988+ * overriding. Driver should be picking up the lowest tx power, either tx
989+ * power per-interface or per-station.
990+ * @type: In particular if TPC %type is NL80211_TX_POWER_LIMITED then tx power
991+ * will be less than or equal to specified from userspace, whereas if TPC
992+ * %type is NL80211_TX_POWER_AUTOMATIC then it indicates default tx power.
993+ * NL80211_TX_POWER_FIXED is not a valid configuration option for
994+ * per peer TPC.
995+ */
996+ struct sta_txpwr {
997+ s16 power ;
998+ enum nl80211_tx_power_setting type ;
976999};
9771000
9781001/**
@@ -1047,6 +1070,7 @@ struct station_parameters {
10471070 const struct ieee80211_he_cap_elem * he_capa ;
10481071 u8 he_capa_len ;
10491072 u16 airtime_weight ;
1073+ struct sta_txpwr txpwr ;
10501074};
10511075
10521076/**
@@ -1327,6 +1351,7 @@ struct cfg80211_tid_stats {
13271351 * @fcs_err_count: number of packets (MPDUs) received from this station with
13281352 * an FCS error. This counter should be incremented only when TA of the
13291353 * received packet with an FCS error matches the peer MAC address.
1354+ * @airtime_link_metric: mesh airtime link metric.
13301355 */
13311356struct station_info {
13321357 u64 filled ;
@@ -1381,6 +1406,8 @@ struct station_info {
13811406
13821407 u32 rx_mpdu_count ;
13831408 u32 fcs_err_count ;
1409+
1410+ u32 airtime_link_metric ;
13841411};
13851412
13861413#if IS_ENABLED (CONFIG_CFG80211 )
@@ -1832,11 +1859,19 @@ static inline void get_random_mask_addr(u8 *buf, const u8 *addr, const u8 *mask)
18321859 * @bssid: BSSID to be matched; may be all-zero BSSID in case of SSID match
18331860 * or no match (RSSI only)
18341861 * @rssi_thold: don't report scan results below this threshold (in s32 dBm)
1862+ * @per_band_rssi_thold: Minimum rssi threshold for each band to be applied
1863+ * for filtering out scan results received. Drivers advertize this support
1864+ * of band specific rssi based filtering through the feature capability
1865+ * %NL80211_EXT_FEATURE_SCHED_SCAN_BAND_SPECIFIC_RSSI_THOLD. These band
1866+ * specific rssi thresholds take precedence over rssi_thold, if specified.
1867+ * If not specified for any band, it will be assigned with rssi_thold of
1868+ * corresponding matchset.
18351869 */
18361870struct cfg80211_match_set {
18371871 struct cfg80211_ssid ssid ;
18381872 u8 bssid [ETH_ALEN ];
18391873 s32 rssi_thold ;
1874+ s32 per_band_rssi_thold [NUM_NL80211_BANDS ];
18401875};
18411876
18421877/**
@@ -3099,6 +3134,32 @@ struct cfg80211_pmsr_request {
30993134 struct cfg80211_pmsr_request_peer peers [];
31003135};
31013136
3137+ /**
3138+ * struct cfg80211_update_owe_info - OWE Information
3139+ *
3140+ * This structure provides information needed for the drivers to offload OWE
3141+ * (Opportunistic Wireless Encryption) processing to the user space.
3142+ *
3143+ * Commonly used across update_owe_info request and event interfaces.
3144+ *
3145+ * @peer: MAC address of the peer device for which the OWE processing
3146+ * has to be done.
3147+ * @status: status code, %WLAN_STATUS_SUCCESS for successful OWE info
3148+ * processing, use %WLAN_STATUS_UNSPECIFIED_FAILURE if user space
3149+ * cannot give you the real status code for failures. Used only for
3150+ * OWE update request command interface (user space to driver).
3151+ * @ie: IEs obtained from the peer or constructed by the user space. These are
3152+ * the IEs of the remote peer in the event from the host driver and
3153+ * the constructed IEs by the user space in the request interface.
3154+ * @ie_len: Length of IEs in octets.
3155+ */
3156+ struct cfg80211_update_owe_info {
3157+ u8 peer [ETH_ALEN ] __aligned (2 );
3158+ u16 status ;
3159+ const u8 * ie ;
3160+ size_t ie_len ;
3161+ };
3162+
31023163/**
31033164 * struct cfg80211_ops - backend description for wireless configuration
31043165 *
@@ -3436,6 +3497,13 @@ struct cfg80211_pmsr_request {
34363497 * Statistics should be cumulative, currently no way to reset is provided.
34373498 * @start_pmsr: start peer measurement (e.g. FTM)
34383499 * @abort_pmsr: abort peer measurement
3500+ *
3501+ * @update_owe_info: Provide updated OWE info to driver. Driver implementing SME
3502+ * but offloading OWE processing to the user space will get the updated
3503+ * DH IE through this interface.
3504+ *
3505+ * @probe_mesh_link: Probe direct Mesh peer's link quality by sending data frame
3506+ * and overrule HWMP path selection algorithm.
34393507 */
34403508struct cfg80211_ops {
34413509 int (* suspend )(struct wiphy * wiphy , struct cfg80211_wowlan * wow );
@@ -3750,6 +3818,10 @@ struct cfg80211_ops {
37503818 struct cfg80211_pmsr_request * request );
37513819 void (* abort_pmsr )(struct wiphy * wiphy , struct wireless_dev * wdev ,
37523820 struct cfg80211_pmsr_request * request );
3821+ int (* update_owe_info )(struct wiphy * wiphy , struct net_device * dev ,
3822+ struct cfg80211_update_owe_info * owe_info );
3823+ int (* probe_mesh_link )(struct wiphy * wiphy , struct net_device * dev ,
3824+ const u8 * buf , size_t len );
37533825};
37543826
37553827/*
@@ -5491,6 +5563,28 @@ static inline void cfg80211_gen_new_bssid(const u8 *bssid, u8 max_bssid,
54915563 u64_to_ether_addr (new_bssid_u64 , new_bssid );
54925564}
54935565
5566+ /**
5567+ * cfg80211_is_element_inherited - returns if element ID should be inherited
5568+ * @element: element to check
5569+ * @non_inherit_element: non inheritance element
5570+ */
5571+ bool cfg80211_is_element_inherited (const struct element * element ,
5572+ const struct element * non_inherit_element );
5573+
5574+ /**
5575+ * cfg80211_merge_profile - merges a MBSSID profile if it is split between IEs
5576+ * @ie: ies
5577+ * @ielen: length of IEs
5578+ * @mbssid_elem: current MBSSID element
5579+ * @sub_elem: current MBSSID subelement (profile)
5580+ * @merged_ie: location of the merged profile
5581+ * @max_copy_len: max merged profile length
5582+ */
5583+ size_t cfg80211_merge_profile (const u8 * ie , size_t ielen ,
5584+ const struct element * mbssid_elem ,
5585+ const struct element * sub_elem ,
5586+ u8 * merged_ie , size_t max_copy_len );
5587+
54945588/**
54955589 * enum cfg80211_bss_frame_type - frame type that the BSS data came from
54965590 * @CFG80211_BSS_FTYPE_UNKNOWN: driver doesn't know whether the data is
@@ -7213,4 +7307,14 @@ void cfg80211_pmsr_complete(struct wireless_dev *wdev,
72137307#define wiphy_WARN (wiphy , format , args ...) \
72147308 WARN(1, "wiphy: %s\n" format, wiphy_name(wiphy), ##args);
72157309
7310+ /**
7311+ * cfg80211_update_owe_info_event - Notify the peer's OWE info to user space
7312+ * @netdev: network device
7313+ * @owe_info: peer's owe info
7314+ * @gfp: allocation flags
7315+ */
7316+ void cfg80211_update_owe_info_event (struct net_device * netdev ,
7317+ struct cfg80211_update_owe_info * owe_info ,
7318+ gfp_t gfp );
7319+
72167320#endif /* __NET_CFG80211_H */
0 commit comments