Xen Test Framework
Functions | Variables
grant_table.h File Reference

A driver for the Xen Grant Table interface. More...

#include <xtf/hypercall.h>
+ Include dependency graph for grant_table.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

int arch_map_gnttab (void)
 Map the domains grant table under gnttab_raw[]. More...
 
const char * gntst_strerror (int err)
 Convert a grant status error value to a string. More...
 
int xtf_init_grant_table (unsigned int version)
 Initialise XTF's grant infrastructure. More...
 

Variables

uint8_t gnttab_raw [PAGE_SIZE]
 Raw grant table mapping from Xen. More...
 
grant_entry_v1_t gnttab_v1 [sizeof(gnttab_raw)/sizeof(grant_entry_v1_t)]
 Grant table in v1 format (aliases gnttab_raw). More...
 
grant_entry_v2_t gnttab_v2 [sizeof(gnttab_raw)/sizeof(grant_entry_v2_t)]
 Grant table in v2 format (aliases gnttab_raw). More...
 

Detailed Description

A driver for the Xen Grant Table interface.

Definition in file grant_table.h.

Function Documentation

◆ arch_map_gnttab()

int arch_map_gnttab ( void  )

Map the domains grant table under gnttab_raw[].

Definition at line 13 of file grant_table.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ gntst_strerror()

const char* gntst_strerror ( int  err)

Convert a grant status error value to a string.

Parameters
errGNTST_*
Returns
error string, or "unknown"

Definition at line 13 of file grant_table.c.

+ Here is the caller graph for this function:

◆ xtf_init_grant_table()

int xtf_init_grant_table ( unsigned int  version)

Initialise XTF's grant infrastructure.

Sets a grant table version, and maps the grant table itself. Safe to be called multiple times to switch grant table version, as long as there are no active grants.

Definition at line 21 of file grant_table.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Variable Documentation

◆ gnttab_raw

uint8_t gnttab_raw[PAGE_SIZE]

Raw grant table mapping from Xen.

Valid once arch_map_gnttab() has returned successfully.

Definition at line 9 of file grant_table.c.

◆ gnttab_v1

grant_entry_v1_t gnttab_v1[ sizeof(gnttab_raw)/sizeof(grant_entry_v1_t)]

Grant table in v1 format (aliases gnttab_raw).

◆ gnttab_v2

grant_entry_v2_t gnttab_v2[ sizeof(gnttab_raw)/sizeof(grant_entry_v2_t)]

Grant table in v2 format (aliases gnttab_raw).