mirror of
https://github.com/torvalds/linux.git
synced 2026-04-18 06:44:00 -04:00
md/r5cache: read data into orig_page for prexor of cached data
With write back cache, we use orig_page to do prexor. This patch makes sure we read data into orig_page for it. Flag R5_OrigPageUPTDODATE is added to show whether orig_page has the latest data from raid disk. We introduce a helper function uptodate_for_rmw() to simplify the a couple conditions in handle_stripe_dirtying(). Signed-off-by: Song Liu <songliubraving@fb.com> Signed-off-by: Shaohua Li <shli@fb.com>
This commit is contained in:
@@ -322,6 +322,11 @@ enum r5dev_flags {
|
||||
* data and parity being written are in the journal
|
||||
* device
|
||||
*/
|
||||
R5_OrigPageUPTDODATE, /* with write back cache, we read old data into
|
||||
* dev->orig_page for prexor. When this flag is
|
||||
* set, orig_page contains latest data in the
|
||||
* raid disk.
|
||||
*/
|
||||
};
|
||||
|
||||
/*
|
||||
|
||||
Reference in New Issue
Block a user