bhyve and mmap(2)

Peter Grehan grehan at
Tue Feb 27 06:57:17 UTC 2018

Hi Fabian,

> Would be possible to use mmap(2) around libvmmapi to map a file
> (MAP_PRIVATE) and or shared memory segments (MAP_SHARED) into guest
> physical address space?

  It currently isn't - doing that will just insert the mappings into the 
user process's view, and not into guest address space.

  Bhyve currently uses a separate vmspace for guest address space. While 
this simplifies the EPT code internally, it also prevents direct 
manipulation of the address space using standard system calls.

  A possible solution to this would be to have the ability to apply 
address-space manipulation calls to an arbitrary address space - this 
was brought up in Linux a long while back:



More information about the freebsd-virtualization mailing list