summaryrefslogtreecommitdiffstats
path: root/include/xen/grant_table.h
diff options
context:
space:
mode:
authorAnnie Li <annie.li@oracle.com>2011-11-22 02:59:21 +0100
committerKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>2011-11-22 15:24:51 +0100
commit85ff6acb075a484780b3d763fdf41596d8fc0970 (patch)
tree30c3f1622c525036e1cefc8ade5853c0be700cb4 /include/xen/grant_table.h
parentxen/granttable: Refactor some code (diff)
downloadlinux-85ff6acb075a484780b3d763fdf41596d8fc0970.tar.xz
linux-85ff6acb075a484780b3d763fdf41596d8fc0970.zip
xen/granttable: Grant tables V2 implementation
Receiver-side copying of packets is based on this implementation, it gives better performance and better CPU accounting. It totally supports three types: full-page, sub-page and transitive grants. However this patch does not cover sub-page and transitive grants, it mainly focus on Full-page part and implements grant table V2 interfaces corresponding to what already exists in grant table V1, such as: grant table V2 initialization, mapping, releasing and exported interfaces. Each guest can only supports one type of grant table type, every entry in grant table should be the same version. It is necessary to set V1 or V2 version before initializing the grant table. Grant table exported interfaces of V2 are same with those of V1, Xen is responsible to judge what grant table version guests are using in every grant operation. V2 fulfills the same role of V1, and it is totally backwards compitable with V1. If dom0 support grant table V2, the guests runing on it can run with either V1 or V2. Acked-by: Ian Campbell <ian.campbell@citrix.com> Signed-off-by: Annie Li <annie.li@oracle.com> [v1: Modified alloc_vm_area call (new parameters), indentation, and cleanpatch warnings] Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Diffstat (limited to 'include/xen/grant_table.h')
-rw-r--r--include/xen/grant_table.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/include/xen/grant_table.h b/include/xen/grant_table.h
index c7a40f8d455a..5494c402c83a 100644
--- a/include/xen/grant_table.h
+++ b/include/xen/grant_table.h
@@ -146,8 +146,10 @@ gnttab_set_unmap_op(struct gnttab_unmap_grant_ref *unmap, phys_addr_t addr,
int arch_gnttab_map_shared(unsigned long *frames, unsigned long nr_gframes,
unsigned long max_nr_gframes,
void **__shared);
-void arch_gnttab_unmap_shared(void *shared,
- unsigned long nr_gframes);
+int arch_gnttab_map_status(uint64_t *frames, unsigned long nr_gframes,
+ unsigned long max_nr_gframes,
+ grant_status_t **__shared);
+void arch_gnttab_unmap(void *shared, unsigned long nr_gframes);
extern unsigned long xen_hvm_resume_frames;
unsigned int gnttab_max_grant_frames(void);