From 199171a297a87d7696b6b8c07ee520363f4603c1 Mon Sep 17 00:00:00 2001 From: Neil Brown Date: Thu, 14 Dec 2006 17:31:00 +1100 Subject: Improve allocation and use of space for bitmaps in version1 metadata Depending on the size of the array we reserve space for up to 128K of bitmap, and we use it where possible. When hot-adding to a version 1.0 we can still only use the 3K at the end though - need a sysfs interface to improve that. If a small chunksize is requested on Create, we don't auto-enlarge the reserved space - this still needs to be fixed. --- Create.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Create.c') diff --git a/Create.c b/Create.c index e0cc797..cd4356c 100644 --- a/Create.c +++ b/Create.c @@ -435,7 +435,8 @@ int Create(struct supertype *st, char *mddev, int mdfd, fprintf(stderr, Name ": internal bitmaps not supported by this kernel.\n"); return 1; } - if (!st->ss->add_internal_bitmap(st, super, bitmap_chunk, delay, write_behind, + if (!st->ss->add_internal_bitmap(st, super, &bitmap_chunk, + delay, write_behind, bitmapsize, 1, major)) { fprintf(stderr, Name ": Given bitmap chunk size not supported.\n"); return 1; -- cgit