OSDN Git Service

dm raid: add raid4/5/6 journal write-back support via journal_mode option
authorHeinz Mauelshagen <heinzm@redhat.com>
Wed, 22 Mar 2017 16:44:38 +0000 (17:44 +0100)
committerMike Snitzer <snitzer@redhat.com>
Mon, 27 Mar 2017 16:08:07 +0000 (12:08 -0400)
commit6e53636fe81465d6810f4e0910e7238edf12a133
tree38be83f8fc4476c3fb4debce0b8135ed07854c1c
parent4464e36e06470e3d68dc26a874f0dbdffa09a6e8
dm raid: add raid4/5/6 journal write-back support via journal_mode option

Commit 63c32ed4afc ("dm raid: add raid4/5/6 journaling support") added
journal support to close the raid4/5/6 "write hole" -- in terms of
writethrough caching.

Introduce a "journal_mode" feature and use the new
r5c_journal_mode_set() API to add support for switching the journal
device's cache mode between write-through (the current default) and
write-back.

NOTE: If the journal device is not layered on resilent storage and it
fails, write-through mode will cause the "write hole" to reoccur.  But
if the journal fails while in write-back mode it will cause data loss
for any dirty cache entries unless resilent storage is used for the
journal.

Signed-off-by: Heinz Mauelshagen <heinzm@redhat.com>
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Documentation/device-mapper/dm-raid.txt
drivers/md/dm-raid.c