diff options
Diffstat (limited to 'include/linux/zbud.h')
-rw-r--r-- | include/linux/zbud.h | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/include/linux/zbud.h b/include/linux/zbud.h new file mode 100644 index 000000000000..2571a5cfa5fc --- /dev/null +++ b/include/linux/zbud.h | |||
@@ -0,0 +1,22 @@ | |||
1 | #ifndef _ZBUD_H_ | ||
2 | #define _ZBUD_H_ | ||
3 | |||
4 | #include <linux/types.h> | ||
5 | |||
6 | struct zbud_pool; | ||
7 | |||
8 | struct zbud_ops { | ||
9 | int (*evict)(struct zbud_pool *pool, unsigned long handle); | ||
10 | }; | ||
11 | |||
12 | struct zbud_pool *zbud_create_pool(gfp_t gfp, struct zbud_ops *ops); | ||
13 | void zbud_destroy_pool(struct zbud_pool *pool); | ||
14 | int zbud_alloc(struct zbud_pool *pool, int size, gfp_t gfp, | ||
15 | unsigned long *handle); | ||
16 | void zbud_free(struct zbud_pool *pool, unsigned long handle); | ||
17 | int zbud_reclaim_page(struct zbud_pool *pool, unsigned int retries); | ||
18 | void *zbud_map(struct zbud_pool *pool, unsigned long handle); | ||
19 | void zbud_unmap(struct zbud_pool *pool, unsigned long handle); | ||
20 | u64 zbud_get_pool_size(struct zbud_pool *pool); | ||
21 | |||
22 | #endif /* _ZBUD_H_ */ | ||