[PATCHv2 2/3] zbud: add compaction callbacks

From: Vitaly Wool
Date: Sat Sep 26 2015 - 04:07:59 EST


Add no-op compaction callbacks to zbud.

Signed-off-by: Vitaly Wool <vitalywool@xxxxxxxxx>
---
mm/zbud.c | 12 ++++++++++++
1 file changed, 12 insertions(+)

diff --git a/mm/zbud.c b/mm/zbud.c
index fa48bcdf..d67c0aa 100644
--- a/mm/zbud.c
+++ b/mm/zbud.c
@@ -195,6 +195,16 @@ static void zbud_zpool_unmap(void *pool, unsigned long handle)
zbud_unmap(pool, handle);
}

+static unsigned long zbud_zpool_compact(void *pool)
+{
+ return 0;
+}
+
+static unsigned long zbud_zpool_get_compacted(void *pool)
+{
+ return 0;
+}
+
static u64 zbud_zpool_total_size(void *pool)
{
return zbud_get_pool_size(pool) * PAGE_SIZE;
@@ -210,6 +220,8 @@ static struct zpool_driver zbud_zpool_driver = {
.shrink = zbud_zpool_shrink,
.map = zbud_zpool_map,
.unmap = zbud_zpool_unmap,
+ .compact = zbud_zpool_compact,
+ .get_num_compacted = zbud_zpool_get_compacted,
.total_size = zbud_zpool_total_size,
};

--
1.9.1
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/