Module: Mesa
Branch: staging/20.1
Commit: f73fd77eaa9d8abc444599fbde93c48ef4a561c4
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=f73fd77eaa9d8abc444599fbde93c48ef4a561c4

Author: Eric Engestrom <e...@engestrom.ch>
Date:   Fri May 29 20:19:22 2020 +0200

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 <e...@engestrom.ch>
Reviewed-by: Iago Toral Quiroga <ito...@igalia.com>
Reviewed-by: Eric Anholt <e...@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5263>
(cherry picked from commit 6456f71f765ce5139970445ae71172462c268a33)

---

 .pick_status.json                    | 2 +-
 src/gallium/drivers/v3d/v3d_bufmgr.c | 3 ++-
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/.pick_status.json b/.pick_status.json
index 6aa6c93c8f5..d8b725e032b 100644
--- a/.pick_status.json
+++ b/.pick_status.json
@@ -391,7 +391,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);

_______________________________________________
mesa-commit mailing list
mesa-commit@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to