|
@@ -1317,6 +1317,39 @@ struct hdd_adapter *hdd_get_assoc_link_adapter(struct hdd_adapter *ml_adapter)
|
|
|
|
|
|
return NULL;
|
|
|
}
|
|
|
+
|
|
|
+static void hdd_set_immediate_power_save(struct hdd_adapter *adapter,
|
|
|
+ bool is_immediate_powersave)
|
|
|
+{
|
|
|
+ struct hdd_adapter *link_adapter;
|
|
|
+ struct hdd_mlo_adapter_info *mlo_adapter_info;
|
|
|
+ struct hdd_station_ctx *sta_ctx;
|
|
|
+ int i;
|
|
|
+
|
|
|
+ mlo_adapter_info = &adapter->mlo_adapter_info;
|
|
|
+ if (mlo_adapter_info->is_ml_adapter) {
|
|
|
+ for (i = 0; i < WLAN_MAX_MLD; i++) {
|
|
|
+ link_adapter = mlo_adapter_info->link_adapter[i];
|
|
|
+ if (!link_adapter)
|
|
|
+ continue;
|
|
|
+ sta_ctx = WLAN_HDD_GET_STATION_CTX_PTR(link_adapter);
|
|
|
+ sta_ctx->ap_supports_immediate_power_save =
|
|
|
+ is_immediate_powersave;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ sta_ctx = WLAN_HDD_GET_STATION_CTX_PTR(adapter);
|
|
|
+ sta_ctx->ap_supports_immediate_power_save = is_immediate_powersave;
|
|
|
+}
|
|
|
+
|
|
|
+#else
|
|
|
+static void hdd_set_immediate_power_save(struct hdd_adapter *adapter,
|
|
|
+ bool is_immediate_powersave)
|
|
|
+{
|
|
|
+ struct hdd_station_ctx *sta_ctx;
|
|
|
+
|
|
|
+ sta_ctx = WLAN_HDD_GET_STATION_CTX_PTR(adapter);
|
|
|
+ sta_ctx->ap_supports_immediate_power_save = is_immediate_powersave;
|
|
|
+}
|
|
|
#endif
|
|
|
|
|
|
static void
|
|
@@ -1338,6 +1371,7 @@ hdd_cm_connect_success_pre_user_update(struct wlan_objmgr_vdev *vdev,
|
|
|
uint8_t uapsd_mask = 0;
|
|
|
uint32_t time_buffer_size;
|
|
|
struct hdd_adapter *assoc_link_adapter;
|
|
|
+ bool is_immediate_power_save;
|
|
|
|
|
|
hdd_ctx = cds_get_context(QDF_MODULE_ID_HDD);
|
|
|
if (!hdd_ctx) {
|
|
@@ -1391,9 +1425,10 @@ hdd_cm_connect_success_pre_user_update(struct wlan_objmgr_vdev *vdev,
|
|
|
ie_field = (uint8_t *)(rsp->connect_ies.bcn_probe_rsp.ptr +
|
|
|
sizeof(struct wlan_frame_hdr) +
|
|
|
offsetof(struct wlan_bcn_frame, ie));
|
|
|
- sta_ctx->ap_supports_immediate_power_save =
|
|
|
+ is_immediate_power_save =
|
|
|
wlan_hdd_is_ap_supports_immediate_power_save(
|
|
|
- ie_field, ie_len);
|
|
|
+ ie_field, ie_len);
|
|
|
+ hdd_set_immediate_power_save(adapter, is_immediate_power_save);
|
|
|
hdd_debug("ap_supports_immediate_power_save flag [%d]",
|
|
|
sta_ctx->ap_supports_immediate_power_save);
|
|
|
}
|