[fuchsia] Merge all fuchsia.hardware.goldfish.* FIDLs into one

Fuchsia CL: https://fuchsia-review.googlesource.com/c/fuchsia/+/330949

In this change we merge all the following FIDLs:
  - fuchsia.hardware.goldfish.address.space
  - fuchsia.hardware.goldfish.control
  - fuchsia.hardware.goldfish.pipe
into one single FIDL named fuchsia.hardware.goldfish.

TEST:
1) Run AEMU correctly
2) goldfish_test PASS, goldfish_benchmark PASS

Change-Id: Ib4e21ee488a464f2b81933ea6bc308084b761e11
diff --git a/BUILD.gn b/BUILD.gn
index c6e0201..2a16489 100644
--- a/BUILD.gn
+++ b/BUILD.gn
@@ -127,9 +127,7 @@
     ]
 
     deps = [
-      "//zircon/system/fidl/fuchsia-hardware-goldfish-address-space",
-      "//zircon/system/fidl/fuchsia-hardware-goldfish-control",
-      "//zircon/system/fidl/fuchsia-hardware-goldfish-pipe",
+      "//zircon/system/fidl/fuchsia-hardware-goldfish",
       "//zircon/system/fidl/fuchsia-sysmem",
       "//zircon/public/lib/fdio",
       "//zircon/public/lib/trace",
diff --git a/shared/OpenglCodecCommon/goldfish_address_space.h b/shared/OpenglCodecCommon/goldfish_address_space.h
index f02fa2e..9a7af71 100644
--- a/shared/OpenglCodecCommon/goldfish_address_space.h
+++ b/shared/OpenglCodecCommon/goldfish_address_space.h
@@ -19,7 +19,7 @@
 #include <stddef.h>
 
 #ifdef __Fuchsia__
-#include <fuchsia/hardware/goldfish/address/space/cpp/fidl.h>
+#include <fuchsia/hardware/goldfish/cpp/fidl.h>
 #endif
 
 class GoldfishAddressSpaceBlock;
@@ -60,7 +60,7 @@
     static void closeHandle(address_space_handle_t handle);
 
 #ifdef __Fuchsia__
-    fuchsia::hardware::goldfish::address::space::DeviceSyncPtr m_device;
+    fuchsia::hardware::goldfish::AddressSpaceDeviceSyncPtr m_device;
 #else // __Fuchsia__
     address_space_handle_t m_handle;
 #endif // !__Fuchsia__
@@ -91,7 +91,7 @@
     GoldfishAddressSpaceBlock &operator=(const GoldfishAddressSpaceBlock &);
 
 #ifdef __Fuchsia__
-    fuchsia::hardware::goldfish::address::space::DeviceSyncPtr* m_device;
+    fuchsia::hardware::goldfish::AddressSpaceDeviceSyncPtr* m_device;
     uint32_t  m_vmo;
 #else // __Fuchsia__
     address_space_handle_t m_handle;
diff --git a/shared/OpenglCodecCommon/goldfish_address_space_fuchsia.impl b/shared/OpenglCodecCommon/goldfish_address_space_fuchsia.impl
index d11fcd1..7373ac2 100644
--- a/shared/OpenglCodecCommon/goldfish_address_space_fuchsia.impl
+++ b/shared/OpenglCodecCommon/goldfish_address_space_fuchsia.impl
@@ -98,7 +98,7 @@
         return false;
     }
 
-    fuchsia::hardware::goldfish::address::space::DeviceSyncPtr* device = &provider->m_device;
+    fuchsia::hardware::goldfish::AddressSpaceDeviceSyncPtr* device = &provider->m_device;
 
     int32_t res = ZX_OK;
     zx::vmo vmo;
diff --git a/system/OpenglSystemCommon/ProcessPipe.cpp b/system/OpenglSystemCommon/ProcessPipe.cpp
index e04d153..823509c 100644
--- a/system/OpenglSystemCommon/ProcessPipe.cpp
+++ b/system/OpenglSystemCommon/ProcessPipe.cpp
@@ -26,7 +26,7 @@
 #include <errno.h>
 
 #ifdef __Fuchsia__
-#include <fuchsia/hardware/goldfish/pipe/cpp/fidl.h>
+#include <fuchsia/hardware/goldfish/cpp/fidl.h>
 #include <lib/fdio/fdio.h>
 #include <lib/zx/vmo.h>
 static QEMU_PIPE_HANDLE   sProcDevice = 0;
@@ -64,10 +64,10 @@
         return;
     }
 
-    fuchsia::hardware::goldfish::pipe::DeviceSyncPtr device;
+    fuchsia::hardware::goldfish::PipeDeviceSyncPtr device;
     device.Bind(std::move(channel));
 
-    fuchsia::hardware::goldfish::pipe::PipeSyncPtr pipe;
+    fuchsia::hardware::goldfish::PipeSyncPtr pipe;
     device->OpenPipe(pipe.NewRequest());
 
     zx_status_t status2 = ZX_OK;
