diff options
author | Carl Worth <cworth@cworth.org> | 2009-05-06 09:17:46 -0700 |
---|---|---|
committer | Carl Worth <cworth@cworth.org> | 2009-05-06 09:17:46 -0700 |
commit | a066cfb0be6e6b20a27eb4ba17f503f13e65e082 (patch) | |
tree | 968be45113893c11de4cf78014bc55e6286d1f82 | |
parent | 115fc9a7d79da07301b96d9fc5c513d33734d273 (diff) |
Hold reference to video binding table until all rects are painted.
The optimization of unreferencing the binding table when the relocation is
posted causes the object to be dereferenced for each box in the clip list,
causing general chaos in the buffer manager. It's easier to just hold a
reference to the object until all of the boxes are painted and then drop it.
Signed-off-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit 11a853bd8e5d907fe7f5bd907453bcdac9032861)
Conflicts:
src/i965_video.c
-rw-r--r-- | src/i965_video.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/i965_video.c b/src/i965_video.c index f6020d4e..c0a69fd6 100644 --- a/src/i965_video.c +++ b/src/i965_video.c @@ -795,7 +795,6 @@ i965_emit_video_setup(ScrnInfoPtr pScrn, drm_intel_bo *bind_bo, int n_src_surf) OUT_BATCH(0); /* sf */ /* Only the PS uses the binding table */ OUT_RELOC(bind_bo, I915_GEM_DOMAIN_INSTRUCTION, 0, 0); - drm_intel_bo_unreference(bind_bo); /* Blend constant color (magenta is fun) */ OUT_BATCH(BRW_3DSTATE_CONSTANT_COLOR | 3); @@ -1161,6 +1160,10 @@ I965DisplayVideoTextured(ScrnInfoPtr pScrn, I830PortPrivPtr pPriv, int id, } i830MarkSync(pScrn); + + /* release reference once we're finished */ + drm_intel_bo_unreference(bind_bo); + #if WATCH_STATS i830_dump_error_state(pScrn); #endif |