summaryrefslogtreecommitdiff
path: root/hw
diff options
context:
space:
mode:
authorEric Auger <eric.auger@redhat.com>2018-05-04 18:05:52 +0100
committerPeter Maydell <peter.maydell@linaro.org>2018-05-04 18:52:58 +0100
commit0d1ac82eced6bb641a98cd5d7f3b829635f95fac (patch)
tree424768178ff1d4ce7c88d33ed1bd5a4a0b7529d9 /hw
parent9bde7f0674fe0354ab58ccf25fdfd9f2f68f2b5c (diff)
downloadqemu-0d1ac82eced6bb641a98cd5d7f3b829635f95fac.tar.gz
hw/arm/smmuv3: Abort on vfio or vhost case
At the moment, the SMMUv3 does not support notification on TLB invalidation. So let's log an error as soon as such notifier gets enabled. Signed-off-by: Eric Auger <eric.auger@redhat.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Message-id: 1524665762-31355-11-git-send-email-eric.auger@redhat.com Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'hw')
-rw-r--r--hw/arm/smmuv3.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/hw/arm/smmuv3.c b/hw/arm/smmuv3.c
index d896834764..b3026dea20 100644
--- a/hw/arm/smmuv3.c
+++ b/hw/arm/smmuv3.c
@@ -1147,12 +1147,23 @@ static void smmuv3_class_init(ObjectClass *klass, void *data)
dc->realize = smmu_realize;
}
+static void smmuv3_notify_flag_changed(IOMMUMemoryRegion *iommu,
+ IOMMUNotifierFlag old,
+ IOMMUNotifierFlag new)
+{
+ if (old == IOMMU_NOTIFIER_NONE) {
+ warn_report("SMMUV3 does not support vhost/vfio integration yet: "
+ "devices of those types will not function properly");
+ }
+}
+
static void smmuv3_iommu_memory_region_class_init(ObjectClass *klass,
void *data)
{
IOMMUMemoryRegionClass *imrc = IOMMU_MEMORY_REGION_CLASS(klass);
imrc->translate = smmuv3_translate;
+ imrc->notify_flag_changed = smmuv3_notify_flag_changed;
}
static const TypeInfo smmuv3_type_info = {