From: Marek Olšák Date: Wed, 24 Feb 2016 16:33:28 +0000 (+0100) Subject: gallium/radeon: don't set texture metadata for buffers X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=be73d358298b04624cdeca7113eedd10e3e37e6c;p=mesa.git gallium/radeon: don't set texture metadata for buffers Reviewed-by: Michel Dänzer Reviewed-by: Nicolai Hähnle --- diff --git a/src/gallium/drivers/radeon/r600_texture.c b/src/gallium/drivers/radeon/r600_texture.c index 5e77080eed2..558dc73d9d4 100644 --- a/src/gallium/drivers/radeon/r600_texture.c +++ b/src/gallium/drivers/radeon/r600_texture.c @@ -261,8 +261,11 @@ static boolean r600_texture_get_handle(struct pipe_screen* screen, if (!res->is_shared) { res->is_shared = true; - r600_texture_init_metadata(rtex, &metadata); - rscreen->ws->buffer_set_metadata(res->buf, &metadata); + + if (resource->target != PIPE_BUFFER) { + r600_texture_init_metadata(rtex, &metadata); + rscreen->ws->buffer_set_metadata(res->buf, &metadata); + } } return rscreen->ws->buffer_get_handle(res->buf,