From: Topi Pohjolainen Date: Sat, 22 Apr 2017 06:37:10 +0000 (+0300) Subject: i965/blorp: Prepare for isl based miptrees X-Git-Tag: upstream/18.1.0~8642 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=7294cde750cc5dcad0a24e826440fdb00da53eae;p=platform%2Fupstream%2Fmesa.git i965/blorp: Prepare for isl based miptrees Reviewed-by: Jason Ekstrand Signed-off-by: Topi Pohjolainen --- diff --git a/src/mesa/drivers/dri/i965/brw_blorp.c b/src/mesa/drivers/dri/i965/brw_blorp.c index e8993a8..f13b61b 100644 --- a/src/mesa/drivers/dri/i965/brw_blorp.c +++ b/src/mesa/drivers/dri/i965/brw_blorp.c @@ -148,8 +148,13 @@ blorp_surf_for_miptree(struct brw_context *brw, intel_miptree_check_level_layer(mt, *level, start_layer + i); } - intel_miptree_get_isl_surf(brw, mt, &tmp_surfs[0]); - surf->surf = &tmp_surfs[0]; + if (mt->surf.size > 0) { + surf->surf = &mt->surf; + } else { + intel_miptree_get_isl_surf(brw, mt, &tmp_surfs[0]); + surf->surf = &tmp_surfs[0]; + } + surf->addr = (struct blorp_address) { .buffer = mt->bo, .offset = mt->offset,