diff options
author | Eric Anholt <[email protected]> | 2014-08-22 13:47:19 -0700 |
---|---|---|
committer | Eric Anholt <[email protected]> | 2014-09-02 12:10:56 -0700 |
commit | d71a9b7d9dc65a5cd56a81a816bc05535031d706 (patch) | |
tree | 096ac6335784a6c6d87d590bc9f80eab2c0c0f8c /src/gallium/drivers/vc4/vc4_bufmgr.h | |
parent | 8f55174fbdc27076f310c4dfb1f87072588b8b0b (diff) |
vc4: Handle a couple of the transfer map flags.
This is part of fixing extremely long runtimes on some piglit tests that
involve streaming vertex reuploads due to format conversions, and will
similarly be important for X performance, which relies on these flags.
Diffstat (limited to 'src/gallium/drivers/vc4/vc4_bufmgr.h')
-rw-r--r-- | src/gallium/drivers/vc4/vc4_bufmgr.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/gallium/drivers/vc4/vc4_bufmgr.h b/src/gallium/drivers/vc4/vc4_bufmgr.h index 14bfa2466df..00ea149bd5f 100644 --- a/src/gallium/drivers/vc4/vc4_bufmgr.h +++ b/src/gallium/drivers/vc4/vc4_bufmgr.h @@ -70,6 +70,9 @@ vc4_bo_reference(struct vc4_bo *bo) static inline void vc4_bo_unreference(struct vc4_bo **bo) { + if (!*bo) + return; + if (pipe_reference(&(*bo)->reference, NULL)) vc4_bo_free(*bo); *bo = NULL; |