[Mesa-dev] [PATCH] radeonsi: fix order of r600_need_dma_space and r600_context_bo_reloc
Marek Olšák
maraeo at gmail.com
Wed Jul 9 06:05:23 PDT 2014
Reviewed-by: Marek Olšák <marek.olsak at amd.com>
Marek
On Wed, Jul 9, 2014 at 2:38 PM, Christian König <deathsimple at vodafone.de> wrote:
> From: Christian König <christian.koenig at amd.com>
>
> Signed-off-by: Christian König <christian.koenig at amd.com>
> ---
> src/gallium/drivers/radeonsi/si_dma.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/src/gallium/drivers/radeonsi/si_dma.c b/src/gallium/drivers/radeonsi/si_dma.c
> index dc8c609..26f1e1b 100644
> --- a/src/gallium/drivers/radeonsi/si_dma.c
> +++ b/src/gallium/drivers/radeonsi/si_dma.c
> @@ -91,12 +91,13 @@ static void si_dma_copy_buffer(struct si_context *ctx,
> }
> ncopy = (size / max_csize) + !!(size % max_csize);
>
> + r600_need_dma_space(&ctx->b, ncopy * 5);
> +
> r600_context_bo_reloc(&ctx->b, &ctx->b.rings.dma, rsrc, RADEON_USAGE_READ,
> RADEON_PRIO_MIN);
> r600_context_bo_reloc(&ctx->b, &ctx->b.rings.dma, rdst, RADEON_USAGE_WRITE,
> RADEON_PRIO_MIN);
>
> - r600_need_dma_space(&ctx->b, ncopy * 5);
> for (i = 0; i < ncopy; i++) {
> csize = size < max_csize ? size : max_csize;
> cs->buf[cs->cdw++] = SI_DMA_PACKET(SI_DMA_PACKET_COPY, sub_cmd, csize);
> --
> 1.9.1
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/mesa-dev
More information about the mesa-dev
mailing list