(Reland) Allow ColorBufferVk setup failures

... to match the previous behavior where the Vulkan backing
was deferred until the first actual Vulkan usage of the
ColorBuffer.

Eventually, Gfxstream should fully implement VIRTGPU_GET_CAPS
and properly send support info into the guest gralloc
implementations. Gfxstream VK format support checking should
also potentially be updated to not completely disable a format
if external memory is for that format isn't supported. For
example, VK_FORMAT_R8G8B8_UNORM may not support external memory.
Currently, getImageFormatExternalMemorySupportInfo() seems to
completely disable the format instead of just marking
supportsExternalMemory as false.

Reland note: no changes from previous aosp/2433613

Bug: b/233939967
Test: android build
Test: cmake build
Test: cvd start --gpu_mode=gfxstream
Test: cvd start --gpu_mode=gfxstream --enable_gpu_angle=true
Test: gfxstream unit tests
Change-Id: I78b42ca14a70347727054ec8c8732b860ffafdbc
diff --git a/stream-servers/vulkan/VkCommonOperations.cpp b/stream-servers/vulkan/VkCommonOperations.cpp
index 764a30b..daeb56a 100644
--- a/stream-servers/vulkan/VkCommonOperations.cpp
+++ b/stream-servers/vulkan/VkCommonOperations.cpp
@@ -1742,7 +1742,11 @@
 bool setupVkColorBuffer(uint32_t width, uint32_t height, GLenum internalFormat,
                         FrameworkFormat frameworkFormat, uint32_t colorBufferHandle,
                         bool vulkanOnly, uint32_t memoryProperty) {
-    if (!isFormatVulkanCompatible(internalFormat)) return false;
+    if (!isFormatVulkanCompatible(internalFormat)) {
+        VK_COMMON_ERROR("Failed to create Vk ColorBuffer: format:%d not compatible.",
+                        internalFormat);
+        return false;
+    }
 
     AutoLock lock(sVkEmulationLock);