summaryrefslogtreecommitdiff
path: root/ipacm/src/IPACM_Wlan.cpp
diff options
context:
space:
mode:
authorLinux Build Service Account <lnxbuild@localhost>2015-11-17 06:35:17 -0800
committerGerrit - the friendly Code Review server <code-review@localhost>2015-11-17 06:35:17 -0800
commit2dd08ba4a817ed208fc8d54d8d1b37ce0514b240 (patch)
tree477a47c74e8a5572e7bd3003b324ef07372d27ee /ipacm/src/IPACM_Wlan.cpp
parentc251b38b68d392ebbc8c6fff783da44601ad62d7 (diff)
parent37e0de9d0171aa99ccfc13221f63e6eccd24374c (diff)
downloadipacfg-mgr-2dd08ba4a817ed208fc8d54d8d1b37ce0514b240.tar.gz
Merge "IPACM: change src mac to bridge0"
Diffstat (limited to 'ipacm/src/IPACM_Wlan.cpp')
-rw-r--r--ipacm/src/IPACM_Wlan.cpp18
1 files changed, 18 insertions, 0 deletions
diff --git a/ipacm/src/IPACM_Wlan.cpp b/ipacm/src/IPACM_Wlan.cpp
index e8dccdf..bb70724 100644
--- a/ipacm/src/IPACM_Wlan.cpp
+++ b/ipacm/src/IPACM_Wlan.cpp
@@ -1784,6 +1784,15 @@ int IPACM_Wlan::handle_wlan_client_init_ex(ipacm_event_data_wlan_ex *data)
memcpy(&pHeaderDescriptor->hdr[0].hdr[data->attribs[i].offset],
get_client_memptr(wlan_client, num_wifi_client)->mac,
IPA_MAC_ADDR_SIZE);
+ /* replace src mac to bridge mac_addr if any */
+ if (IPACM_Iface::ipacmcfg->ipa_bridge_enable)
+ {
+ memcpy(&pHeaderDescriptor->hdr[0].hdr[data->attribs[i].offset+IPA_MAC_ADDR_SIZE],
+ IPACM_Iface::ipacmcfg->bridge_mac,
+ IPA_MAC_ADDR_SIZE);
+ IPACMDBG_H("device is in bridge mode \n");
+ }
+
}
else if(data->attribs[i].attrib_type == WLAN_HDR_ATTRIB_STA_ID)
{
@@ -1890,6 +1899,15 @@ int IPACM_Wlan::handle_wlan_client_init_ex(ipacm_event_data_wlan_ex *data)
memcpy(&pHeaderDescriptor->hdr[0].hdr[data->attribs[i].offset],
get_client_memptr(wlan_client, num_wifi_client)->mac,
IPA_MAC_ADDR_SIZE);
+
+ /* replace src mac to bridge mac_addr if any */
+ if (IPACM_Iface::ipacmcfg->ipa_bridge_enable)
+ {
+ memcpy(&pHeaderDescriptor->hdr[0].hdr[data->attribs[i].offset+IPA_MAC_ADDR_SIZE],
+ IPACM_Iface::ipacmcfg->bridge_mac,
+ IPA_MAC_ADDR_SIZE);
+ IPACMDBG_H("device is in bridge mode \n");
+ }
}
else if (data->attribs[i].attrib_type == WLAN_HDR_ATTRIB_STA_ID)
{