Comment 201 for bug 359392

Revision history for this message
Jesse Barnes (jbarnes-virtuousgeek) wrote :

Ok so the bug I mentioned in 196 doesn't actually exist, so ignore that request.

However Eric is now worried about the buffer reuse we're seeing in the dumps. If caching is at all wrong or we're not taking care to reset the buffer contents correctly between reuse it could easily cause problems.

Buffer object reuse can be disabled in the 3D driver by setting the bo_reuse DRI variable to 0 (it defaults to 1). The 2D driver needs to be patched to avoid re-use though:

diff --git a/src/i830_driver.c b/src/i830_driver.c
index 6ec2cdd..c43a7be 100644
--- a/src/i830_driver.c
+++ b/src/i830_driver.c
@@ -2835,7 +2835,7 @@ i830_init_bufmgr(ScrnInfoPtr pScrn)
         batch_size = 4096;

       pI830->bufmgr = intel_bufmgr_gem_init(pI830->drmSubFD, batch_size);
- intel_bufmgr_gem_enable_reuse(pI830->bufmgr);
+// intel_bufmgr_gem_enable_reuse(pI830->bufmgr);
    } else {
       assert(pI830->FbBase != NULL);