diff options
author | NeilBrown <neilb@cse.unsw.edu.au> | 2005-06-21 20:17:28 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@ppc970.osdl.org> | 2005-06-21 22:07:47 -0400 |
commit | 7bfa19f2748000d646dbdf8f48258cfe1d257b52 (patch) | |
tree | 2f7e6b0a0cba4ac01d7809224023a7dc73b94840 /include/linux/raid/md_k.h | |
parent | a654b9d8f851f4ca02649d5825cbe6c608adb10c (diff) |
[PATCH] md: allow md to update multiple superblocks in parallel.
currently, md updates all superblocks (one on each device) in series. It
waits for one write to complete before starting the next. This isn't a big
problem as superblock updates don't happen that often.
However it is neater to do it in parallel, and if the drives in the array have
gone to "sleep" after a period of idleness, then waking them is parallel is
faster (and someone else should be worrying about power drain).
Futher, we will need parallel superblock updates for a future patch which
keeps the intent-logging bitmap near the superblock.
Also remove the silly code that retired superblock updates 100 times. This
simply never made sense.
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>
Diffstat (limited to 'include/linux/raid/md_k.h')
-rw-r--r-- | include/linux/raid/md_k.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/raid/md_k.h b/include/linux/raid/md_k.h index a3725b57fb7d..8c14ba565a45 100644 --- a/include/linux/raid/md_k.h +++ b/include/linux/raid/md_k.h | |||
@@ -262,6 +262,7 @@ struct mddev_s | |||
262 | 262 | ||
263 | spinlock_t write_lock; | 263 | spinlock_t write_lock; |
264 | wait_queue_head_t sb_wait; /* for waiting on superblock updates */ | 264 | wait_queue_head_t sb_wait; /* for waiting on superblock updates */ |
265 | atomic_t pending_writes; /* number of active superblock writes */ | ||
265 | 266 | ||
266 | unsigned int safemode; /* if set, update "clean" superblock | 267 | unsigned int safemode; /* if set, update "clean" superblock |
267 | * when no writes pending. | 268 | * when no writes pending. |