package mirage-xen

  1. Overview
  2. Docs

Some more Xen-specific that is neither part of scheduling nor startup info, and not tied to xenstore either.

val virt_to_mfn : nativeint -> nativeint

Convert a Xen virtual addr "va" to MFN

  • This is a binding to Xen mini-os virt_to_mfn();
  • The inverse function in minios is __mfn_to_virt.
  • example use: OS.MM.virt_to_mfn (Io_page.get_addr your_io_page_t)
  • see https://xenbits.xen.org/docs/xtf/mm_8h_source.html and https://wiki.xenproject.org/wiki/XenTerminology

Grants

Allow a local xen domain to read/write memory exported ("granted") from foreign domains. Safe memory sharing is a building block of all xen inter-domain communication protocols such as those for virtual network and disk devices.

Foreign domains will explicitly "grant" us access to certain memory regions such as disk buffers. These regions are uniquely identified by the pair of (foreign domain id, integer reference) which is passed to us over some existing channel (typically via xenstore keys or via structures in previously-shared memory region).

module Gntref : sig ... end

Receiving foreign pages

module Import : sig ... end

Offering pages to foreign domains

module Export : sig ... end
val console : Gntref.t

In xen-4.2 and later, the domain builder will allocate one of the reserved grant table entries and use it to pre-authorise the console backend domain.

val xenstore : Gntref.t

In xen-4.2 and later, the domain builder will allocate one of the reserved grant table entries and use it to pre-authorise the xenstore backend domain.