From: Philippe Mathieu-Daudé Date: Tue, 11 Mar 2025 08:57:42 +0000 (+0100) Subject: hw/vfio: Compile iommufd.c once X-Git-Tag: v10.0.0-rc0~9^2~3 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=d5c0be1a94fb3733ee04b8d5cde6641ad54ee2ea;p=thirdparty%2Fqemu.git hw/vfio: Compile iommufd.c once Removing unused "exec/ram_addr.h" header allow to compile iommufd.c once for all targets. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Pierrick Bouvier Reviewed-by: Richard Henderson Reviewed-by: Cédric Le Goater Reviewed-by: Eric Auger Message-Id: <20250308230917.18907-6-philmd@linaro.org> Link: https://lore.kernel.org/qemu-devel/20250311085743.21724-8-philmd@linaro.org Signed-off-by: Cédric Le Goater --- diff --git a/hw/vfio/iommufd.c b/hw/vfio/iommufd.c index df61edffc0..42c8412bbf 100644 --- a/hw/vfio/iommufd.c +++ b/hw/vfio/iommufd.c @@ -25,7 +25,6 @@ #include "qemu/cutils.h" #include "qemu/chardev_open.h" #include "pci.h" -#include "exec/ram_addr.h" static int iommufd_cdev_map(const VFIOContainerBase *bcontainer, hwaddr iova, ram_addr_t size, void *vaddr, bool readonly) diff --git a/hw/vfio/meson.build b/hw/vfio/meson.build index 784eae4b55..5c9ec7e897 100644 --- a/hw/vfio/meson.build +++ b/hw/vfio/meson.build @@ -4,9 +4,6 @@ vfio_ss.add(files( 'container.c', )) vfio_ss.add(when: 'CONFIG_PSERIES', if_true: files('spapr.c')) -vfio_ss.add(when: 'CONFIG_IOMMUFD', if_true: files( - 'iommufd.c', -)) vfio_ss.add(when: 'CONFIG_VFIO_PCI', if_true: files( 'display.c', 'pci-quirks.c', @@ -28,3 +25,6 @@ system_ss.add(when: 'CONFIG_VFIO', if_true: files( 'migration-multifd.c', 'cpr.c', )) +system_ss.add(when: ['CONFIG_VFIO', 'CONFIG_IOMMUFD'], if_true: files( + 'iommufd.c', +))