]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commitdiff
xfrm: clone missing x->lastused in xfrm_do_migrate
authorAntony Antony <antony.antony@secunet.com>
Wed, 27 Jul 2022 15:41:22 +0000 (17:41 +0200)
committerStefan Bader <stefan.bader@canonical.com>
Mon, 17 Oct 2022 09:57:42 +0000 (11:57 +0200)
BugLink: https://bugs.launchpad.net/bugs/1991717
[ Upstream commit 6aa811acdb76facca0b705f4e4c1d948ccb6af8b ]

x->lastused was not cloned in xfrm_do_migrate. Add it to clone during
migrate.

Fixes: 80c9abaabf42 ("[XFRM]: Extension for dynamic update of endpoint address(es)")
Signed-off-by: Antony Antony <antony.antony@secunet.com>
Signed-off-by: Steffen Klassert <steffen.klassert@secunet.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
net/xfrm/xfrm_state.c

index b1a04a22166f76f235cad363e085b91982c52657..15132b080614cd19a2a1f2a18a23e914b18cb845 100644 (file)
@@ -1591,6 +1591,7 @@ static struct xfrm_state *xfrm_state_clone(struct xfrm_state *orig,
        x->replay = orig->replay;
        x->preplay = orig->preplay;
        x->mapping_maxage = orig->mapping_maxage;
+       x->lastused = orig->lastused;
        x->new_mapping = 0;
        x->new_mapping_sport = 0;