On 9/1/24 10:00, Srivatsa Vaddagiri wrote:
Specify the location of device-tree and its size, as Gunyah requires the
device-tree to be parsed before VM can begin its execution.
Signed-off-by: Srivatsa Vaddagiri <quic_svadd...@quicinc.com>
---
MAINTAINERS | 1 +
accel/stubs/gunyah-stub.c | 5 +++++
hw/arm/virt.c | 6 ++++++
include/sysemu/gunyah.h | 2 ++
target/arm/gunyah.c | 45 +++++++++++++++++++++++++++++++++++++++
target/arm/meson.build | 3 +++
6 files changed, 62 insertions(+)
create mode 100644 target/arm/gunyah.c
diff --git a/target/arm/gunyah.c b/target/arm/gunyah.c
new file mode 100644
index 0000000000..73c1c2a88a
--- /dev/null
+++ b/target/arm/gunyah.c
@@ -0,0 +1,45 @@
+/*
+ * QEMU Gunyah hypervisor support
+ *
+ * Copyright(c) 2023 Qualcomm Innovation Center, Inc. All Rights Reserved.
+ *
+ * SPDX-License-Identifier: GPL-2.0-or-later
+ */
+
+#include "qemu/osdep.h"
+#include "qemu/error-report.h"
+#include "sysemu/gunyah.h"
+#include "sysemu/gunyah_int.h"
+#include "linux-headers/linux/gunyah.h"
I'm getting on macOS:
In file included from ../../target/arm/gunyah.c:13:
linux-headers/linux/gunyah.h:13:10: fatal error: 'linux/types.h' file
not found
#include <linux/types.h>
^~~~~~~~~~~~~~~
1 error generated.
Maybe we need the following change?
-- >8 --
diff --git a/meson.build b/meson.build
index 6ded60063e..fb20ca04d1 100644
--- a/meson.build
+++ b/meson.build
@@ -712,5 +712,5 @@ endif
gunyah = not_found
-if get_option('gunyah').allowed()
+if get_option('gunyah').allowed() and host_os == 'linux'
accelerators += 'CONFIG_GUNYAH'
endif
---