From 2c94f659e8453bb584e1d50b188d4199fe7b8194 Mon Sep 17 00:00:00 2001 From: Nanley Chery Date: Wed, 30 Dec 2015 16:00:47 -0800 Subject: [PATCH] anv/meta: Fix CopyBuffer when size matches HW limit Perform a copy when the copy_size matches the HW limit (max_copy_size). Otherwise the current behavior is that we fail the following assertion: assert(height < max_surface_dim); because the values are equal. --- src/vulkan/anv_meta.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vulkan/anv_meta.c b/src/vulkan/anv_meta.c index 483469348c8..351af219e7f 100644 --- a/src/vulkan/anv_meta.c +++ b/src/vulkan/anv_meta.c @@ -846,7 +846,7 @@ void anv_CmdCopyBuffer( /* First, we make a bunch of max-sized copies */ uint64_t max_copy_size = max_surface_dim * max_surface_dim * bs; - while (copy_size > max_copy_size) { + while (copy_size >= max_copy_size) { do_buffer_copy(cmd_buffer, src_buffer->bo, src_offset, dest_buffer->bo, dest_offset, max_surface_dim, max_surface_dim, copy_format); -- 2.30.2