summary refs log tree commit diff
path: root/devices
diff options
context:
space:
mode:
authorSteven Richman <srichman@google.com>2020-05-13 23:05:58 -0700
committerCommit Bot <commit-bot@chromium.org>2020-06-10 17:08:55 +0000
commit7c359d617f82361d03910a07ab54e17f07a54b23 (patch)
treea95a48325bfaf0e7e0578723abc011acc14b633b /devices
parent2a0ce34f31533b8e6e8c7b7ed1a55990702958ac (diff)
downloadcrosvm-7c359d617f82361d03910a07ab54e17f07a54b23.tar
crosvm-7c359d617f82361d03910a07ab54e17f07a54b23.tar.gz
crosvm-7c359d617f82361d03910a07ab54e17f07a54b23.tar.bz2
crosvm-7c359d617f82361d03910a07ab54e17f07a54b23.tar.lz
crosvm-7c359d617f82361d03910a07ab54e17f07a54b23.tar.xz
crosvm-7c359d617f82361d03910a07ab54e17f07a54b23.tar.zst
crosvm-7c359d617f82361d03910a07ab54e17f07a54b23.zip
hypervisor: add Vm user memory region functions
The separate Vm functions for MemoryMappings and MemoryMappingArenas
have been combined and now use a MappedRegion trait that the mappings
implement.  msync_memory_region replaces the get_mmap_arena function,
which is used by VmMsyncRequest.  Since Vm uses mutexes for cloning, it
can't return mem region references.

BUG=chromium:1077058
TEST=cargo test, cargo test -p sys_util, cargo test -p hypervisor

Change-Id: If257b16ee34d07820ae7ebdb9a3a598a41df013c
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosvm/+/2202845
Reviewed-by: Daniel Verkamp <dverkamp@chromium.org>
Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
Tested-by: kokoro <noreply+kokoro@google.com>
Commit-Queue: Gurchetan Singh <gurchetansingh@chromium.org>
Diffstat (limited to 'devices')
-rw-r--r--devices/src/pci/vfio_pci.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/devices/src/pci/vfio_pci.rs b/devices/src/pci/vfio_pci.rs
index 7b5c233..fa27dec 100644
--- a/devices/src/pci/vfio_pci.rs
+++ b/devices/src/pci/vfio_pci.rs
@@ -9,7 +9,7 @@ use std::u32;
 use kvm::Datamatch;
 use msg_socket::{MsgReceiver, MsgSender};
 use resources::{Alloc, MmioType, SystemAllocator};
-use sys_util::{error, EventFd, MemoryMapping};
+use sys_util::{error, EventFd, MappedRegion, MemoryMapping};
 
 use vfio_sys::*;
 use vm_control::{