diff options
author | Zhigang Gong <zhigang.gong@linux.intel.com> | 2012-06-26 13:09:05 +0800 |
---|---|---|
committer | Zhigang Gong <zhigang.gong@linux.intel.com> | 2012-07-03 18:30:15 +0800 |
commit | 8c178c206b86a01b9beceabcdc7b5ebf658d3ee9 (patch) | |
tree | 727239afeb949ec52a0dc6f371888110e8c3c3e3 | |
parent | 7e9ee2760c93c23ed71046e4ff65fe6d5998c558 (diff) |
glamor: glamor_largepixmap: Walkaround for large texture's upload.
I met a problem with large texture (larger than 7000x7000)'s
uploading on SNB platform. The map_gtt get back a mapped VA
without error, but write to that virtual address triggers
BUS error. This work around is to avoid that direct uploading.
Signed-off-by: Zhigang Gong <zhigang.gong@linux.intel.com>
-rw-r--r-- | glamor_pixmap.c | 6 | ||||
-rw-r--r-- | glamor_priv.h | 1 |
2 files changed, 6 insertions, 1 deletions
diff --git a/glamor_pixmap.c b/glamor_pixmap.c index ce243ab..10066a6 100644 --- a/glamor_pixmap.c +++ b/glamor_pixmap.c @@ -497,7 +497,11 @@ ready_to_upload: if (no_alpha == 0 && revert == REVERT_NONE && swap_rb == SWAP_NONE_UPLOADING - && !need_flip) { + && !need_flip +#ifdef WALKAROUND_LARGE_TEXTURE_MAP + && pixmap_priv->type != GLAMOR_TEXTURE_LARGE +#endif + ) { int fbo_x_off, fbo_y_off; assert(pixmap_priv->base.fbo->tex); pixmap_priv_get_fbo_off(pixmap_priv, &fbo_x_off, &fbo_y_off); diff --git a/glamor_priv.h b/glamor_priv.h index 4fad5cd..642aff6 100644 --- a/glamor_priv.h +++ b/glamor_priv.h @@ -1001,6 +1001,7 @@ glamor_poly_line(DrawablePtr pDrawable, GCPtr pGC, int mode, int npt, //#define GLAMOR_TRAPEZOID_SHADER #endif #define GLAMOR_TEXTURED_LARGE_PIXMAP 1 +#define WALKAROUND_LARGE_TEXTURE_MAP #if 0 #define MAX_FBO_SIZE 32 /* For test purpose only. */ #endif |