iPXE
Data Structures | Defines | Typedefs | Functions
grant_table.h File Reference
#include "xen.h"

Go to the source code of this file.

Data Structures

struct  grant_entry_v1
struct  gnttab_map_grant_ref
struct  gnttab_unmap_grant_ref
struct  gnttab_setup_table
struct  gnttab_dump_table
struct  gnttab_transfer
struct  gnttab_copy
struct  gnttab_query_size
struct  gnttab_unmap_and_replace

Defines

#define grant_entry_v1   grant_entry
#define grant_entry_v1_t   grant_entry_t
#define GNTTAB_NR_RESERVED_ENTRIES   8
#define GNTTAB_RESERVED_CONSOLE   0
#define GNTTAB_RESERVED_XENSTORE   1
#define GTF_invalid   (0U<<0)
#define GTF_permit_access   (1U<<0)
#define GTF_accept_transfer   (2U<<0)
#define GTF_transitive   (3U<<0)
#define GTF_type_mask   (3U<<0)
#define _GTF_readonly   (2)
#define GTF_readonly   (1U<<_GTF_readonly)
#define _GTF_reading   (3)
#define GTF_reading   (1U<<_GTF_reading)
#define _GTF_writing   (4)
#define GTF_writing   (1U<<_GTF_writing)
#define _GTF_PWT   (5)
#define GTF_PWT   (1U<<_GTF_PWT)
#define _GTF_PCD   (6)
#define GTF_PCD   (1U<<_GTF_PCD)
#define _GTF_PAT   (7)
#define GTF_PAT   (1U<<_GTF_PAT)
#define _GTF_sub_page   (8)
#define GTF_sub_page   (1U<<_GTF_sub_page)
#define _GTF_transfer_committed   (2)
#define GTF_transfer_committed   (1U<<_GTF_transfer_committed)
#define _GTF_transfer_completed   (3)
#define GTF_transfer_completed   (1U<<_GTF_transfer_completed)
#define GNTTABOP_map_grant_ref   0
#define GNTTABOP_unmap_grant_ref   1
#define GNTTABOP_setup_table   2
#define GNTTABOP_dump_table   3
#define GNTTABOP_transfer   4
#define GNTTABOP_copy   5
#define GNTTABOP_query_size   6
#define GNTTABOP_unmap_and_replace   7
#define _GNTCOPY_source_gref   (0)
#define GNTCOPY_source_gref   (1<<_GNTCOPY_source_gref)
#define _GNTCOPY_dest_gref   (1)
#define GNTCOPY_dest_gref   (1<<_GNTCOPY_dest_gref)
#define _GNTMAP_device_map   (0)
#define GNTMAP_device_map   (1<<_GNTMAP_device_map)
#define _GNTMAP_host_map   (1)
#define GNTMAP_host_map   (1<<_GNTMAP_host_map)
#define _GNTMAP_readonly   (2)
#define GNTMAP_readonly   (1<<_GNTMAP_readonly)
#define _GNTMAP_application_map   (3)
#define GNTMAP_application_map   (1<<_GNTMAP_application_map)
#define _GNTMAP_contains_pte   (4)
#define GNTMAP_contains_pte   (1<<_GNTMAP_contains_pte)
#define _GNTMAP_can_fail   (5)
#define GNTMAP_can_fail   (1<<_GNTMAP_can_fail)
#define _GNTMAP_guest_avail0   (16)
#define GNTMAP_guest_avail_mask   ((uint32_t)~0 << _GNTMAP_guest_avail0)
#define GNTST_okay   (0) /* Normal return. */
#define GNTST_general_error   (-1) /* General undefined error. */
#define GNTST_bad_domain   (-2) /* Unrecognsed domain id. */
#define GNTST_bad_gntref   (-3) /* Unrecognised or inappropriate gntref. */
#define GNTST_bad_handle   (-4) /* Unrecognised or inappropriate handle. */
#define GNTST_bad_virt_addr   (-5) /* Inappropriate virtual address to map. */
#define GNTST_bad_dev_addr   (-6) /* Inappropriate device address to unmap.*/
#define GNTST_no_device_space   (-7) /* Out of space in I/O MMU. */
#define GNTST_permission_denied   (-8) /* Not enough privilege for operation. */
#define GNTST_bad_page   (-9) /* Specified page was invalid for op. */
#define GNTST_bad_copy_arg   (-10) /* copy arguments cross page boundary. */
#define GNTST_address_too_big   (-11) /* transfer page address too large. */
#define GNTST_eagain   (-12) /* Operation not done; try again. */
#define GNTTABOP_error_msgs

Typedefs

