xfrm: fix a small bug in xfrm_sa_len()
authorEric Dumazet <edumazet@google.com>
Wed, 8 Dec 2021 20:20:19 +0000 (12:20 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 27 Jan 2022 09:53:55 +0000 (10:53 +0100)
commit3e801ea43c4b81a32e2a72cd102ad60783b5f07e
tree034be09e56e9858c6039f12b6e0b81ae1a8a95b2
parentb87034d7a2a85267d13d1306841feacca0e4d8b0
xfrm: fix a small bug in xfrm_sa_len()

[ Upstream commit 7770a39d7c63faec6c4f33666d49a8cb664d0482 ]

copy_user_offload() will actually push a struct struct xfrm_user_offload,
which is different than (struct xfrm_state *)->xso
(struct xfrm_state_offload)

Fixes: d77e38e612a01 ("xfrm: Add an IPsec hardware offloading API")
Signed-off-by: Eric Dumazet <edumazet@google.com>
Cc: Steffen Klassert <steffen.klassert@secunet.com>
Signed-off-by: Steffen Klassert <steffen.klassert@secunet.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
net/xfrm/xfrm_user.c