[PATCH] md: support write-mostly device in raid1
This allows a device in a raid1 to be marked as "write mostly". Read requests will only be sent if there is no other option. Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
committed by
Linus Torvalds
parent
36fa30636f
commit
8ddf9efe67
@@ -181,6 +181,9 @@ struct mdk_rdev_s
|
||||
int faulty; /* if faulty do not issue IO requests */
|
||||
int in_sync; /* device is a full member of the array */
|
||||
|
||||
unsigned long flags; /* Should include faulty and in_sync here. */
|
||||
#define WriteMostly 4 /* Avoid reading if at all possible */
|
||||
|
||||
int desc_nr; /* descriptor index in the superblock */
|
||||
int raid_disk; /* role of device in array */
|
||||
int saved_raid_disk; /* role that device used to have in the
|
||||
|
||||
Reference in New Issue
Block a user