[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 16/29] vdpa: Skip protected ram IOMMU mappings
From: |
Michael S. Tsirkin |
Subject: |
[PULL 16/29] vdpa: Skip protected ram IOMMU mappings |
Date: |
Tue, 19 Oct 2021 07:20:25 -0400 |
From: Eugenio Pérez <eperezma@redhat.com>
Following the logic of commit 56918a126ae ("memory: Add RAM_PROTECTED
flag to skip IOMMU mappings") with VFIO, skip memory sections
inaccessible via normal mechanisms, including DMA.
Signed-off-by: Eugenio Pérez <eperezma@redhat.com>
Acked-by: Jason Wang <jasowang@redhat.com>
Message-Id: <20211014141236.923287-2-eperezma@redhat.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Reviewed-by: Stefano Garzarella <sgarzare@redhat.com>
---
hw/virtio/vhost-vdpa.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/hw/virtio/vhost-vdpa.c b/hw/virtio/vhost-vdpa.c
index 47d7a5a23d..ea1aa71ad8 100644
--- a/hw/virtio/vhost-vdpa.c
+++ b/hw/virtio/vhost-vdpa.c
@@ -28,6 +28,7 @@ static bool
vhost_vdpa_listener_skipped_section(MemoryRegionSection *section)
{
return (!memory_region_is_ram(section->mr) &&
!memory_region_is_iommu(section->mr)) ||
+ memory_region_is_protected(section->mr) ||
/* vhost-vDPA doesn't allow MMIO to be mapped */
memory_region_is_ram_device(section->mr) ||
/*
--
MST
- [PULL 09/29] tests: acpi: whitelist expected blobs for new acpi/q35/ivrs testcase, (continued)
- [PULL 09/29] tests: acpi: whitelist expected blobs for new acpi/q35/ivrs testcase, Michael S. Tsirkin, 2021/10/19
- [PULL 08/29] tests: acpi: add expected blob for DMAR table, Michael S. Tsirkin, 2021/10/19
- [PULL 13/29] tests: arm-cpu-features: use qtest_has_kvm() API, Michael S. Tsirkin, 2021/10/19
- [PULL 19/29] virtio-iommu: Remove the non transitional name, Michael S. Tsirkin, 2021/10/19
- [PULL 21/29] libvhost-user: fix VHOST_USER_REM_MEM_REG skipping mmap_addr, Michael S. Tsirkin, 2021/10/19
- [PULL 14/29] tests: migration-test: use qtest_has_accel() API, Michael S. Tsirkin, 2021/10/19
- [PULL 24/29] docs: Add documentation for vhost based RNG implementation, Michael S. Tsirkin, 2021/10/19
- [PULL 05/29] tests: acpi: update expected tables blobs, Michael S. Tsirkin, 2021/10/19
- [PULL 12/29] tests: acpi: arm/virt: drop redundant test_acpi_one() in test_acpi_virt_tcg(), Michael S. Tsirkin, 2021/10/19
- [PULL 17/29] vdpa: Add vhost_vdpa_section_end, Michael S. Tsirkin, 2021/10/19
- [PULL 16/29] vdpa: Skip protected ram IOMMU mappings,
Michael S. Tsirkin <=
- [PULL 18/29] vdpa: Check for iova range at mappings changes, Michael S. Tsirkin, 2021/10/19
- [PULL 20/29] virtio-iommu: Drop base_name and change generic_name, Michael S. Tsirkin, 2021/10/19
- [PULL 23/29] vhost-user-rng-pci: Add vhost-user-rng-pci implementation, Michael S. Tsirkin, 2021/10/19
- [PULL 22/29] vhost-user-rng: Add vhost-user-rng implementation, Michael S. Tsirkin, 2021/10/19
- [PULL 25/29] vhost-user: fix duplicated notifier MR init, Michael S. Tsirkin, 2021/10/19
- [PULL 26/29] tests/acpi/bios-tables-test: add and allow changes to a new q35 DSDT table blob, Michael S. Tsirkin, 2021/10/19
- [PULL 27/29] tests/acpi/pcihp: add unit tests for hotplug on multifunction bridges for q35, Michael S. Tsirkin, 2021/10/19
- [PULL 28/29] tests/acpi/bios-tables-test: update DSDT blob for multifunction bridge test, Michael S. Tsirkin, 2021/10/19
- [PULL 29/29] failover: fix a regression introduced by JSON'ification of -device, Michael S. Tsirkin, 2021/10/19
- [PULL 15/29] tests: bios-tables-test: use qtest_has_accel() API to register TCG only tests, Michael S. Tsirkin, 2021/10/19