diff options
author | Numan Siddique <nusiddiq@redhat.com> | 2018-04-16 19:26:53 +0530 |
---|---|---|
committer | Ben Pfaff <blp@ovn.org> | 2018-04-16 13:04:43 -0700 |
commit | 895ceaf78db8ab462cd0d9bf1fe22c831d637629 (patch) | |
tree | 1cd2a4e0183c2665c8b1c8af1a378b3ad7645187 /ovn | |
parent | 571b565b46ae1730c6a91a2205461e93a257b0c8 (diff) | |
download | openvswitch-895ceaf78db8ab462cd0d9bf1fe22c831d637629.tar.gz |
ovn: Set router lifetime value for IPv6 periodic RA.
ovn-controller when it sends out periodic RA packets, sets '0' in the
Router lifetime field. As per the RFC 4861, lifetime of 0 indicates that
the router is not a default router and SHOULD NOT appear on the default
router list. Without the default route, a VM will not able to reach to
other router ports attached to the same router unless a default route
is added by the user.
ovn-controller when encoding the 'put_nd_ra_opts' action sets the Router
Lifetime field to 0xffff. So this patch also sets the same value when
sending out the periodic RAs.
Reported-at: https://bugzilla.redhat.com/show_bug.cgi?id=1567735
Signed-off-by: Numan Siddique <nusiddiq@redhat.com>
Signed-off-by: Ben Pfaff <blp@ovn.org>
Acked-by: Mark Michelson <mmichels@redhat.com>
Diffstat (limited to 'ovn')
-rw-r--r-- | ovn/controller/pinctrl.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/ovn/controller/pinctrl.c b/ovn/controller/pinctrl.c index 2f130994a..6e6aa1caa 100644 --- a/ovn/controller/pinctrl.c +++ b/ovn/controller/pinctrl.c @@ -1432,7 +1432,8 @@ ipv6_ra_send(struct ipv6_ra_state *ra) dp_packet_use_stub(&packet, packet_stub, sizeof packet_stub); compose_nd_ra(&packet, ra->config->eth_src, ra->config->eth_dst, &ra->config->ipv6_src, &ra->config->ipv6_dst, - 255, ra->config->mo_flags, 0, 0, 0, ra->config->mtu); + 255, ra->config->mo_flags, htons(IPV6_ND_RA_LIFETIME), 0, 0, + ra->config->mtu); for (int i = 0; i < ra->config->prefixes.n_ipv6_addrs; i++) { ovs_be128 addr; |