drm/vc4: gem: Add a managed action to cleanup the job queue
authorMaxime Ripard <maxime@cerno.tech>
Thu, 29 Oct 2020 19:01:01 +0000 (20:01 +0100)
committerMaxime Ripard <maxime@cerno.tech>
Mon, 2 Nov 2020 11:14:43 +0000 (12:14 +0100)
commit171a072b4699b4bf79cd1bbbcd05a53d40903034
treea3599950ff7be0c012f8aefd770012becf76cd1a
parente46e5330d13de67de5b614c5021730e9709de975
drm/vc4: gem: Add a managed action to cleanup the job queue

The job queue needs to be cleaned up using vc4_gem_destroy, but it's
not used consistently (vc4_drv's bind calls it in its error path, but
doesn't in unbind), and we can make that automatic through a managed
action. Let's remove the requirement to call vc4_gem_destroy.

Fixes: d5b1a78a772f ("drm/vc4: Add support for drawing 3D frames.")
Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Maxime Ripard <maxime@cerno.tech>
Link: https://patchwork.freedesktop.org/patch/msgid/20201029190104.2181730-3-maxime@cerno.tech
drivers/gpu/drm/vc4/vc4_drv.c
drivers/gpu/drm/vc4/vc4_drv.h
drivers/gpu/drm/vc4/vc4_gem.c