gasp_region_flags

Flags for the guest address space API

Synopsis:

#include <qvm/types.h>
enum gasp_region_flags {
    GRF_NONE = 0x00000000,
    GRF_VIRT_RD = 0x00000001,
    GRF_VIRT_WR = 0x00000002,
    GRF_VIRT_EX = 0x00000004,
    GRF_VIRT_ANY = (GRF_VIRT_RD|GRF_VIRT_WR|GRF_VIRT_EX),
    GRF_PASS_RD = 0x00000008,
    GRF_PASS_WR = 0x00000010,
    GRF_PASS_EX = 0x00000020,
    GRF_PASS_ANY = (GRF_PASS_RD|GRF_PASS_WR|GRF_PASS_EX),
    GRF_NOCACHE = 0x00000040,
    GRF_ACTIVE = 0x00000080,
    GRF_MEMORY = 0x00000100,
    GRF_PASSTHRU = 0x00000200,
    GRF_DMA_USES = 0x00000400,
    GRF_DMA_NO_USE = 0x00000800,
    GRF_DMA_SOURCE = 0x00001000,
    GRF_DMA_TARGET = 0x00002000,
    GRF_PRECIOUS = 0x00004000,
    GRF_NOPERMS = 0x00008000,
    GRF_BACKUP_MASK = 0xf0000000,
    GRF_BACKUP_SHIFT = (28-3),
    GRF_STICKY = (GRF_MEMORY|GRF_DMA_SOURCE|GRF_DMA_TARGET|GRF_PASSTHRU)
};

Data:

GRF_NONE

No flags specified.

GRF_VIRT_RD

A read access causes the guest to exit and invokes the vread callback.

GRF_VIRT_WR

A write access causes the guestto exit and invokes the vwrite callback.

GRF_VIRT_EX

An execute access causes the guest to exit and triggers an action specified by the VM unsupported configuration option.

GRF_VIRT_ANY

A convenient alias for the first three bits.

GRF_PASS_RD

A read access is allowed through with no guest exit.

GRF_PASS_WR

A write access is allowed through with no guest exit.

GRF_PASS_EX

An execute access is allowed through with no guest exit.

GRF_PASS_ANY

A convenient alias for the second three bits.

GRF_NOCACHE

Pass-through mappings should be marked as uncachable.

GRF_ACTIVE

Indicate that the region is installed.

GRF_MEMORY

The region is available as normal system RAM.

GRF_PASSTHRU

The item was specified with a pass option in the VM configuration; for internal use only.

GRF_DMA_USES

The item uses DMA; for internal use only.

GRF_DMA_NO_USE

The item doesn't use DMA; for internal use only.

GRF_DMA_SOURCE

The item can be a DMA source; for internal use only.

GRF_DMA_TARGET

The item can be a DMA target; for internal use only.

GRF_PRECIOUS

The region can't overlap another region; for internal use only.

GRF_NOPERMS

The region is reserved, but the pages have no permissions.

GRF_BACKUP_MASK

Mask for saved bits.

GRF_BACKUP_SHIFT

Shift for saved bits (saved bits are PASS_* and NOCACHE).

GRF_STICKY

Flags that should be preserved.

Library:

Provided by qvm; no external library is required.

Description:

These flags are used in the gasp_region structure.