From c6a80dc32ef17bc972d4137ce7444ebed4d28ebb Mon Sep 17 00:00:00 2001 From: Keith Whitwell Date: Tue, 23 Mar 2010 13:52:15 -0700 Subject: r300: restore 4k alignment for oqbo buffers --- src/gallium/drivers/r300/r300_screen_buffer.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/gallium/drivers/r300/r300_screen_buffer.c b/src/gallium/drivers/r300/r300_screen_buffer.c index c4357babf2..033621c67d 100644 --- a/src/gallium/drivers/r300/r300_screen_buffer.c +++ b/src/gallium/drivers/r300/r300_screen_buffer.c @@ -310,6 +310,7 @@ struct pipe_resource *r300_buffer_create(struct pipe_screen *screen, { struct r300_screen *r300screen = r300_screen(screen); struct r300_buffer *rbuf; + unsigned alignment = 16; rbuf = CALLOC_STRUCT(r300_buffer); if (!rbuf) @@ -322,9 +323,12 @@ struct pipe_resource *r300_buffer_create(struct pipe_screen *screen, pipe_reference_init(&rbuf->b.b.reference, 1); rbuf->b.b.screen = screen; + if (bind & R300_BIND_OQBO) + alignment = 4096; + rbuf->buf = r300_winsys_buffer_create(r300screen, - 16, - rbuf->b.b.bind, /* XXX */ + alignment, + rbuf->b.b.bind, rbuf->b.b.width0); if (!rbuf->buf) -- cgit v1.2.3