Merge "ipacm: set upstream flag if downstream IP addr event come later"
diff --git a/ipacm/src/IPACM_Lan.cpp b/ipacm/src/IPACM_Lan.cpp
index 532269f..f7544e8 100644
--- a/ipacm/src/IPACM_Lan.cpp
+++ b/ipacm/src/IPACM_Lan.cpp
@@ -462,6 +462,18 @@
} else {
IPACMDBG_H("Wan_V6 haven't up yet\n");
}
+#else
+ /* check if Upstream was set before */
+ if (IPACM_Wan::isWanUP(ipa_if_num))
+ {
+ IPACMDBG_H("Upstream was set previously for ipv4, change is_upstream_set flag\n");
+ is_upstream_set[IPA_IP_v4] = true;
+ }
+ if (IPACM_Wan::isWanUP_V6(ipa_if_num))
+ {
+ IPACMDBG_H("Upstream was set previously for ipv6, change is_upstream_set flag\n");
+ is_upstream_set[IPA_IP_v6] = true;
+ }
#endif
/* Post event to NAT */
if (data->iptype == IPA_IP_v4)
diff --git a/ipacm/src/IPACM_Wlan.cpp b/ipacm/src/IPACM_Wlan.cpp
index 0669b80..a97c0a0 100644
--- a/ipacm/src/IPACM_Wlan.cpp
+++ b/ipacm/src/IPACM_Wlan.cpp
@@ -323,6 +323,18 @@
} else {
IPACMDBG_H("Wan_V6 haven't up yet \n");
}
+#else
+ /* check if Upstream was set before */
+ if (IPACM_Wan::isWanUP(ipa_if_num))
+ {
+ IPACMDBG_H("Upstream was set previously for ipv4, change is_upstream_set flag\n");
+ is_upstream_set[IPA_IP_v4] = true;
+ }
+ if (IPACM_Wan::isWanUP_V6(ipa_if_num))
+ {
+ IPACMDBG_H("Upstream was set previously for ipv6, change is_upstream_set flag\n");
+ is_upstream_set[IPA_IP_v6] = true;
+ }
#endif
/* checking if SW-RT_enable */
if (IPACM_Iface::ipacmcfg->ipa_sw_rt_enable == true)