From: Zhenzhong Duan <zhenzhong.duan@intel.com>
To: qemu-devel@nongnu.org, qemu-arm@nongnu.org
Cc: eric.auger@redhat.com, jean-philippe@linaro.org,
alex.williamson@redhat.com, clg@redhat.com, peterx@redhat.com,
jasowang@redhat.com, mst@redhat.com, yi.l.liu@intel.com,
chao.p.peng@intel.com, Zhenzhong Duan <zhenzhong.duan@intel.com>
Subject: [PATCH 0/3] Two minor fixes on virtio-iommu
Date: Mon, 22 Jan 2024 14:40:12 +0800 [thread overview]
Message-ID: <20240122064015.94630-1-zhenzhong.duan@intel.com> (raw)
PATCH1 fixes a potential issue with vfio devices when reboot to a
different OS which set bus number differently from previous OS.
I didn't reproduce the issue in reality, but it's still possible
in theory.
PATCH2 is a prerequisite of of PATCH3.
PATCH3 make virtio-iommu support PCI device aliases. If there are
more than one device in same IOMMU group, either due to topology,
isolation feature, etc. virtio-iommu can only make one which has
alias BDF works. This impacts both emulated and vfio devices.
I have reproduced the failure with an example config to have two
vfio devices under same pcie to pci bridge.
This patch also make a proper place in virtio-iommu to store
iova_ranges from vfio device when vfio device shares same IOMMU
group with other devices, either emulated or vfio devices.
Zhenzhong Duan (3):
virtio_iommu: Clear IOMMUPciBus pointer cache when system reset
hw/pci: Add two parameters to get_address_space
virtio-iommu: Support PCI device aliases
include/hw/pci/pci.h | 11 ++++++++---
hw/alpha/typhoon.c | 3 ++-
hw/arm/smmu-common.c | 3 ++-
hw/i386/amd_iommu.c | 6 ++++--
hw/i386/intel_iommu.c | 6 ++++--
hw/pci-host/astro.c | 3 ++-
hw/pci-host/designware.c | 3 ++-
hw/pci-host/dino.c | 3 ++-
hw/pci-host/pnv_phb3.c | 3 ++-
hw/pci-host/pnv_phb4.c | 3 ++-
hw/pci-host/ppce500.c | 3 ++-
hw/pci-host/raven.c | 3 ++-
hw/pci-host/sabre.c | 3 ++-
hw/pci/pci.c | 3 ++-
hw/ppc/ppc440_pcix.c | 3 ++-
hw/ppc/spapr_pci.c | 3 ++-
hw/remote/iommu.c | 3 ++-
hw/s390x/s390-pci-bus.c | 3 ++-
hw/virtio/virtio-iommu.c | 21 ++++++++++++---------
19 files changed, 58 insertions(+), 31 deletions(-)
--
2.34.1
next reply other threads:[~2024-01-22 6:43 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-01-22 6:40 Zhenzhong Duan [this message]
2024-01-22 6:40 ` [PATCH 1/3] virtio_iommu: Clear IOMMUPciBus pointer cache when system reset Zhenzhong Duan
2024-01-23 9:41 ` Cédric Le Goater
2024-01-23 10:03 ` Duan, Zhenzhong
2024-01-24 21:04 ` Eric Auger
2024-01-25 2:46 ` Duan, Zhenzhong
2024-01-22 6:40 ` [PATCH 2/3] hw/pci: Add two parameters to get_address_space Zhenzhong Duan
2024-01-22 6:40 ` [PATCH 3/3] virtio-iommu: Support PCI device aliases Zhenzhong Duan
2024-01-24 20:55 ` Eric Auger
2024-01-25 5:58 ` Duan, Zhenzhong
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240122064015.94630-1-zhenzhong.duan@intel.com \
--to=zhenzhong.duan@intel.com \
--cc=alex.williamson@redhat.com \
--cc=chao.p.peng@intel.com \
--cc=clg@redhat.com \
--cc=eric.auger@redhat.com \
--cc=jasowang@redhat.com \
--cc=jean-philippe@linaro.org \
--cc=mst@redhat.com \
--cc=peterx@redhat.com \
--cc=qemu-arm@nongnu.org \
--cc=qemu-devel@nongnu.org \
--cc=yi.l.liu@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).