]> git.hungrycats.org Git - linux/commit
powerpc/64s: Fix VAS mm use after free
authorNicholas Piggin <npiggin@gmail.com>
Wed, 7 Jun 2023 10:10:24 +0000 (20:10 +1000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 11 Jul 2023 17:39:48 +0000 (19:39 +0200)
commitdb8657fdd53c5e3069149d7f957cb60e63027bb2
tree2befee7b1f82d38e1859bc7d5b9c990e9d331b69
parent010139bfc6bb9ddab81dbc2cf71cd3a9c28adc7f
powerpc/64s: Fix VAS mm use after free

[ Upstream commit b4bda59b47879cce38a6ec5a01cd3cac702b5331 ]

The refcount on mm is dropped before the coprocessor is detached.

Reported-by: Sachin Sant <sachinp@linux.ibm.com>
Fixes: 7bc6f71bdff5f ("powerpc/vas: Define and use common vas_window struct")
Fixes: b22f2d88e435c ("powerpc/pseries/vas: Integrate API with open/close windows")
Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
Tested-by: Sachin Sant <sachinp@linux.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://msgid.link/20230607101024.14559-1-npiggin@gmail.com
Signed-off-by: Sasha Levin <sashal@kernel.org>
arch/powerpc/platforms/powernv/vas-window.c
arch/powerpc/platforms/pseries/vas.c