summaryrefslogtreecommitdiffstats
path: root/drivers/md/raid1.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/md/raid1.h')
-rw-r--r--drivers/md/raid1.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/drivers/md/raid1.h b/drivers/md/raid1.h
index 331a98a231b4..9bebca7bff2f 100644
--- a/drivers/md/raid1.h
+++ b/drivers/md/raid1.h
@@ -41,6 +41,19 @@ struct r1conf {
41 */ 41 */
42 sector_t next_resync; 42 sector_t next_resync;
43 43
44 /* When raid1 starts resync, we divide array into four partitions
45 * |---------|--------------|---------------------|-------------|
46 * next_resync start_next_window end_window
47 * start_next_window = next_resync + NEXT_NORMALIO_DISTANCE
48 * end_window = start_next_window + NEXT_NORMALIO_DISTANCE
49 * current_window_requests means the count of normalIO between
50 * start_next_window and end_window.
51 * next_window_requests means the count of normalIO after end_window.
52 * */
53 sector_t start_next_window;
54 int current_window_requests;
55 int next_window_requests;
56
44 spinlock_t device_lock; 57 spinlock_t device_lock;
45 58
46 /* list of 'struct r1bio' that need to be processed by raid1d, 59 /* list of 'struct r1bio' that need to be processed by raid1d,
@@ -112,6 +125,7 @@ struct r1bio {
112 * in this BehindIO request 125 * in this BehindIO request
113 */ 126 */
114 sector_t sector; 127 sector_t sector;
128 sector_t start_next_window;
115 int sectors; 129 int sectors;
116 unsigned long state; 130 unsigned long state;
117 struct mddev *mddev; 131 struct mddev *mddev;