From af2f7573ea00a84f1b93e0111261c67d1567c753 Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Sun, 10 Nov 2024 04:41:11 +0000 Subject: [PATCH] Revert "xfrm: Pass flowi_oif or l3mdev as oif to xfrm_dst_lookup" This reverts commit 0825c5ff246cb8df5c70cf0331289cf4361dd3ae which is commit 748b82c23e25310fec54e1eff2cb63936f391b24 upstream. It breaks the Android kernel abi and can be brought back in the future in an abi-safe way if it is really needed. Bug: 161946584 Change-Id: Ib3f614c0ff41f47d5b7c6b15df0c5d90f1e1cd32 Signed-off-by: Greg Kroah-Hartman --- net/xfrm/xfrm_policy.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/net/xfrm/xfrm_policy.c b/net/xfrm/xfrm_policy.c index 25b74fa03abc..ac18cf1a03ec 100644 --- a/net/xfrm/xfrm_policy.c +++ b/net/xfrm/xfrm_policy.c @@ -2602,14 +2602,12 @@ static struct dst_entry *xfrm_bundle_create(struct xfrm_policy *policy, if (xfrm[i]->props.mode != XFRM_MODE_TRANSPORT) { __u32 mark = 0; - int oif; if (xfrm[i]->props.smark.v || xfrm[i]->props.smark.m) mark = xfrm_smark_get(fl->flowi_mark, xfrm[i]); family = xfrm[i]->props.family; - oif = fl->flowi_oif ? : fl->flowi_l3mdev; - dst = xfrm_dst_lookup(xfrm[i], tos, oif, + dst = xfrm_dst_lookup(xfrm[i], tos, fl->flowi_oif, &saddr, &daddr, family, mark); err = PTR_ERR(dst); if (IS_ERR(dst))