Message ID | 54be8183fb49a5486a8137627c204f00595e21af.1651743750.git.leonro@nvidia.com |
---|---|
State | Awaiting Upstream |
Headers | show |
Series | Be explicit with XFRM offload direction | expand |
On Thu, 5 May 2022 13:06:43 +0300 Leon Romanovsky wrote: > From: Leon Romanovsky <leonro@nvidia.com> > > Make sure that netdevsim relies on direction and not on flags. > > Reviewed-by: Raed Salem <raeds@nvidia.com> > Signed-off-by: Leon Romanovsky <leonro@nvidia.com> Acked-by: Jakub Kicinski <kuba@kernel.org>
diff --git a/drivers/net/netdevsim/ipsec.c b/drivers/net/netdevsim/ipsec.c index b80ed2ffd45e..386336a38f34 100644 --- a/drivers/net/netdevsim/ipsec.c +++ b/drivers/net/netdevsim/ipsec.c @@ -171,7 +171,7 @@ static int nsim_ipsec_add_sa(struct xfrm_state *xs) return ret; } - if (xs->xso.flags & XFRM_OFFLOAD_INBOUND) { + if (xs->xso.dir == XFRM_DEV_OFFLOAD_IN) { sa.rx = true; if (xs->props.family == AF_INET6)