diff options
| author | jiad <jiad@codeaurora.org> | 2018-04-02 16:52:52 +0800 |
|---|---|---|
| committer | Gerrit - the friendly Code Review server <code-review@localhost> | 2018-04-02 23:23:19 -0700 |
| commit | 60e5d872ba016675c7043098e45b66a68931973d (patch) | |
| tree | 6e724eb720bfbe456834f1f0c2f0c5fa96ac8917 | |
| parent | 3dd38603cbf05ad1794a0c62179059547de527a8 (diff) | |
qcacld-3.0: Fix wrong derived interface mac address
If FW provided mac address, derived_mac_addr[0] will be 0 as initial
value. Issue is under sta-ap configuration, sta interface will get
provisioned mac addr but ap interface will then get derived_mac_addr[0],
which leads to sta-ap failure when CONFIG_MOBILE_ROUTER feature is
enabled.
Fix is to copy derived_mac_addr according to number of provisioned mac
address.
Change-Id: Ie485ab1ba81024423d42ebe162655b994d58190f
CRs-Fixed: 2215113
| -rw-r--r-- | core/hdd/src/wlan_hdd_main.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/core/hdd/src/wlan_hdd_main.c b/core/hdd/src/wlan_hdd_main.c index c0925e51d6f1..8115ed4de0e6 100644 --- a/core/hdd/src/wlan_hdd_main.c +++ b/core/hdd/src/wlan_hdd_main.c @@ -968,7 +968,10 @@ void hdd_update_macaddr(hdd_context_t *hdd_ctx, MAC_ADDRESS_STR, MAC_ADDR_ARRAY(hdd_ctx->derived_mac_addr[0].bytes)); } - for (i = 1; i < QDF_MAX_CONCURRENCY_PERSONA; i++) { + + for (i = hdd_ctx->num_derived_addr; + i < QDF_MAX_CONCURRENCY_PERSONA - hdd_ctx->num_provisioned_addr; + i++) { qdf_mem_copy(hdd_ctx->derived_mac_addr[i].bytes, hw_macaddr.bytes, QDF_MAC_ADDR_SIZE); |
