summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnuj Phogat <anuj.phogat@gmail.com>2014-01-07 17:46:45 -0800
committerCarl Worth <cworth@cworth.org>2014-03-10 15:34:14 -0700
commit59ab5bf0a078836e5e1d4b0ff0e8f36bcfb033fe (patch)
treef27ce726331807f0275cac105c4098989273f163
parent85e04ad280f4fc7dc67cbf072244f74089964a99 (diff)
downloadmesa-59ab5bf0a078836e5e1d4b0ff0e8f36bcfb033fe.tar.gz
i965: Fix the region's pitch condition to use blitter
intelEmitCopyBlit uses a signed 16-bit integer to represent buffer pitch, so it can only handle buffer pitches < 32k. Cc: mesa-stable@lists.freedesktop.org Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> (cherry picked from commit b3094d9927fe7aa5a84892262404aaad4d728724)
-rw-r--r--src/mesa/drivers/dri/i965/intel_blit.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mesa/drivers/dri/i965/intel_blit.c b/src/mesa/drivers/dri/i965/intel_blit.c
index 0a03859df3e..415c354ae2a 100644
--- a/src/mesa/drivers/dri/i965/intel_blit.c
+++ b/src/mesa/drivers/dri/i965/intel_blit.c
@@ -199,9 +199,9 @@ intel_miptree_blit(struct brw_context *brw,
* As a result of these two limitations, we can only use the blitter to do
* this copy when the region's pitch is less than 32k.
*/
- if (src_mt->region->pitch > 32768 ||
- dst_mt->region->pitch > 32768) {
- perf_debug("Falling back due to >32k pitch\n");
+ if (src_mt->region->pitch >= 32768 ||
+ dst_mt->region->pitch >= 32768) {
+ perf_debug("Falling back due to >=32k pitch\n");
return false;
}