[MA-289][WORKAROUND] block on swapchain aquire to prevent Mozart from getting ahead of itself

Change-Id: I0cf66cc9ca7cb27d67429d07b47173b6b85e79b2
diff --git a/src/vulkan/wsi/wsi_common_magma.cc b/src/vulkan/wsi/wsi_common_magma.cc
index 099dcf7..8c75aba 100644
--- a/src/vulkan/wsi/wsi_common_magma.cc
+++ b/src/vulkan/wsi/wsi_common_magma.cc
@@ -243,6 +243,15 @@
       uint32_t index = chain->next_index_;
       MagmaImage* image = chain->get_image(index);
 
+      //TODO(MA-289) remove this wait/signal once Mozart 2.0 lands
+      magma_status_t status = magma_wait_semaphore(image->display_semaphore(), timeout);
+      if (status == MAGMA_STATUS_TIMED_OUT) {
+         DLOG("timeout waiting for image semaphore");
+         return VK_TIMEOUT;
+      }
+      magma_signal_semaphore(image->display_semaphore());
+
+
       DLOG("AcquireNextImage semaphore id 0x%" PRIx64,
            magma_get_semaphore_id(image->display_semaphore()));