aboutsummaryrefslogtreecommitdiffstats
path: root/include/xen
diff options
context:
space:
mode:
authorDavid Vrabel <david.vrabel@citrix.com>2015-01-08 13:06:01 -0500
committerDavid Vrabel <david.vrabel@citrix.com>2015-01-28 09:03:12 -0500
commitff4b156f166b3931894d2a8b5cdba6cdf4da0618 (patch)
treedfb7d79d269b365b2a95efa390c0fe62a8de935e /include/xen
parent0ae65f49af64d68f0daca37b83383115cae5e690 (diff)
xen/grant-table: add helpers for allocating pages
Add gnttab_alloc_pages() and gnttab_free_pages() to allocate/free pages suitable to for granted maps. Signed-off-by: David Vrabel <david.vrabel@citrix.com> Reviewed-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Diffstat (limited to 'include/xen')
-rw-r--r--include/xen/grant_table.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/xen/grant_table.h b/include/xen/grant_table.h
index 7235d8f35459..949803e20872 100644
--- a/include/xen/grant_table.h
+++ b/include/xen/grant_table.h
@@ -163,6 +163,9 @@ void gnttab_free_auto_xlat_frames(void);
163 163
164#define gnttab_map_vaddr(map) ((void *)(map.host_virt_addr)) 164#define gnttab_map_vaddr(map) ((void *)(map.host_virt_addr))
165 165
166int gnttab_alloc_pages(int nr_pages, struct page **pages);
167void gnttab_free_pages(int nr_pages, struct page **pages);
168
166int gnttab_map_refs(struct gnttab_map_grant_ref *map_ops, 169int gnttab_map_refs(struct gnttab_map_grant_ref *map_ops,
167 struct gnttab_map_grant_ref *kmap_ops, 170 struct gnttab_map_grant_ref *kmap_ops,
168 struct page **pages, unsigned int count); 171 struct page **pages, unsigned int count);