Lines Matching +full:guest +full:- +full:side

4  * Guest OS interface to Xen.
30 #include "xen-compat.h"
33 #include "arch-x86/xen.h"
35 #include "arch-arm.h"
41 /* Guest handles for primitive C types. */
135 /* Architecture-specific hypercall definitions. */
157 /* New event-channel and physdev hypercalls introduced in 0x00030202. */
173 * Virtual interrupts that a guest OS may receive from Xen.
175 * In the side comments, 'V.' denotes a per-VCPU VIRQ while 'G.' denotes a
176 * global VIRQ. The former can be bound once per VCPU and cannot be re-bound.
177 * The latter can be allocated only once per guest: they must initially be
178 * allocated to VCPU0 but can subsequently be re-bound.
182 #define VIRQ_DEBUG 1 /* V. Request guest to dump debug info. */
195 /* Architecture-specific VIRQ definitions. */
223 * x != 0 => PFD == x - 1
225 * Sub-commands: ptr[1:0] specifies the appropriate MMU_* command.
226 * -------------
234 * ptr[:2] -- Machine address of the page-table entry to modify.
235 * val -- Value to write.
238 * pages that make up a pagetable must be mapped read-only in the guest.
239 * This prevents uncontrolled guest updates to the pagetable. Xen strictly
244 * 1). Start with top-level page (PGD or in Xen language: L4). Fill out
257 * via the HYPERVISOR_mmuext_op(MMUEXT_PIN_L4_TABLE, guest physical frame
259 * MMUEXT_NEW_BASEPTR, guest physical frame number of the PGD (L4)) can be
261 * For 32-bit guests, the L4 is not used (as there is less pagetables), so
272 * Updates an entry in the machine->pseudo-physical mapping table.
273 * ptr[:2] -- Machine address within the frame whose mapping to modify.
275 * val -- Value to write into the mapping entry.
289 * - 63 if set means No execute (NX)
290 * - 46-13 the machine frame number
291 * - 12 available for guest
292 * - 11 available for guest
293 * - 10 available for guest
294 * - 9 available for guest
295 * - 8 global
296 * - 7 PAT (PSE is disabled, must use hypercall to make 4MB or 2MB pages)
297 * - 6 dirty
298 * - 5 accessed
299 * - 4 page cached disabled
300 * - 3 page write through
301 * - 2 userspace accessible
302 * - 1 writeable
303 * - 0 present
311 * using it as the Page Attribute Table (PAT) bit - for details on it please
315 * The PAT MSR is as follows (it is a 64-bit value, each entry is 8 bits):
317 * +-----+-----+----+----+----+-----+----+----+
318 * | UC | UC- | WC | WB | UC | UC- | WC | WB | <= Linux
319 * +-----+-----+----+----+----+-----+----+----+
320 * | UC | UC- | WT | WB | UC | UC- | WT | WB | <= BIOS (default when machine boots)
321 * +-----+-----+----+----+----+-----+----+----+
322 * | rsv | rsv | WP | WC | UC | UC- | WT | WB | <= Xen
323 * +-----+-----+----+----+----+-----+----+----+
334 * that if a guest that follows Linux's PAT setup and would like to set Write
345 * PWT (so bit 3 on) --> PAT (so bit 7 is on) and clear bit 3
349 * PAT (bit 7 on) --> PWT (bit 3 on) and clear bit 7.
375 * mfn: Machine frame number of new page-table base to install in MMU.
378 * mfn: Machine frame number of new page-table base to install in MMU
408 * linear_addr: Linear address of LDT base (NB. must be page-aligned).
506 * @buffer: Pointer in the guest memory
538 * x86 guests: support writes to bottom-level PTEs.
539 * NB1. Page-directory entries cannot be written.
540 * NB2. Guest must continue to remove all writable mappings of PTEs.
549 * - virtual iopl updated from do_iret() hypercalls.
550 * - virtual iopl reported in bounce frames.
551 * - guest kernels assumed to be level 0 for the purpose of iopl checks.
557 * Enable setting the XEN_RUNSTATE_UPDATE flag in guest memory mapped
564 * This allows the guest to control respective hypervisor behavior:
565 * - when not set, L4 tables get created with the respective slot blank,
568 * - when set, L4 tables get created with the respective slot initialized
585 * DOMID_IO is used to restrict page-table updates to mapping I/O memory.
589 * aren't adjusted on the I/O-mapping code path).
601 * - HYPERVISOR_mmu_update()'s, HYPERVISOR_mmuext_op()'s, or
603 * - with XENMAPSPACE_gmfn_foreign,
654 * Event channel endpoints per domain (when using the 2-level ABI):
663 * increment of 'version'. The guest can therefore detect updates by
664 * looking for changes to 'version'. If the least-significant bit of
665 * the version number is set then an update is in progress and the guest
677 * ((((tsc - tsc_timestamp) << tsc_shift) * tsc_to_system_mul) >> 32)
697 * 'evtchn_upcall_pending' is written non-zero by Xen to indicate
699 * by the guest OS /before/ checking for pending work, thus avoiding
700 * a set-and-check race. Note that the mask is only accessed by Xen
702 * pending and mask flags can be updated by the guest without special
707 * 1. The task of 'interrupt holdoff' is covered by the per-event-
711 * 2. The main purpose of the per-VCPU mask is therefore to restrict
716 * The mask is read before making an event upcall to the guest: a
717 * non-zero mask therefore guarantees that the VCPU will not receive
719 * to block: this avoids wakeup-waiting races.
736 * `incontents 200 startofday_shared Start-of-day shared data structure
737 * Xen/kernel shared data -- pointer provided in start_info.
751 * 1. Bi-directional inter- and intra-domain connections. Domains must
752 * arrange out-of-band to set up a connection (usually by allocating
755 * 2. Physical interrupts. A domain with suitable hardware-access
756 * privileges can bind an event-channel port to a physical interrupt
758 * 3. Virtual interrupts ('events'). A domain can bind an event-channel
759 * port to a virtual interrupt source, such as the virtual-timer
764 * 1. PENDING -- notifies the domain that there is a pending notification
765 * to be processed. This bit is cleared by the guest.
766 * 2. MASK -- if this bit is clear then a 0->1 transition of PENDING
768 * updated by the guest. It is read-only within Xen. If a channel
770 * (i.e., when the channel is unmasked, the guest must manually handle
773 * To expedite scanning of pending notifications, any 0->1 pending
775 * per-vcpu selector word to be set. Each bit in the selector covers a
784 * wallclock-base value.
787 * by XEN_DOMCTL_settimeoffset, or adjusted via a guest write to the
808 * `incontents 200 startofday Start-of-day memory layout
810 * 1. The domain is started within contiguous virtual-memory region.
824 * 4. Bootstrap elements are packed together, but each is 4kB-aligned.
825 * 5. The list of page frames forms a contiguous 'pseudo-physical' memory
826 * layout for the domain. In particular, the bootstrap virtual-memory
827 * region is a 1:1 mapping to the first section of the pseudo-physical map.
828 * 6. All bootstrap elements are mapped read-writable for the guest OS. The
829 * only exception is the bootstrap page table, which is mapped read-only.
834 * Note: Prior to 25833:bb85bbccb1c9. ("x86/32-on-64 adjust Dom0 initial page
836 * to the start of the guest page tables (it was offset by two pages).
837 * This only manifested itself on 32-on-64 dom0 kernels and not 32-on-64 domU
838 * or 64-bit kernels of any colour. The page tables for a 32-on-64 dom0 got
841 * 32-bit and runs under a 64-bit hypervisor should _NOT_ use two of the
847 char magic[32]; /* "xen-<version>-<platform>". */
866 unsigned long mfn_list; /* VIRTUAL address of page-frame list. */
867 unsigned long mod_start; /* VIRTUAL address of pre-loaded module */
868 /* (PFN of pre-loaded module if */
870 unsigned long mod_len; /* Size (bytes) of pre-loaded module. */
873 /* The pfn range here covers both page table and p->m table frames. */
874 unsigned long first_p2m_pfn;/* 1st pfn forming initial P->M table. */
875 unsigned long nr_p2m_frames;/* # of pfns forming initial P->M table. */
892 /* P->M making the 3 level tree obsolete? */
893 #define SIF_PM_MASK (0xFF<<8) /* reserve 1 byte for xen-pm options */
898 * - the array of module descriptors is by convention simply at the beginning
900 * - addresses in the module descriptors are based on the beginning of the
902 * - the number of modules is determined by a termination descriptor that has
906 * file, and let the PV guest easily rebase the addresses to virtual addresses
915 /* Address of zero-terminated command line */
990 * will construct UUID 00112233-4455-6677-8899-aabbccddeeff presented as
995 * compatible with Microsoft, as they use mixed-endian encoding (some
996 * components are little-endian, some are big-endian).
1044 * c-file-style: "BSD"
1045 * c-basic-offset: 4
1046 * tab-width: 4
1047 * indent-tabs-mode: nil