diff options
author | Sivan Reinstein <sivanr@codeaurora.org> | 2015-11-05 17:30:06 +0200 |
---|---|---|
committer | Skylar Chang <chiaweic@codeaurora.org> | 2016-04-11 14:51:56 -0700 |
commit | b81a3893c0a0dc161310507c3eb11b5d058fce0c (patch) | |
tree | 9b40c6d988383eadcd465a0d30ffb0b7559a52ef /ipacm/src/IPACM_Wlan.cpp | |
parent | bbb3c92ca1c764e7515f0412b6878f87d42b2ee8 (diff) | |
download | ipacfg-mgr-b81a3893c0a0dc161310507c3eb11b5d058fce0c.tar.gz |
IPACM: Fix hashable fields to behave in boolean form
This change fixes an incorrect assignment of values in the
hashable fields. The current version of the code relies
on an enum definition which does not conform to the required
boolean values of the fields.
Change-Id: I4c0a44b97e3b99a51adb573e7eb32ef08bfb6133
Acked-by: David Arinzon <darinzon@qti.qualcomm.com>
Diffstat (limited to 'ipacm/src/IPACM_Wlan.cpp')
-rw-r--r-- | ipacm/src/IPACM_Wlan.cpp | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/ipacm/src/IPACM_Wlan.cpp b/ipacm/src/IPACM_Wlan.cpp index f933a69..3c92a4f 100644 --- a/ipacm/src/IPACM_Wlan.cpp +++ b/ipacm/src/IPACM_Wlan.cpp @@ -2204,6 +2204,9 @@ int IPACM_Wlan::handle_wlan_client_route_rule(uint8_t *mac_addr, ipa_ip_type ipt rt_rule_entry->rule.hdr_hdl = get_client_memptr(wlan_client, wlan_index)->hdr_hdl_v4; rt_rule_entry->rule.attrib.u.v4.dst_addr = get_client_memptr(wlan_client, wlan_index)->v4_addr; rt_rule_entry->rule.attrib.u.v4.dst_addr_mask = 0xFFFFFFFF; +#ifdef FEATURE_IPA_V3 + rt_rule_entry->rule.hashable = true; +#endif if (false == m_routing.AddRoutingRule(rt_rule)) { IPACMERR("Routing rule addition failed!\n"); @@ -2243,6 +2246,9 @@ int IPACM_Wlan::handle_wlan_client_route_rule(uint8_t *mac_addr, ipa_ip_type ipt rt_rule_entry->rule.attrib.u.v6.dst_addr_mask[1] = 0xFFFFFFFF; rt_rule_entry->rule.attrib.u.v6.dst_addr_mask[2] = 0xFFFFFFFF; rt_rule_entry->rule.attrib.u.v6.dst_addr_mask[3] = 0xFFFFFFFF; +#ifdef FEATURE_IPA_V3 + rt_rule_entry->rule.hashable = true; +#endif if (false == m_routing.AddRoutingRule(rt_rule)) { IPACMERR("Routing rule addition failed!\n"); @@ -2283,6 +2289,9 @@ int IPACM_Wlan::handle_wlan_client_route_rule(uint8_t *mac_addr, ipa_ip_type ipt rt_rule_entry->rule.attrib.u.v6.dst_addr_mask[1] = 0xFFFFFFFF; rt_rule_entry->rule.attrib.u.v6.dst_addr_mask[2] = 0xFFFFFFFF; rt_rule_entry->rule.attrib.u.v6.dst_addr_mask[3] = 0xFFFFFFFF; +#ifdef FEATURE_IPA_V3 + rt_rule_entry->rule.hashable = true; +#endif if (false == m_routing.AddRoutingRule(rt_rule)) { IPACMERR("Routing rule addition failed!\n"); @@ -3337,6 +3346,9 @@ int IPACM_Wlan::install_dummy_flt_rule(ipa_ip_type iptype, int num_rule) flt_rule.flt_rule_hdl = -1; flt_rule.status = -1; flt_rule.rule.action = IPA_PASS_TO_EXCEPTION; +#ifdef FEATURE_IPA_V3 + flt_rule.rule.hashable = true; +#endif memcpy(&flt_rule.rule.attrib, &rx_prop->rx[0].attrib, sizeof(flt_rule.rule.attrib)); @@ -4454,7 +4466,9 @@ int IPACM_Wlan::eth_bridge_add_wlan_client_rt_rule(uint8_t* mac, eth_bridge_src_ rt_rule.at_rear = false; rt_rule.status = -1; rt_rule.rt_rule_hdl = -1; - +#ifdef FEATURE_IPA_V3 + rt_rule.rule.hashable = true; +#endif rt_rule.rule.hdr_hdl = 0; if(src == SRC_WLAN) { @@ -4517,6 +4531,7 @@ int IPACM_Wlan::eth_bridge_add_wlan_client_rt_rule(uint8_t* mac, eth_bridge_src_ position++; } } + if(false == m_routing.AddRoutingRule(rt_rule_table)) { IPACMERR("Routing rule addition failed!\n"); |