Browse Source

qcacld-3.0: update mld address when wlan_mac.bin is used

Update the MLD address when mac address are retrieved through
wlan_mac.bin.

Change-Id: I90e54f93dcc447756dd0dcaf5f39bfa86d110c79
CRs-Fixed: 3254278
Lin Bai 2 years ago
parent
commit
c65b1f6ca9
1 changed files with 7 additions and 6 deletions
  1. 7 6
      core/hdd/src/wlan_hdd_cfg.c

+ 7 - 6
core/hdd/src/wlan_hdd_cfg.c

@@ -218,7 +218,7 @@ QDF_STATUS hdd_update_mac_config(struct hdd_context *hdd_ctx)
 	char *name, *value;
 	int max_mac_addr = QDF_MAX_CONCURRENCY_PERSONA;
 	struct hdd_cfg_entry mac_table[QDF_MAX_CONCURRENCY_PERSONA];
-	tSirMacAddr custom_mac_addr;
+	struct qdf_mac_addr custom_mac_addr;
 
 	QDF_STATUS qdf_status = QDF_STATUS_SUCCESS;
 
@@ -310,15 +310,16 @@ QDF_STATUS hdd_update_mac_config(struct hdd_context *hdd_ctx)
 	hdd_populate_random_mac_addr(hdd_ctx, max_mac_addr - i);
 
 	if (hdd_ctx->num_provisioned_addr)
-		qdf_mem_copy(&custom_mac_addr,
+		qdf_mem_copy(custom_mac_addr.bytes,
 			     &hdd_ctx->provisioned_mac_addr[0].bytes[0],
-			     sizeof(tSirMacAddr));
+			     sizeof(custom_mac_addr));
 	else
-		qdf_mem_copy(&custom_mac_addr,
+		qdf_mem_copy(custom_mac_addr.bytes,
 			     &hdd_ctx->derived_mac_addr[0].bytes[0],
-			     sizeof(tSirMacAddr));
+			     sizeof(custom_mac_addr));
 
-	sme_set_custom_mac_addr(custom_mac_addr);
+	hdd_update_mld_mac_addr(hdd_ctx, custom_mac_addr);
+	sme_set_custom_mac_addr(custom_mac_addr.bytes);
 
 config_exit:
 	qdf_mem_free(temp);