]> git.baikalelectronics.ru Git - kernel.git/commit
net: ipv6: Dont add RT6_LOOKUP_F_IFACE flag if saddr set
authorDavid Ahern <dsa@cumulusnetworks.com>
Wed, 21 Oct 2015 15:42:22 +0000 (08:42 -0700)
committerDavid S. Miller <davem@davemloft.net>
Thu, 22 Oct 2015 14:36:19 +0000 (07:36 -0700)
commitbaf00fa9a3d66365d06cf441a35a68a924af6ded
tree24b84e5a7b51f6c7687993a7951c44661b16fa4b
parent62f1bd1ed4de41711ea917f9b567f6c9999e9ad6
net: ipv6: Dont add RT6_LOOKUP_F_IFACE flag if saddr set

c6b9b8dbeec1 ("net: ipv6: Add RT6_LOOKUP_F_IFACE flag if oif is set")
adds the RT6_LOOKUP_F_IFACE flag to make device index mismatch fatal if
oif is given. Hajime reported that this change breaks the Mobile IPv6
use case that wants to force the message through one interface yet use
the source address from another interface. Handle this case by only
adding the flag if oif is set and saddr is not set.

Fixes: c6b9b8dbeec1 ("net: ipv6: Add RT6_LOOKUP_F_IFACE flag if oif is set")
Cc: Hajime Tazaki <thehajime@gmail.com>
Signed-off-by: David Ahern <dsa@cumulusnetworks.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv6/route.c