summaryrefslogtreecommitdiffstats
path: root/kernel/include/linux/zsmalloc.h
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/include/linux/zsmalloc.h')
-rw-r--r--kernel/include/linux/zsmalloc.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/kernel/include/linux/zsmalloc.h b/kernel/include/linux/zsmalloc.h
index 1338190b5..34eb16098 100644
--- a/kernel/include/linux/zsmalloc.h
+++ b/kernel/include/linux/zsmalloc.h
@@ -34,9 +34,14 @@ enum zs_mapmode {
*/
};
+struct zs_pool_stats {
+ /* How many pages were migrated (freed) */
+ unsigned long pages_compacted;
+};
+
struct zs_pool;
-struct zs_pool *zs_create_pool(char *name, gfp_t flags);
+struct zs_pool *zs_create_pool(const char *name, gfp_t flags);
void zs_destroy_pool(struct zs_pool *pool);
unsigned long zs_malloc(struct zs_pool *pool, size_t size);
@@ -49,4 +54,5 @@ void zs_unmap_object(struct zs_pool *pool, unsigned long handle);
unsigned long zs_get_total_pages(struct zs_pool *pool);
unsigned long zs_compact(struct zs_pool *pool);
+void zs_pool_stats(struct zs_pool *pool, struct zs_pool_stats *stats);
#endif