diff options
author | kmacy <kmacy@FreeBSD.org> | 2008-09-25 07:01:31 +0000 |
---|---|---|
committer | kmacy <kmacy@FreeBSD.org> | 2008-09-25 07:01:31 +0000 |
commit | ba5a88198a11cf10ef7006738e2a99e94993e7d3 (patch) | |
tree | 451d5f5304549dc85c7c3b468c2df4e1b2176041 /sys/xen/interface/grant_table.h | |
parent | 7ed2245e3e156c78830bab862e09656891eea415 (diff) | |
download | FreeBSD-src-ba5a88198a11cf10ef7006738e2a99e94993e7d3.zip FreeBSD-src-ba5a88198a11cf10ef7006738e2a99e94993e7d3.tar.gz |
partial update to interface headers to 3.2
MFC after: 1 month
Diffstat (limited to 'sys/xen/interface/grant_table.h')
-rw-r--r-- | sys/xen/interface/grant_table.h | 36 |
1 files changed, 35 insertions, 1 deletions
diff --git a/sys/xen/interface/grant_table.h b/sys/xen/interface/grant_table.h index d0ba9e9..7dcba2b 100644 --- a/sys/xen/interface/grant_table.h +++ b/sys/xen/interface/grant_table.h @@ -119,6 +119,7 @@ typedef struct grant_entry grant_entry_t; * GTF_readonly: Restrict @domid to read-only mappings and accesses. [GST] * GTF_reading: Grant entry is currently mapped for reading by @domid. [XEN] * GTF_writing: Grant entry is currently mapped for writing by @domid. [XEN] + * GTF_PAT, GTF_PWT, GTF_PCD: (x86) cache attribute flags for the grant [GST] */ #define _GTF_readonly (2) #define GTF_readonly (1U<<_GTF_readonly) @@ -126,6 +127,12 @@ typedef struct grant_entry grant_entry_t; #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) /* * Subflags for GTF_accept_transfer: @@ -228,7 +235,11 @@ struct gnttab_setup_table { uint32_t nr_frames; /* OUT parameters. */ int16_t status; /* GNTST_* */ - XEN_GUEST_HANDLE(ulong) frame_list; +#ifdef __LP64__ + XEN_GUEST_HANDLE(uint64_t) frame_list; +#else + XEN_GUEST_HANDLE(uint32_t) frame_list; +#endif }; typedef struct gnttab_setup_table gnttab_setup_table_t; DEFINE_XEN_GUEST_HANDLE(gnttab_setup_table_t); @@ -328,6 +339,29 @@ struct gnttab_query_size { typedef struct gnttab_query_size gnttab_query_size_t; DEFINE_XEN_GUEST_HANDLE(gnttab_query_size_t); +/* + * GNTTABOP_unmap_and_replace: Destroy one or more grant-reference mappings + * tracked by <handle> but atomically replace the page table entry with one + * pointing to the machine address under <new_addr>. <new_addr> will be + * redirected to the null entry. + * NOTES: + * 1. The call may fail in an undefined manner if either mapping is not + * tracked by <handle>. + * 2. After executing a batch of unmaps, it is guaranteed that no stale + * mappings will remain in the device or host TLBs. + */ +#define GNTTABOP_unmap_and_replace 7 +struct gnttab_unmap_and_replace { + /* IN parameters. */ + uint64_t host_addr; + uint64_t new_addr; + grant_handle_t handle; + /* OUT parameters. */ + int16_t status; /* GNTST_* */ +}; +typedef struct gnttab_unmap_and_replace gnttab_unmap_and_replace_t; +DEFINE_XEN_GUEST_HANDLE(gnttab_unmap_and_replace_t); + /* * Bitfield values for update_pin_status.flags. |