turnip: Initialize memory type in requirements.
authorBas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Fri, 17 Aug 2018 12:43:01 +0000 (14:43 +0200)
committerChia-I Wu <olvaffe@gmail.com>
Mon, 11 Mar 2019 17:01:33 +0000 (10:01 -0700)
src/freedreno/vulkan/tu_device.c

index 54385fefd239b46c8bd443d580f782c63ea43a27..235aa44dbd70da4071d22d03993fa13fa835f282 100644 (file)
@@ -1379,6 +1379,7 @@ tu_GetBufferMemoryRequirements(VkDevice _device,
 {
    TU_FROM_HANDLE(tu_buffer, buffer, _buffer);
 
+   pMemoryRequirements->memoryTypeBits = 1;
    pMemoryRequirements->alignment = 16;
    pMemoryRequirements->size =
      align64(buffer->size, pMemoryRequirements->alignment);
@@ -1401,8 +1402,7 @@ tu_GetImageMemoryRequirements(VkDevice _device,
 {
    TU_FROM_HANDLE(tu_image, image, _image);
 
-   /* TODO: memory type */
-
+   pMemoryRequirements->memoryTypeBits = 1;
    pMemoryRequirements->size = image->size;
    pMemoryRequirements->alignment = image->alignment;
 }