drm/v3d: don't leak bin job if v3d_job_init fails.
authorIago Toral Quiroga <itoral@igalia.com>
Mon, 16 Sep 2019 07:11:25 +0000 (09:11 +0200)
committerEric Anholt <eric@anholt.net>
Wed, 18 Sep 2019 17:30:44 +0000 (10:30 -0700)
commit0d352a3a8a1f26168d09f7073e61bb4b328e3bb9
tree6ead80abea5a4075568c1ab56fd05c0da6c79c08
parent69b22f51e6644b6592087fe157537dd5f68e30bb
drm/v3d: don't leak bin job if v3d_job_init fails.

If the initialization of the job fails we need to kfree() it
before returning.

Signed-off-by: Iago Toral Quiroga <itoral@igalia.com>
Signed-off-by: Eric Anholt <eric@anholt.net>
Link: https://patchwork.freedesktop.org/patch/msgid/20190916071125.5255-1-itoral@igalia.com
Fixes: a783a09ee76d ("drm/v3d: Refactor job management.")
Reviewed-by: Eric Anholt <eric@anholt.net>
drivers/gpu/drm/v3d/v3d_gem.c