panfrost: Delete debug allocated syncobj.

Fix defect reported by Coverity Scan.

Logically dead code (DEADCODE)
dead_error_line: Execution cannot reach this statement: drmSyncobjDestroy(dev->fd, ...

Fixes: 64d6f56ad2 ("panfrost: Allocate syncobjs in panfrost_flush")
Signed-off-by: Vinson Lee <vlee@freedesktop.org>
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6720>
This commit is contained in:
Vinson Lee
2020-09-14 17:53:31 -07:00
committed by Marge Bot
parent fcc506e520
commit ffbdbd631a
+4 -1
View File
@@ -970,7 +970,7 @@ panfrost_batch_submit_ioctl(struct panfrost_batch *batch,
if (!out_sync && dev->debug & (PAN_DBG_TRACE | PAN_DBG_SYNC)) {
drmSyncobjCreate(dev->fd, 0, &out_sync);
our_sync = false;
our_sync = true;
}
submit.out_sync = out_sync;
@@ -1003,6 +1003,9 @@ panfrost_batch_submit_ioctl(struct panfrost_batch *batch,
if (dev->debug & PAN_DBG_MSGS)
fprintf(stderr, "Error submitting: %m\n");
if (our_sync)
drmSyncobjDestroy(dev->fd, out_sync);
return errno;
}