radv: Do not use the bo list for local buffers.
authorBas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Fri, 25 Jan 2019 00:56:45 +0000 (01:56 +0100)
committerBas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Wed, 6 Feb 2019 21:36:19 +0000 (22:36 +0100)
The kernel already does it for us.

Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
src/amd/vulkan/radv_device.c

index b8ef93d0cd28075c7ca5f38d2a03cb5fc7db0727..5202d83a418f5724fee74d95a59c4ae7b160f05e 100644 (file)
@@ -1551,6 +1551,9 @@ static VkResult radv_bo_list_add(struct radv_device *device,
 {
        struct radv_bo_list *bo_list = &device->bo_list;
 
+       if (bo->is_local)
+               return VK_SUCCESS;
+
        if (unlikely(!device->use_global_bo_list))
                return VK_SUCCESS;
 
@@ -1578,6 +1581,9 @@ static void radv_bo_list_remove(struct radv_device *device,
 {
        struct radv_bo_list *bo_list = &device->bo_list;
 
+       if (bo->is_local)
+               return;
+
        if (unlikely(!device->use_global_bo_list))
                return;