浏览代码

qcacmn: Extract current active/inactive link bitmap

FW will report current active/inactive link bitmap for
each set link command. Extract them and save to respone
data struct.

Change-Id: I8513391fbf3b181c6182d6568d0ce8e83c627bc6
CRs-Fixed: 3564785
Liangwei Dong 2 年之前
父节点
当前提交
5a23527cfd
共有 2 个文件被更改,包括 30 次插入5 次删除
  1. 12 2
      umac/mlo_mgr/inc/wlan_mlo_mgr_public_structs.h
  2. 18 3
      wmi/src/wmi_unified_11be_tlv.c

+ 12 - 2
umac/mlo_mgr/inc/wlan_mlo_mgr_public_structs.h

@@ -397,6 +397,9 @@ struct mlo_sta_quiet_status {
  * @force_active_num_bitmap: force active num link bitmap
  * @force_inactive_num: force inactive link num
  * @force_inactive_num_bitmap: force inactive num link bitmap
+ * @curr_dynamic_inactive_bitmap: dynamic inactive link bitmap
+ * @curr_active_bitmap: current active link bitmap
+ * @curr_inactive_bitmap: current inactive link bitmap
  */
 struct ml_link_force_state {
 	uint16_t force_active_bitmap;
@@ -405,6 +408,9 @@ struct ml_link_force_state {
 	uint16_t force_active_num_bitmap;
 	uint8_t force_inactive_num;
 	uint16_t force_inactive_num_bitmap;
+	uint16_t curr_dynamic_inactive_bitmap;
+	uint16_t curr_active_bitmap;
+	uint16_t curr_inactive_bitmap;
 };
 
 /**
@@ -1086,8 +1092,10 @@ enum mlo_link_force_reason {
  * @use_ieee_link_id: link id is valid in active_linkid_bitmap or
  *	inactive_linkid_bitmap
  * @ap_mld_mac_addr: AP MLD mac address
- * @active_linkid_bitmap: current active link id bitmap
- * @inactive_linkid_bitmap: current inactive link id bitmap
+ * @active_linkid_bitmap: current forced active link id bitmap
+ * @inactive_linkid_bitmap: current forced inactive link id bitmap
+ * @curr_inactive_linkid_bitmap: current inactive link id bitmap
+ * @curr_active_linkid_bitmap: current active link id bitmap
  */
 struct mlo_link_set_active_resp {
 	uint32_t status;
@@ -1099,6 +1107,8 @@ struct mlo_link_set_active_resp {
 	struct qdf_mac_addr  ap_mld_mac_addr;
 	uint32_t active_linkid_bitmap;
 	uint32_t inactive_linkid_bitmap;
+	uint32_t curr_inactive_linkid_bitmap;
+	uint32_t curr_active_linkid_bitmap;
 };
 
 /**

+ 18 - 3
wmi/src/wmi_unified_11be_tlv.c

@@ -902,6 +902,21 @@ extract_mlo_link_set_active_resp_tlv(wmi_unified_t wmi_handle, void *evt_buf,
 		  resp->status,
 		  evt->use_ieee_link_id_bitmap,
 		  QDF_MAC_ADDR_REF(resp->ap_mld_mac_addr.bytes));
+
+	bitmap = param_buf->current_active_ieee_link_id_bitmap;
+	if (bitmap &&
+	    param_buf->num_current_active_ieee_link_id_bitmap > 0)
+		resp->curr_active_linkid_bitmap = bitmap[0];
+	bitmap = param_buf->current_inactive_ieee_link_id_bitmap;
+	if (bitmap &&
+	    param_buf->num_current_inactive_ieee_link_id_bitmap > 0)
+		resp->curr_inactive_linkid_bitmap = bitmap[0];
+	wmi_debug("curr active links: 0x%x inactive links: 0x%x num: %x %x",
+		  resp->curr_active_linkid_bitmap,
+		  resp->curr_inactive_linkid_bitmap,
+		  param_buf->num_current_active_ieee_link_id_bitmap,
+		  param_buf->num_current_inactive_ieee_link_id_bitmap);
+
 	if (evt->use_ieee_link_id_bitmap) {
 		bitmap = param_buf->force_active_ieee_link_id_bitmap;
 		if (bitmap &&
@@ -913,7 +928,7 @@ extract_mlo_link_set_active_resp_tlv(wmi_unified_t wmi_handle, void *evt_buf,
 		    param_buf->num_force_inactive_ieee_link_id_bitmap > 0)
 			resp->inactive_linkid_bitmap = bitmap[0];
 		resp->use_ieee_link_id = true;
-		wmi_debug("active links: 0x%x inactive links: 0x%x num: %x %x",
+		wmi_debug("forced active links: 0x%x inactive links: 0x%x num: %x %x",
 			  resp->active_linkid_bitmap,
 			  resp->inactive_linkid_bitmap,
 			  param_buf->num_force_active_ieee_link_id_bitmap,
@@ -927,7 +942,7 @@ extract_mlo_link_set_active_resp_tlv(wmi_unified_t wmi_handle, void *evt_buf,
 	resp->active_sz = entry_num;
 	for (i = 0; i < entry_num; i++) {
 		resp->active[i] = bitmap[i];
-		wmi_debug("active[%d]: 0x%x", i, resp->active[i]);
+		wmi_debug("vdev active[%d]: 0x%x", i, resp->active[i]);
 	}
 
 	bitmap = param_buf->force_inactive_vdev_bitmap;
@@ -936,7 +951,7 @@ extract_mlo_link_set_active_resp_tlv(wmi_unified_t wmi_handle, void *evt_buf,
 	resp->inactive_sz = entry_num;
 	for (i = 0; i < entry_num; i++) {
 		resp->inactive[i] = bitmap[i];
-		wmi_debug("inactive[%d]: 0x%x", i, resp->inactive[i]);
+		wmi_debug("vdev inactive[%d]: 0x%x", i, resp->inactive[i]);
 	}
 
 	return QDF_STATUS_SUCCESS;