drm/etnaviv: fix MMU context leak on GPU reset
authorLucas Stach <l.stach@pengutronix.de>
Fri, 20 Aug 2021 20:18:28 +0000 (22:18 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 22 Sep 2021 10:27:55 +0000 (12:27 +0200)
commit660dfbf208a4bf3eaab8560e8671be831b52e1c1
tree4f1638d4019ec91a0a2e370f9522aacfcfae3ab3
parent22163efedcf303e7d1b73bb3bd3aee26bd41b888
drm/etnaviv: fix MMU context leak on GPU reset

commit f978a5302f5566480c58ffae64a16d34456801bd upstream.

After a reset the GPU is no longer using the MMU context and may be
restarted with a different context. While the mmu_state proeprly was
cleared, the context wasn't unreferenced, leading to a memory leak.

Cc: stable@vger.kernel.org # 5.4
Reported-by: Michael Walle <michael@walle.cc>
Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Tested-by: Michael Walle <michael@walle.cc>
Tested-by: Marek Vasut <marex@denx.de>
Reviewed-by: Christian Gmeiner <christian.gmeiner@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/gpu/drm/etnaviv/etnaviv_gpu.c