[Mesa-dev] [PATCH 02/18] i965: Fix offset-aligned-to-tile test in dma_buf import.

Eric Anholt eric at anholt.net
Tue Apr 29 16:34:27 PDT 2014


v1 of the patch got pushed, insted of the v2 that I had reviewed.
---
 src/mesa/drivers/dri/i965/intel_screen.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/src/mesa/drivers/dri/i965/intel_screen.c b/src/mesa/drivers/dri/i965/intel_screen.c
index 46a7e3b..d708efe 100644
--- a/src/mesa/drivers/dri/i965/intel_screen.c
+++ b/src/mesa/drivers/dri/i965/intel_screen.c
@@ -637,7 +637,6 @@ intel_create_image_from_fds(__DRIscreen *screen,
 {
    struct intel_screen *intelScreen = screen->driverPrivate;
    struct intel_image_format *f;
-   uint32_t mask_x, mask_y;
    __DRIimage *image;
    int i, index;
 
@@ -673,8 +672,7 @@ intel_create_image_from_fds(__DRIscreen *screen,
 
    if (f->nplanes == 1) {
       image->offset = image->offsets[0];
-      intel_region_get_tile_masks(image->region, &mask_x, &mask_y, false);
-      if (image->offset & mask_x)
+      if (image->region->tiling != I915_TILING_NONE && (image->offset & 0xfff))
          _mesa_warning(NULL,
                        "intel_create_image_from_fds: offset not on tile boundary");
    }
-- 
1.9.2



More information about the mesa-dev mailing list