diff options
Diffstat (limited to 'src/gallium/drivers/nv50')
-rw-r--r-- | src/gallium/drivers/nv50/nv50_miptree.c | 6 | ||||
-rw-r--r-- | src/gallium/drivers/nv50/nv50_resource.h | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/src/gallium/drivers/nv50/nv50_miptree.c b/src/gallium/drivers/nv50/nv50_miptree.c index ed0f8c2b2f1..fe481887570 100644 --- a/src/gallium/drivers/nv50/nv50_miptree.c +++ b/src/gallium/drivers/nv50/nv50_miptree.c @@ -213,7 +213,7 @@ nv50_miptree_init_ms_mode(struct nv50_miptree *mt) } boolean -nv50_miptree_init_layout_linear(struct nv50_miptree *mt) +nv50_miptree_init_layout_linear(struct nv50_miptree *mt, unsigned pitch_align) { struct pipe_resource *pt = &mt->base.base; const unsigned blocksize = util_format_get_blocksize(pt->format); @@ -227,7 +227,7 @@ nv50_miptree_init_layout_linear(struct nv50_miptree *mt) if (mt->ms_x | mt->ms_y) return FALSE; - mt->level[0].pitch = align(pt->width0 * blocksize, 64); + mt->level[0].pitch = align(pt->width0 * blocksize, pitch_align); /* Account for very generous prefetch (allocate size as if tiled). */ h = MAX2(h, 8); @@ -314,7 +314,7 @@ nv50_miptree_create(struct pipe_screen *pscreen, if (bo_config.nv50.memtype != 0) { nv50_miptree_init_layout_tiled(mt); } else - if (!nv50_miptree_init_layout_linear(mt)) { + if (!nv50_miptree_init_layout_linear(mt, 64)) { FREE(mt); return NULL; } diff --git a/src/gallium/drivers/nv50/nv50_resource.h b/src/gallium/drivers/nv50/nv50_resource.h index a2bc9803fbe..469d812098f 100644 --- a/src/gallium/drivers/nv50/nv50_resource.h +++ b/src/gallium/drivers/nv50/nv50_resource.h @@ -67,7 +67,7 @@ nv50_miptree(struct pipe_resource *pt) /* Internal functions: */ boolean -nv50_miptree_init_layout_linear(struct nv50_miptree *mt); +nv50_miptree_init_layout_linear(struct nv50_miptree *mt, unsigned pitch_align); struct pipe_resource * nv50_miptree_create(struct pipe_screen *pscreen, |