drm: writeback: Cleanup job ownership handling when queuing job
authorLaurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Thu, 21 Feb 2019 10:17:32 +0000 (12:17 +0200)
committerLaurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Mon, 18 Mar 2019 15:24:30 +0000 (17:24 +0200)
commit97eb9eaeb95ba8eb3c7a77a7ec7786d47a1bcaee
tree23475d0d548703ad3e775ef57e64a8bd48a5b666
parenta63722aeb76c65f39c98c66a1e730a2f3da123ab
drm: writeback: Cleanup job ownership handling when queuing job

The drm_writeback_queue_job() function takes ownership of the passed job
and requires the caller to manually set the connector state
writeback_job pointer to NULL. To simplify drivers and avoid errors
(such as the missing NULL set in the vc4 driver), pass the connector
state pointer to the function instead of the job pointer, and set the
writeback_job pointer to NULL internally.

Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Reviewed-by: Brian Starkey <brian.starkey@arm.com>
Acked-by: Eric Anholt <eric@anholt.net>
Acked-by: Liviu Dudau <liviu.dudau@arm.com>
Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
drivers/gpu/drm/arm/malidp_mw.c
drivers/gpu/drm/drm_writeback.c
drivers/gpu/drm/vc4/vc4_txp.c
include/drm/drm_writeback.h