aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/md
diff options
context:
space:
mode:
authorNeilBrown <neilb@suse.de>2005-09-09 19:23:58 -0400
committerLinus Torvalds <torvalds@g5.osdl.org>2005-09-09 19:39:13 -0400
commit53e87fbb5dc887766229eef3ba8bd8ab8853b066 (patch)
tree6fec888a271f42a9adb4c0d091219cad1f617233 /drivers/md
parent500af87abb81098da47474c81f29ea315a056dc5 (diff)
[PATCH] md: choose better default offset for bitmap.
On reflection, a better default location for hot-adding bitmaps with version-1 superblocks is immediately after the superblock. There might not be much room there, but there is usually atleast 3k, and that is a good start. Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/md')
-rw-r--r--drivers/md/md.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/md/md.c b/drivers/md/md.c
index 30e3624f3d90..fd66c3958942 100644
--- a/drivers/md/md.c
+++ b/drivers/md/md.c
@@ -957,8 +957,7 @@ static int super_1_validate(mddev_t *mddev, mdk_rdev_t *rdev)
957 mddev->events = le64_to_cpu(sb->events); 957 mddev->events = le64_to_cpu(sb->events);
958 mddev->bitmap_offset = 0; 958 mddev->bitmap_offset = 0;
959 mddev->default_bitmap_offset = 0; 959 mddev->default_bitmap_offset = 0;
960 if (mddev->minor_version == 0) 960 mddev->default_bitmap_offset = 1024;
961 mddev->default_bitmap_offset = -(64*1024)/512;
962 961
963 mddev->recovery_cp = le64_to_cpu(sb->resync_offset); 962 mddev->recovery_cp = le64_to_cpu(sb->resync_offset);
964 memcpy(mddev->uuid, sb->set_uuid, 16); 963 memcpy(mddev->uuid, sb->set_uuid, 16);