All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] dm-raid: avoid bitmap with raid4/5/6 journal device
@ 2018-10-12 18:24 Heinz Mauelshagen
  0 siblings, 0 replies; only message in thread
From: Heinz Mauelshagen @ 2018-10-12 18:24 UTC (permalink / raw)
  To: heinzm, dm-devel; +Cc: snitzer

With raid4/5/6, journal device and write intent bitmap are mutually exclusive.

Signed-off-by: Heinz Mauelshagen <heinzm@redhat.com>
---
 drivers/md/dm-raid.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/md/dm-raid.c b/drivers/md/dm-raid.c
index c44925e4e481..e1dd1622a290 100644
--- a/drivers/md/dm-raid.c
+++ b/drivers/md/dm-raid.c
@@ -2475,7 +2475,7 @@ static int super_validate(struct raid_set *rs, struct md_rdev *rdev)
 	}
 
 	/* Enable bitmap creation for RAID levels != 0 */
-	mddev->bitmap_info.offset = rt_is_raid0(rs->raid_type) ? 0 : to_sector(4096);
+	mddev->bitmap_info.offset = (rt_is_raid0(rs->raid_type) || rs->journal_dev.dev) ? 0 : to_sector(4096);
 	mddev->bitmap_info.default_offset = mddev->bitmap_info.offset;
 
 	if (!test_and_clear_bit(FirstUse, &rdev->flags)) {
-- 
2.17.2

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2018-10-12 18:24 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-10-12 18:24 [PATCH] dm-raid: avoid bitmap with raid4/5/6 journal device Heinz Mauelshagen

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.