You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
qemu/include/system
Chenyi Qiang 2fde3fb916 physmem: Support coordinated discarding of RAM with guest_memfd
A new field, attributes, was introduced in RAMBlock to link to a
RamBlockAttributes object, which centralizes all guest_memfd related
information (such as fd and status bitmap) within a RAMBlock.

Create and initialize the RamBlockAttributes object upon ram_block_add().
Meanwhile, register the object in the target RAMBlock's MemoryRegion.
After that, guest_memfd-backed RAMBlock is associated with the
RamDiscardManager interface, and the users can execute RamDiscardManager
specific handling. For example, VFIO will register the
RamDiscardListener and get notifications when the state_change() helper
invokes.

As coordinate discarding of RAM with guest_memfd is now supported, only
block uncoordinated discard.

Tested-by: Alexey Kardashevskiy <aik@amd.com>
Reviewed-by: Alexey Kardashevskiy <aik@amd.com>
Acked-by: David Hildenbrand <david@redhat.com>
Signed-off-by: Chenyi Qiang <chenyi.qiang@intel.com>
Link: https://lore.kernel.org/r/20250612082747.51539-6-chenyi.qiang@intel.com
Signed-off-by: Peter Xu <peterx@redhat.com>
5 days ago
..
accel-blocker.h
accel-ops.h
address-spaces.h
arch_init.h
balloon.h
block-backend-common.h
block-backend-global-state.h
block-backend-io.h
block-backend.h
block-ram-registrar.h
blockdev.h
confidential-guest-support.h meson: Only allow CONFIG_USER_ONLY from certain source sets 2 months ago
cpu-throttle.h
cpu-timers-internal.h
cpu-timers.h include/exec: Split out icount.h 2 months ago
cpus.h
cryptodev-vhost-user.h
cryptodev-vhost.h
cryptodev.h
device_tree.h
dirtylimit.h
dirtyrate.h
dma.h
dump-arch.h
dump.h
event-loop-base.h
host_iommu_device.h vfio/iommufd: Save vendor specific device info 3 weeks ago
hostmem.h
hvf.h include/system/hvf: missing vaddr include 2 months ago
hvf_int.h accel/hvf: Fix TYPE_HVF_ACCEL instance size 3 weeks ago
hw_accel.h
iommufd.h vfio/iommufd: Add properties and handlers to TYPE_HOST_IOMMU_DEVICE_IOMMUFD 3 weeks ago
ioport.h include/system: Move exec/ioport.h to system/ioport.h 2 months ago
iothread.h
kvm.h i386/kvm: Prefault memory on page state change 3 weeks ago
kvm_int.h
kvm_xen.h
memory.h memory: Unify the definiton of ReplayRamPopulate() and ReplayRamDiscard() 5 days ago
memory_mapping.h
numa.h
nvmm.h
os-posix.h
os-wasm.h include/qemu/osdep.h: Add Emscripten-specific OS dependencies 2 months ago
os-win32.h cleanup: Drop pointless return at end of function 2 months ago
qtest.h include/system: Remove ifndef CONFIG_USER_ONLY in qtest.h 2 months ago
ram_addr.h include: Remove 'exec/exec-all.h' 2 months ago
ramblock.h physmem: Support coordinated discarding of RAM with guest_memfd 5 days ago
replay.h meson: Only allow CONFIG_USER_ONLY from certain source sets 2 months ago
reset.h
rng-random.h
rng.h
rtc.h
runstate-action.h
runstate.h system/runstate: add VM state change cb with return value 2 months ago
seccomp.h
spdm-socket.h
stats.h
system.h
tcg.h tcg: Move qemu_tcg_mttcg_enabled() to 'system/tcg.h' 2 months ago
tpm.h
tpm_backend.h
tpm_util.h
vhost-user-backend.h vhost-user: return failure if backend crash when live migration 2 months ago
watchdog.h
whpx.h
xen-mapcache.h
xen.h meson: Only allow CONFIG_USER_ONLY from certain source sets 2 months ago