]> git.baikalelectronics.ru Git - kernel.git/commit
net: ipv4: fix l3slave check for index returned in IP_PKTINFO
authorDavid Ahern <dsahern@gmail.com>
Thu, 14 Sep 2017 00:11:37 +0000 (17:11 -0700)
committerDavid S. Miller <davem@davemloft.net>
Fri, 15 Sep 2017 21:27:51 +0000 (14:27 -0700)
commit0127235f3d4b32bc283891c1039bed616d9e8775
tree76214a42f705f5c745b735046942b6e672fdbcf8
parent74d2c45ed43df882de7383dcb9a9df5fce469715
net: ipv4: fix l3slave check for index returned in IP_PKTINFO

rt_iif is only set to the actual egress device for the output path. The
recent change to consider the l3slave flag when returning IP_PKTINFO
works for local traffic (the correct device index is returned), but it
broke the more typical use case of packets received from a remote host
always returning the VRF index rather than the original ingress device.
Update the fixup to consider l3slave and rt_iif actually getting set.

Fixes: aefd85ec8fa8c ("net: ipv4: add check for l3slave for index returned in IP_PKTINFO")
Signed-off-by: David Ahern <dsahern@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/ip_sockglue.c