File tree Expand file tree Collapse file tree 5 files changed +44
-1
lines changed
drivers/net/wireless/intel/iwlwifi Expand file tree Collapse file tree 5 files changed +44
-1
lines changed Original file line number Diff line number Diff line change @@ -579,8 +579,14 @@ enum iwl_umac_scan_general_flags {
579
579
IWL_UMAC_SCAN_GEN_FLAGS_RRM_ENABLED = BIT (8 ),
580
580
IWL_UMAC_SCAN_GEN_FLAGS_MATCH = BIT (9 ),
581
581
IWL_UMAC_SCAN_GEN_FLAGS_EXTENDED_DWELL = BIT (10 ),
582
+ /* Extended dwell is obselete when adaptive dwell is used, making this
583
+ * bit reusable. Hence, probe request defer is used only when adaptive
584
+ * dwell is supported. */
585
+ IWL_UMAC_SCAN_GEN_FLAGS_PROB_REQ_DEFER_SUPP = BIT (10 ),
582
586
IWL_UMAC_SCAN_GEN_FLAGS_LMAC2_FRAGMENTED = BIT (11 ),
583
587
IWL_UMAC_SCAN_GEN_FLAGS_ADAPTIVE_DWELL = BIT (13 ),
588
+ IWL_UMAC_SCAN_GEN_FLAGS_MAX_CHNL_TIME = BIT (14 ),
589
+ IWL_UMAC_SCAN_GEN_FLAGS_PROB_REQ_HIGH_TX_RATE = BIT (15 ),
584
590
};
585
591
586
592
/**
Original file line number Diff line number Diff line change @@ -265,6 +265,7 @@ enum iwl_ucode_tlv_api {
265
265
IWL_UCODE_TLV_API_NAN2_VER2 = (__force iwl_ucode_tlv_api_t )31 ,
266
266
/* API Set 1 */
267
267
IWL_UCODE_TLV_API_ADAPTIVE_DWELL = (__force iwl_ucode_tlv_api_t )32 ,
268
+ IWL_UCODE_TLV_API_OCE = (__force iwl_ucode_tlv_api_t )33 ,
268
269
IWL_UCODE_TLV_API_NEW_BEACON_TEMPLATE = (__force iwl_ucode_tlv_api_t )34 ,
269
270
IWL_UCODE_TLV_API_NEW_RX_STATS = (__force iwl_ucode_tlv_api_t )35 ,
270
271
IWL_UCODE_TLV_API_QUOTA_LOW_LATENCY = (__force iwl_ucode_tlv_api_t )38 ,
Original file line number Diff line number Diff line change @@ -661,6 +661,17 @@ int iwl_mvm_mac_setup_register(struct iwl_mvm *mvm)
661
661
NL80211_EXT_FEATURE_SET_SCAN_DWELL );
662
662
}
663
663
664
+ if (iwl_mvm_is_oce_supported (mvm )) {
665
+ wiphy_ext_feature_set (hw -> wiphy ,
666
+ NL80211_EXT_FEATURE_ACCEPT_BCAST_PROBE_RESP );
667
+ wiphy_ext_feature_set (hw -> wiphy ,
668
+ NL80211_EXT_FEATURE_FILS_MAX_CHANNEL_TIME );
669
+ wiphy_ext_feature_set (hw -> wiphy ,
670
+ NL80211_EXT_FEATURE_OCE_PROBE_REQ_DEFERRAL_SUPPRESSION );
671
+ wiphy_ext_feature_set (hw -> wiphy ,
672
+ NL80211_EXT_FEATURE_OCE_PROBE_REQ_HIGH_TX_RATE );
673
+ }
674
+
664
675
mvm -> rts_threshold = IEEE80211_MAX_RTS_THRESHOLD ;
665
676
666
677
#ifdef CONFIG_PM_SLEEP
Original file line number Diff line number Diff line change @@ -1155,6 +1155,12 @@ static inline bool iwl_mvm_is_adaptive_dwell_supported(struct iwl_mvm *mvm)
1155
1155
IWL_UCODE_TLV_API_ADAPTIVE_DWELL );
1156
1156
}
1157
1157
1158
+ static inline bool iwl_mvm_is_oce_supported (struct iwl_mvm * mvm )
1159
+ {
1160
+ /* OCE should never be enabled for LMAC scan FWs */
1161
+ return fw_has_api (& mvm -> fw -> ucode_capa , IWL_UCODE_TLV_API_OCE );
1162
+ }
1163
+
1158
1164
static inline bool iwl_mvm_enter_d0i3_on_suspend (struct iwl_mvm * mvm )
1159
1165
{
1160
1166
/* For now we only use this mode to differentiate between
Original file line number Diff line number Diff line change @@ -1268,9 +1268,28 @@ static u16 iwl_mvm_scan_umac_flags(struct iwl_mvm *mvm,
1268
1268
*/
1269
1269
if (iwl_mvm_is_regular_scan (params ) &&
1270
1270
vif -> type != NL80211_IFTYPE_P2P_DEVICE &&
1271
- params -> type != IWL_SCAN_TYPE_FRAGMENTED )
1271
+ params -> type != IWL_SCAN_TYPE_FRAGMENTED &&
1272
+ !iwl_mvm_is_adaptive_dwell_supported (mvm ) &&
1273
+ !iwl_mvm_is_oce_supported (mvm ))
1272
1274
flags |= IWL_UMAC_SCAN_GEN_FLAGS_EXTENDED_DWELL ;
1273
1275
1276
+ if (iwl_mvm_is_oce_supported (mvm )) {
1277
+ if ((params -> flags &
1278
+ NL80211_SCAN_FLAG_OCE_PROBE_REQ_HIGH_TX_RATE ))
1279
+ flags |= IWL_UMAC_SCAN_GEN_FLAGS_PROB_REQ_HIGH_TX_RATE ;
1280
+ /* Since IWL_UMAC_SCAN_GEN_FLAGS_EXTENDED_DWELL and
1281
+ * NL80211_SCAN_FLAG_OCE_PROBE_REQ_DEFERRAL_SUPPRESSION shares
1282
+ * the same bit, we need to make sure that we use this bit here
1283
+ * only when IWL_UMAC_SCAN_GEN_FLAGS_EXTENDED_DWELL cannot be
1284
+ * used. */
1285
+ if ((params -> flags &
1286
+ NL80211_SCAN_FLAG_OCE_PROBE_REQ_DEFERRAL_SUPPRESSION ) &&
1287
+ !WARN_ON_ONCE (!iwl_mvm_is_adaptive_dwell_supported (mvm )))
1288
+ flags |= IWL_UMAC_SCAN_GEN_FLAGS_PROB_REQ_DEFER_SUPP ;
1289
+ if ((params -> flags & NL80211_SCAN_FLAG_FILS_MAX_CHANNEL_TIME ))
1290
+ flags |= IWL_UMAC_SCAN_GEN_FLAGS_MAX_CHNL_TIME ;
1291
+ }
1292
+
1274
1293
return flags ;
1275
1294
}
1276
1295
You can’t perform that action at this time.
0 commit comments