]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
xfrm: Pass flowi_oif or l3mdev as oif to xfrm_dst_lookup
authorDavid Ahern <dsahern@kernel.org>
Fri, 1 Apr 2022 18:58:37 +0000 (12:58 -0600)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 17 Oct 2024 13:12:01 +0000 (15:12 +0200)
commit9476ecd7f7b8df773ac8048e7ebb916c64261204
tree6266ca3a0c8da1be4bce785f8411c032019a6ba1
parent78f4daf715e8d2f56b2b5be5a5e43c994a74ee85
xfrm: Pass flowi_oif or l3mdev as oif to xfrm_dst_lookup

commit 748b82c23e25310fec54e1eff2cb63936f391b24 upstream.

The commit referenced in the Fixes tag no longer changes the
flow oif to the l3mdev ifindex. A xfrm use case was expecting
the flowi_oif to be the VRF if relevant and the change broke
that test. Update xfrm_bundle_create to pass oif if set and any
potential flowi_l3mdev if oif is not set.

Fixes: 40867d74c374 ("net: Add l3mdev index to flow struct and avoid oif reset for port devices")
Reported-by: kernel test robot <oliver.sang@intel.com>
Signed-off-by: David Ahern <dsahern@kernel.org>
Signed-off-by: Steffen Klassert <steffen.klassert@secunet.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/xfrm/xfrm_policy.c