2 * zsmalloc memory allocator
4 * Copyright (C) 2011 Nitin Gupta
6 * This code is released using a dual license strategy: BSD/GPL
7 * You can choose the license that better fits your requirements.
9 * Released under the terms of 3-clause BSD License
10 * Released under the terms of GNU General Public License Version 2.0
16 #include <linux/types.h>
20 struct zs_pool *zs_create_pool(const char *name, gfp_t flags);
21 void zs_destroy_pool(struct zs_pool *pool);
23 void *zs_malloc(struct zs_pool *pool, size_t size);
24 void zs_free(struct zs_pool *pool, void *obj);
26 void *zs_map_object(struct zs_pool *pool, void *handle);
27 void zs_unmap_object(struct zs_pool *pool, void *handle);
29 u64 zs_get_total_size_bytes(struct zs_pool *pool);