diff --git a/system/OpenglSystemCommon/QemuPipeStream.h b/system/OpenglSystemCommon/QemuPipeStream.h
index 65755da..87638af 100644
--- a/system/OpenglSystemCommon/QemuPipeStream.h
+++ b/system/OpenglSystemCommon/QemuPipeStream.h
@@ -26,7 +26,7 @@
 #include "qemu_pipe.h"
 
 #ifdef __Fuchsia__
-#include <fuchsia/hardware/goldfish/pipe/cpp/fidl.h>
+#include <fuchsia/hardware/goldfish/cpp/fidl.h>
 #include <lib/zx/event.h>
 #include <lib/zx/vmo.h>
 #endif
@@ -58,8 +58,8 @@
     size_t m_read;
     size_t m_readLeft;
 #ifdef __Fuchsia__
-    fuchsia::hardware::goldfish::pipe::DeviceSyncPtr m_device;
-    fuchsia::hardware::goldfish::pipe::PipeSyncPtr m_pipe;
+    fuchsia::hardware::goldfish::PipeDeviceSyncPtr m_device;
+    fuchsia::hardware::goldfish::PipeSyncPtr m_pipe;
     zx::event m_event;
     zx::vmo m_vmo;
 #endif
diff --git a/system/OpenglSystemCommon/QemuPipeStreamFuchsia.cpp b/system/OpenglSystemCommon/QemuPipeStreamFuchsia.cpp
index 8b22719..e72d039 100644
--- a/system/OpenglSystemCommon/QemuPipeStreamFuchsia.cpp
+++ b/system/OpenglSystemCommon/QemuPipeStreamFuchsia.cpp
@@ -286,14 +286,14 @@
         }
         zx_signals_t observed = ZX_SIGNAL_NONE;
         status = m_event.wait_one(
-            fuchsia::hardware::goldfish::pipe::SIGNAL_READABLE |
-            fuchsia::hardware::goldfish::pipe::SIGNAL_HANGUP,
+            fuchsia::hardware::goldfish::SIGNAL_READABLE |
+            fuchsia::hardware::goldfish::SIGNAL_HANGUP,
             zx::time::infinite(), &observed);
         if (status != ZX_OK) {
             ALOGD("%s: wait_one failed: %d", __FUNCTION__, status);
             return nullptr;
         }
-        if (observed & fuchsia::hardware::goldfish::pipe::SIGNAL_HANGUP) {
+        if (observed & fuchsia::hardware::goldfish::SIGNAL_HANGUP) {
             ALOGD("%s: Remote end hungup", __FUNCTION__);
             return nullptr;
         }
diff --git a/system/vulkan_enc/ResourceTracker.cpp b/system/vulkan_enc/ResourceTracker.cpp
index 98bf049..5dcc579 100644
--- a/system/vulkan_enc/ResourceTracker.cpp
+++ b/system/vulkan_enc/ResourceTracker.cpp
@@ -38,7 +38,7 @@
 #ifdef VK_USE_PLATFORM_FUCHSIA
 
 #include <cutils/native_handle.h>
-#include <fuchsia/hardware/goldfish/control/cpp/fidl.h>
+#include <fuchsia/hardware/goldfish/cpp/fidl.h>
 #include <fuchsia/sysmem/cpp/fidl.h>
 #include <lib/fdio/directory.h>
 #include <lib/fdio/fd.h>
@@ -1938,7 +1938,7 @@
                     std::move(vmo_copy),
                     imageCreateInfo.extent.width,
                     imageCreateInfo.extent.height,
-                    fuchsia::hardware::goldfish::control::FormatType::BGRA,
+                    fuchsia::hardware::goldfish::ColorBufferFormatType::BGRA,
                     &status2);
                 if (status != ZX_OK || status2 != ZX_OK) {
                     ALOGE("CreateColorBuffer failed: %d:%d", status, status2);
@@ -2359,7 +2359,7 @@
                     std::move(vmo),
                     localCreateInfo.extent.width,
                     localCreateInfo.extent.height,
-                    fuchsia::hardware::goldfish::control::FormatType::BGRA,
+                    fuchsia::hardware::goldfish::ColorBufferFormatType::BGRA,
                     &status2);
                 if (status != ZX_OK || (status2 != ZX_OK && status2 != ZX_ERR_ALREADY_EXISTS)) {
                     ALOGE("CreateColorBuffer failed: %d:%d", status, status2);
@@ -3991,7 +3991,7 @@
     int mSyncDeviceFd = -1;
 
 #ifdef VK_USE_PLATFORM_FUCHSIA
-    fuchsia::hardware::goldfish::control::DeviceSyncPtr mControlDevice;
+    fuchsia::hardware::goldfish::ControlDeviceSyncPtr mControlDevice;
     fuchsia::sysmem::AllocatorSyncPtr mSysmemAllocator;
 #endif