summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjackiechen1985 <xiaobo.chen@tieto.com>2019-04-29 11:29:04 +0800
committerDave Barach <openvpp@barachs.net>2019-05-13 12:38:41 +0000
commit6b7e2332fbf74e043394699fd5d145af026d3719 (patch)
tree8846a3d3443fcde66e13f949ec0ee620783913f5
parentc1a02fcd9294fa46a6bd458cad7b7e14f0769548 (diff)
Fix VPP-1528 get the same IP address from DHCP server for two VPP DHCP clients
Change-Id: I18dfe51000758f44b991d2dd065c9aa2bc5863d5 Signed-off-by: jackiechen1985 <xiaobo.chen@tieto.com>
-rw-r--r--src/vnet/dhcp/client.c2
-rw-r--r--src/vnet/dhcp/dhcp6_pd_client_dp.c4
2 files changed, 2 insertions, 4 deletions
diff --git a/src/vnet/dhcp/client.c b/src/vnet/dhcp/client.c
index b89b8f28acc..b5710684bc1 100644
--- a/src/vnet/dhcp/client.c
+++ b/src/vnet/dhcp/client.c
@@ -1209,7 +1209,7 @@ dhcp_client_init (vlib_main_t * vm)
dcm->vlib_main = vm;
dcm->vnet_main = vnet_get_main ();
- dcm->seed = 0xdeaddabe;
+ dcm->seed = (u32) clib_cpu_time_now ();
return 0;
}
diff --git a/src/vnet/dhcp/dhcp6_pd_client_dp.c b/src/vnet/dhcp/dhcp6_pd_client_dp.c
index bc6baf76293..c1bf5f8844f 100644
--- a/src/vnet/dhcp/dhcp6_pd_client_dp.c
+++ b/src/vnet/dhcp/dhcp6_pd_client_dp.c
@@ -647,10 +647,8 @@ dhcp6_pd_client_init (vlib_main_t * vm)
cm->vlib_main = vm;
cm->vnet_main = vnet_get_main ();
-
cm->publisher_node = ~0;
-
- cm->seed = 0xdeaddabe;
+ cm->seed = (u32) clib_cpu_time_now ();
return 0;
}