typedef uint32_t grant_ref_t
typedef struct grant_entry_v1 grant_entry_v1_t
typedef uint32_t grant_handle_t
typedef struct gnttab_map_grant_ref gnttab_map_grant_ref_t
typedef struct
gnttab_unmap_grant_ref 
gnttab_unmap_grant_ref_t
typedef struct gnttab_setup_table gnttab_setup_table_t
typedef struct gnttab_dump_table gnttab_dump_table_t
typedef struct gnttab_transfer gnttab_transfer_t
typedef struct gnttab_copy gnttab_copy_t
typedef struct gnttab_query_size gnttab_query_size_t
typedef struct
gnttab_unmap_and_replace 
gnttab_unmap_and_replace_t

Functions

 FILE_LICENCE (MIT)
 DEFINE_XEN_GUEST_HANDLE (gnttab_map_grant_ref_t)
 DEFINE_XEN_GUEST_HANDLE (gnttab_unmap_grant_ref_t)
 DEFINE_XEN_GUEST_HANDLE (gnttab_setup_table_t)
 DEFINE_XEN_GUEST_HANDLE (gnttab_dump_table_t)
 DEFINE_XEN_GUEST_HANDLE (gnttab_transfer_t)
 DEFINE_XEN_GUEST_HANDLE (gnttab_copy_t)
 DEFINE_XEN_GUEST_HANDLE (gnttab_query_size_t)
 DEFINE_XEN_GUEST_HANDLE (gnttab_unmap_and_replace_t)

Define Documentation

#define grant_entry_v1   grant_entry

Definition at line 130 of file grant_table.h.

#define grant_entry_v1_t   grant_entry_t

Definition at line 131 of file grant_table.h.

Definition at line 149 of file grant_table.h.

Referenced by xengrant_alloc().

#define GNTTAB_RESERVED_CONSOLE   0

Definition at line 150 of file grant_table.h.

#define GNTTAB_RESERVED_XENSTORE   1

Definition at line 151 of file grant_table.h.

#define GTF_invalid   (0U<<0)

Definition at line 162 of file grant_table.h.

#define GTF_permit_access   (1U<<0)

Definition at line 163 of file grant_table.h.

#define GTF_accept_transfer   (2U<<0)

Definition at line 164 of file grant_table.h.

#define GTF_transitive   (3U<<0)

Definition at line 165 of file grant_table.h.

#define GTF_type_mask   (3U<<0)

Definition at line 166 of file grant_table.h.

Referenced by xengrant_alloc().

#define _GTF_readonly   (2)

Definition at line 178 of file grant_table.h.

#define GTF_readonly   (1U<<_GTF_readonly)

Definition at line 179 of file grant_table.h.

#define _GTF_reading   (3)

Definition at line 180 of file grant_table.h.

#define GTF_reading   (1U<<_GTF_reading)

Definition at line 181 of file grant_table.h.

#define _GTF_writing   (4)

Definition at line 182 of file grant_table.h.

#define GTF_writing   (1U<<_GTF_writing)

Definition at line 183 of file grant_table.h.

#define _GTF_PWT   (5)

Definition at line 184 of file grant_table.h.

#define GTF_PWT   (1U<<_GTF_PWT)

Definition at line 185 of file grant_table.h.

#define _GTF_PCD   (6)

Definition at line 186 of file grant_table.h.

#define GTF_PCD   (1U<<_GTF_PCD)

Definition at line 187 of file grant_table.h.

#define _GTF_PAT   (7)

Definition at line 188 of file grant_table.h.

#define GTF_PAT   (1U<<_GTF_PAT)

Definition at line 189 of file grant_table.h.

#define _GTF_sub_page   (8)

Definition at line 190 of file grant_table.h.

#define GTF_sub_page   (1U<<_GTF_sub_page)

Definition at line 191 of file grant_table.h.

#define _GTF_transfer_committed   (2)

Definition at line 203 of file grant_table.h.

#define GTF_transfer_committed   (1U<<_GTF_transfer_committed)

Definition at line 204 of file grant_table.h.

#define _GTF_transfer_completed   (3)

Definition at line 205 of file grant_table.h.

#define GTF_transfer_completed   (1U<<_GTF_transfer_completed)

Definition at line 206 of file grant_table.h.

#define GNTTABOP_map_grant_ref   0

Definition at line 301 of file grant_table.h.

#define GNTTABOP_unmap_grant_ref   1

Definition at line 302 of file grant_table.h.

#define GNTTABOP_setup_table   2

Definition at line 303 of file grant_table.h.

#define GNTTABOP_dump_table   3

