[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH-for-9.1] hw/i386: Add a config to only build the microvm mach
From: |
Michael Tokarev |
Subject: |
Re: [PATCH-for-9.1] hw/i386: Add a config to only build the microvm machine |
Date: |
Tue, 26 Mar 2024 18:48:34 +0300 |
User-agent: |
Mozilla Thunderbird |
26.03.2024 16:14, Philippe Mathieu-Daudé wrote:
Add a config file to build a binary only containing the
microvm machine, inspired by a discussion on the list:
604bf457-23a7-4d06-b59f-a7b46945c626@tls.msk.ru/">https://lore.kernel.org/qemu-devel/604bf457-23a7-4d06-b59f-a7b46945c626@tls.msk.ru/
As suggested in commit d1d5e9eefd ("configure: allow the
selection of alternate config in the build"), it can be
built using:
$ ../configure --without-default-features \
--target-list=x86_64-softmmu \
--with-devices-x86_64=microvm
Inspired-by: Michael Tokarev <mjt@tls.msk.ru>
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
---
configs/devices/x86_64-softmmu/microvm.mak | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
create mode 100644 configs/devices/x86_64-softmmu/microvm.mak
This is not enough. This step is good already, but it lacks default machine
type selection. In debian we carry a tiny patch to make microvm the default
machine type or else it crashes at startup not finding "pc" machine or one
of its required devices.
/mjt
diff --git a/configs/devices/x86_64-softmmu/microvm.mak
b/configs/devices/x86_64-softmmu/microvm.mak
new file mode 100644
index 0000000000..fe48b5b4a7
--- /dev/null
+++ b/configs/devices/x86_64-softmmu/microvm.mak
@@ -0,0 +1,20 @@
+# SPDX-FileCopyrightText: 2024 Linaro Ltd.
+#
+# Config that only supports the 64-bit microvm machine.
+# This avoids bringing in any of numerous legacy features from
+# the legacy machines or the 32bit platform.
+#
+
+CONFIG_MICROVM=y
+CONFIG_PCI_DEVICES=n
+CONFIG_SMBIOS=y
+CONFIG_SMBIOS_LEGACY=n
+CONFIG_VIRTIO_BALLOON=y
+CONFIG_VIRTIO_BLK=y
+CONFIG_VIRTIO_CRYPTO=y
+CONFIG_VIRTIO_GPU=y
+CONFIG_VIRTIO_INPUT=y
+CONFIG_VIRTIO_NET=y
+CONFIG_VIRTIO_RNG=y
+CONFIG_VIRTIO_SCSI=y
+CONFIG_VIRTIO_SERIAL=y