Skip to content

Commit d23c4b6

Browse files
liuhangbindavem330
authored andcommitted
net/ipv6: init ip6 anycast rt->dst.input as ip6_input
Commit 6edb3c9 ("net/ipv6: Defer initialization of dst to data path") forgot to handle anycast route and init anycast rt->dst.input to ip6_forward. Fix it by setting anycast rt->dst.input back to ip6_input. Fixes: 6edb3c9 ("net/ipv6: Defer initialization of dst to data path") Signed-off-by: Hangbin Liu <liuhangbin@gmail.com> Reviewed-by: David Ahern <dsahern@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent 58ce660 commit d23c4b6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

net/ipv6/route.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -956,7 +956,7 @@ static void ip6_rt_init_dst(struct rt6_info *rt, struct fib6_info *ort)
956956
rt->dst.error = 0;
957957
rt->dst.output = ip6_output;
958958

959-
if (ort->fib6_type == RTN_LOCAL) {
959+
if (ort->fib6_type == RTN_LOCAL || ort->fib6_type == RTN_ANYCAST) {
960960
rt->dst.input = ip6_input;
961961
} else if (ipv6_addr_type(&ort->fib6_dst.addr) & IPV6_ADDR_MULTICAST) {
962962
rt->dst.input = ip6_mc_input;

0 commit comments

Comments
 (0)