xf86-video-intel: src/i830_memory.c

Jesse Barnes jbarnes at kemper.freedesktop.org
Tue Jun 30 16:03:34 PDT 2009


 src/i830_memory.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 058ad9e6ab4a00ff66046d94c2129056011ebee9
Author: Jesse Barnes <jbarnes at virtuousgeek.org>
Date:   Tue Jun 30 16:02:19 2009 -0700

    Don't try to pin buffers in KMS mode
    
    The only things we try to pin in KMS mode are the cursor objects and
    front buffer, and those are taken care of by the kernel anyway, so we
    shouldn't even bother trying to pin them (well, not entirely true,
    XvMC tries to pin as well, but it needs work w/KMS anyway).
    
    Signed-off-by: Jesse Barnes <jbarnes at virtuousgeek.org>

diff --git a/src/i830_memory.c b/src/i830_memory.c
index 5e07213..387e52b 100644
--- a/src/i830_memory.c
+++ b/src/i830_memory.c
@@ -202,7 +202,7 @@ i830_bind_memory(ScrnInfoPtr pScrn, i830_memory *mem)
     if (mem == NULL || mem->bound)
 	return TRUE;
 
-    if (mem->bo != NULL) {
+    if (mem->bo != NULL && !pI830->use_drm_mode) {
 	if (dri_bo_pin(mem->bo, mem->alignment) != 0) {
 	    xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
 		       "Failed to pin %s: %s\n",
@@ -249,7 +249,7 @@ i830_unbind_memory(ScrnInfoPtr pScrn, i830_memory *mem)
 	!pI830->kernel_exec_fencing)
 	i830_clear_tiling(pScrn, mem->fence_nr);
 
-    if (mem->bo != NULL) {
+    if (mem->bo != NULL && !pI830->use_drm_mode) {
 	if (dri_bo_unpin(mem->bo) == 0) {
 	    mem->bound = FALSE;
 	    /* Give buffer obviously wrong offset/end until it's re-pinned. */


More information about the xorg-commit mailing list