qemu/accel
Isaku Yamahata 565f4768bb kvm/tdx: Ignore memory conversion to shared of unassigned region
TDX requires vMMIO region to be shared.  For KVM, MMIO region is the region
which kvm memslot isn't assigned to (except in-kernel emulation).
qemu has the memory region for vMMIO at each device level.

While OVMF issues MapGPA(to-shared) conservatively on 32bit PCI MMIO
region, qemu doesn't find corresponding vMMIO region because it's before
PCI device allocation and memory_region_find() finds the device region, not
PCI bus region.  It's safe to ignore MapGPA(to-shared) because when guest
accesses those region they use GPA with shared bit set for vMMIO.  Ignore
memory conversion request of non-assigned region to shared and return
success.  Otherwise OVMF is confused and panics there.

Signed-off-by: Isaku Yamahata <isaku.yamahata@intel.com>
Signed-off-by: Xiaoyao Li <xiaoyao.li@intel.com>
Message-ID: <20240229063726.610065-35-xiaoyao.li@intel.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2024-04-23 17:35:26 +02:00
..
hvf accel: Do not set CPUState::can_do_io in non-TCG accels 2024-01-19 12:28:59 +01:00
kvm kvm/tdx: Ignore memory conversion to shared of unassigned region 2024-04-23 17:35:26 +02:00
qtest meson: Replace CONFIG_SOFTMMU -> CONFIG_SYSTEM_ONLY 2023-06-20 10:01:30 +02:00
stubs RAMBlock: Add support of KVM private guest memfd 2024-04-23 17:35:25 +02:00
tcg accel/tcg: Improve can_do_io management 2024-04-09 07:45:10 -10:00
xen hw/xen: Extract 'xen_igd.h' from 'xen_pt.h' 2024-03-09 18:51:45 +01:00
accel-blocker.c system/cpus: rename qemu_mutex_lock_iothread() to bql_lock() 2024-01-08 10:45:43 -05:00
accel-system.c accel: Rename accel_init_ops_interfaces() to include 'system' 2024-01-19 12:28:59 +01:00
accel-system.h accel: Rename accel_init_ops_interfaces() to include 'system' 2024-01-19 12:28:59 +01:00
accel-target.c accel: Rename accel_init_ops_interfaces() to include 'system' 2024-01-19 12:28:59 +01:00
accel-user.c accel: extend AccelState and AccelClass to user-mode 2021-02-05 10:24:15 -10:00
dummy-cpus.c accel: Do not set CPUState::can_do_io in non-TCG accels 2024-01-19 12:28:59 +01:00
Kconfig i386: xen: fix compilation --without-default-devices 2024-02-16 13:56:09 +01:00
meson.build accel: Rename accel_softmmu* -> accel_system* 2023-10-07 19:02:57 +02:00