mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2025-02-03 10:25:20 +00:00
61f9a4ec6c
Create two functions for registering/unregistering DMA mapping handlers, each handler being associated with a VFIO device. Whenever the plugged_size is modified (which means triggered by the virtio-mem driver in the guest), the virtio-mem backend is responsible for updating the DMA mappings related to every VFIO device through the handler previously provided. It's important to update the map when the handler is either registered or unregistered as well, as we don't want to miss some plugged memory that would have been added before the VFIO device is added to the VM. Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>