[PATCH 0/3] hw/iommu: Avoid including CONFIG_DEVICES in hw/ header

Philippe Mathieu-Daudé posted 3 patches 1 month, 2 weeks ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20260225031658.32095-1-philmd@linaro.org
Maintainers: Peter Maydell <peter.maydell@linaro.org>, Eric Auger <eric.auger@redhat.com>, Paolo Bonzini <pbonzini@redhat.com>, Richard Henderson <richard.henderson@linaro.org>, Eduardo Habkost <eduardo@habkost.net>, "Michael S. Tsirkin" <mst@redhat.com>, Marcel Apfelbaum <marcel.apfelbaum@gmail.com>, Jason Wang <jasowang@redhat.com>, Yi Liu <yi.l.liu@intel.com>, "Clément Mathieu--Drif" <clement.mathieu--drif@eviden.com>, Halil Pasic <pasic@linux.ibm.com>, Christian Borntraeger <borntraeger@linux.ibm.com>, Eric Farman <farman@linux.ibm.com>, Matthew Rosato <mjrosato@linux.ibm.com>, Thomas Huth <thuth@redhat.com>, Ilya Leoshkevich <iii@linux.ibm.com>, David Hildenbrand <david@kernel.org>, Farhan Ali <alifm@linux.ibm.com>
hw/arm/smmuv3-accel.h             | 35 ------------------------
hw/i386/intel_iommu_accel.h       | 35 ++----------------------
include/hw/s390x/s390-pci-vfio.h  | 20 --------------
hw/arm/smmuv3-accel-stubs.c       | 44 +++++++++++++++++++++++++++++++
hw/i386/intel_iommu_accel-stubs.c | 37 ++++++++++++++++++++++++++
hw/s390x/s390-pci-vfio-stubs.c    | 32 ++++++++++++++++++++++
hw/arm/meson.build                |  5 ++--
hw/i386/meson.build               |  1 +
hw/s390x/meson.build              |  1 +
9 files changed, 120 insertions(+), 90 deletions(-)
create mode 100644 hw/arm/smmuv3-accel-stubs.c
create mode 100644 hw/i386/intel_iommu_accel-stubs.c
create mode 100644 hw/s390x/s390-pci-vfio-stubs.c
[PATCH 0/3] hw/iommu: Avoid including CONFIG_DEVICES in hw/ header
Posted by Philippe Mathieu-Daudé 1 month, 2 weeks ago
By inlinining the stubs we can avoid the use of target-specific
CONFIG_DEVICES include in a hw/ header, allowing to build the
source files including it as common objects.

Philippe Mathieu-Daudé (3):
  hw/arm/smmuv3: Avoid including CONFIG_DEVICES in hw/ header
  hw/i386/intel_iommu: Avoid including CONFIG_DEVICES in hw/ header
  hw/s390x/s390-pci-vfio: Avoid including CONFIG_DEVICES in hw/ header

 hw/arm/smmuv3-accel.h             | 35 ------------------------
 hw/i386/intel_iommu_accel.h       | 35 ++----------------------
 include/hw/s390x/s390-pci-vfio.h  | 20 --------------
 hw/arm/smmuv3-accel-stubs.c       | 44 +++++++++++++++++++++++++++++++
 hw/i386/intel_iommu_accel-stubs.c | 37 ++++++++++++++++++++++++++
 hw/s390x/s390-pci-vfio-stubs.c    | 32 ++++++++++++++++++++++
 hw/arm/meson.build                |  5 ++--
 hw/i386/meson.build               |  1 +
 hw/s390x/meson.build              |  1 +
 9 files changed, 120 insertions(+), 90 deletions(-)
 create mode 100644 hw/arm/smmuv3-accel-stubs.c
 create mode 100644 hw/i386/intel_iommu_accel-stubs.c
 create mode 100644 hw/s390x/s390-pci-vfio-stubs.c

-- 
2.52.0


Re: [PATCH 0/3] hw/iommu: Avoid including CONFIG_DEVICES in hw/ header
Posted by Richard Henderson 1 month, 2 weeks ago
On 2/25/26 14:16, Philippe Mathieu-Daudé wrote:
> By inlinining the stubs we can avoid the use of target-specific
> CONFIG_DEVICES include in a hw/ header, allowing to build the
> source files including it as common objects.
> 
> Philippe Mathieu-Daudé (3):
>    hw/arm/smmuv3: Avoid including CONFIG_DEVICES in hw/ header
>    hw/i386/intel_iommu: Avoid including CONFIG_DEVICES in hw/ header
>    hw/s390x/s390-pci-vfio: Avoid including CONFIG_DEVICES in hw/ header

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>

r~