summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Engestrom <eric@engestrom.ch>2020-05-29 20:19:22 +0200
committerEric Engestrom <eric@engestrom.ch>2020-06-24 23:03:50 +0200
commit6fdd0b39a9c02f49faf4df065916f8ac1c90a24a (patch)
tree00d3e5726fc147c14660e980bf88d28780204bae
parentd8372602768eff0d4d0accd1e28ea3cc1739b650 (diff)
v3d: add missing unlock() in error path
CoverityID: 1435701 Fixes: e5a81ac70431502bc592 ("broadcom/vc5: Don't forget to get the BO offset when opening a dmabuf.") Signed-off-by: Eric Engestrom <eric@engestrom.ch> Reviewed-by: Iago Toral Quiroga <itoral@igalia.com> Reviewed-by: Eric Anholt <eric@anholt.net> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5263> (cherry picked from commit 6456f71f765ce5139970445ae71172462c268a33)
-rw-r--r--.pick_status.json2
-rw-r--r--src/gallium/drivers/v3d/v3d_bufmgr.c3
2 files changed, 3 insertions, 2 deletions
diff --git a/.pick_status.json b/.pick_status.json
index 8d5c1fa0f98..7b19bd23c24 100644
--- a/.pick_status.json
+++ b/.pick_status.json
@@ -4216,7 +4216,7 @@
"description": "v3d: add missing unlock() in error path",
"nominated": true,
"nomination_type": 1,
- "resolution": 0,
+ "resolution": 1,
"master_sha": null,
"because_sha": "e5a81ac70431502bc592c05e4ae639c0504ec816"
},
diff --git a/src/gallium/drivers/v3d/v3d_bufmgr.c b/src/gallium/drivers/v3d/v3d_bufmgr.c
index 31a08036b38..dd8a2e98611 100644
--- a/src/gallium/drivers/v3d/v3d_bufmgr.c
+++ b/src/gallium/drivers/v3d/v3d_bufmgr.c
@@ -367,7 +367,8 @@ v3d_bo_open_handle(struct v3d_screen *screen,
strerror(errno));
free(bo->map);
free(bo);
- return NULL;
+ bo = NULL;
+ goto done;
}
bo->offset = get.offset;
assert(bo->offset != 0);