Definition at line 304 of file grant_table.h.

#define GNTTABOP_transfer   4

Definition at line 305 of file grant_table.h.

#define GNTTABOP_copy   5

Definition at line 306 of file grant_table.h.

#define GNTTABOP_query_size   6

Definition at line 307 of file grant_table.h.

Definition at line 308 of file grant_table.h.

#define _GNTCOPY_source_gref   (0)

Definition at line 450 of file grant_table.h.

Definition at line 451 of file grant_table.h.

#define _GNTCOPY_dest_gref   (1)

Definition at line 452 of file grant_table.h.

Definition at line 453 of file grant_table.h.

#define _GNTMAP_device_map   (0)

Definition at line 585 of file grant_table.h.

Definition at line 586 of file grant_table.h.

#define _GNTMAP_host_map   (1)

Definition at line 588 of file grant_table.h.

#define GNTMAP_host_map   (1<<_GNTMAP_host_map)

Definition at line 589 of file grant_table.h.

#define _GNTMAP_readonly   (2)

Definition at line 591 of file grant_table.h.

#define GNTMAP_readonly   (1<<_GNTMAP_readonly)

Definition at line 592 of file grant_table.h.

#define _GNTMAP_application_map   (3)

Definition at line 598 of file grant_table.h.

Definition at line 599 of file grant_table.h.

#define _GNTMAP_contains_pte   (4)

Definition at line 606 of file grant_table.h.

Definition at line 607 of file grant_table.h.

#define _GNTMAP_can_fail   (5)

Definition at line 609 of file grant_table.h.

#define GNTMAP_can_fail   (1<<_GNTMAP_can_fail)

Definition at line 610 of file grant_table.h.

#define _GNTMAP_guest_avail0   (16)

Definition at line 616 of file grant_table.h.

Definition at line 617 of file grant_table.h.

#define GNTST_okay   (0) /* Normal return. */

Definition at line 623 of file grant_table.h.

#define GNTST_general_error   (-1) /* General undefined error. */

Definition at line 624 of file grant_table.h.

#define GNTST_bad_domain   (-2) /* Unrecognsed domain id. */

Definition at line 625 of file grant_table.h.

#define GNTST_bad_gntref   (-3) /* Unrecognised or inappropriate gntref. */

Definition at line 626 of file grant_table.h.

#define GNTST_bad_handle   (-4) /* Unrecognised or inappropriate handle. */

Definition at line 627 of file grant_table.h.

#define GNTST_bad_virt_addr   (-5) /* Inappropriate virtual address to map. */

Definition at line 628 of file grant_table.h.

#define GNTST_bad_dev_addr   (-6) /* Inappropriate device address to unmap.*/

Definition at line 629 of file grant_table.h.

#define GNTST_no_device_space   (-7) /* Out of space in I/O MMU. */

Definition at line 630 of file grant_table.h.

#define GNTST_permission_denied   (-8) /* Not enough privilege for operation. */

Definition at line 631 of file grant_table.h.

#define GNTST_bad_page   (-9) /* Specified page was invalid for op. */

Definition at line 632 of file grant_table.h.

#define GNTST_bad_copy_arg   (-10) /* copy arguments cross page boundary. */

Definition at line 633 of file grant_table.h.

#define GNTST_address_too_big   (-11) /* transfer page address too large. */

Definition at line 634 of file grant_table.h.

#define GNTST_eagain   (-12) /* Operation not done; try again. */

Definition at line 635 of file grant_table.h.

Value:
{                   \
    "okay",                                     \
    "undefined error",                          \
    "unrecognised domain id",                   \
    "invalid grant reference",                  \
    "invalid mapping handle",                   \
    "invalid virtual address",                  \
    "invalid device address",                   \
    "no spare translation slot in the I/O MMU", \
    "permission denied",                        \
    "bad page",                                 \
    "copy arguments cross page boundary",       \
    "page address size too large",              \
    "operation not done; try again"             \
}

Definition at line 638 of file grant_table.h.


Typedef Documentation

Definition at line 116 of file grant_table.h.

Definition at line 144 of file grant_table.h.

Definition at line 320 of file grant_table.h.

Definition at line 350 of file grant_table.h.

Definition at line 372 of file grant_table.h.

Definition at line 396 of file grant_table.h.

Definition at line 409 of file grant_table.h.

Definition at line 428 of file grant_table.h.

typedef struct gnttab_copy gnttab_copy_t

Definition at line 470 of file grant_table.h.

Definition at line 488 of file grant_table.h.

Definition at line 510 of file grant_table.h.


Function Documentation

FILE_LICENCE ( MIT  )