drm/panfrost: Fix shrinker list corruption by madvise IOCTL
Calling madvise IOCTL twice on BO causes memory shrinker list corruption and crashes kernel because BO is already on the list and it's added to the list again, while BO should be removed from the list before it's re-added. Fix it. Cc: stable@vger.kernel.org Fixes: 013b6510 ("drm/panfrost: Add madvise and shrinker support") Acked-by: NAlyssa Rosenzweig <alyssa.rosenzweig@collabora.com> Reviewed-by: NSteven Price <steven.price@arm.com> Signed-off-by: NDmitry Osipenko <dmitry.osipenko@collabora.com> Signed-off-by: NSteven Price <steven.price@arm.com> Link: https://patchwork.freedesktop.org/patch/msgid/20220630200601.1884120-3-dmitry.osipenko@collabora.com
Showing
想要评论请 注册 或 登录