diff options
author | NeilBrown <neilb@suse.de> | 2012-07-31 03:08:14 -0400 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2012-07-31 03:08:14 -0400 |
commit | 0021b7bc045e4b0b85d8c53614342aaf84ca96a5 (patch) | |
tree | 1432761eec4c49bbacea55df083e73599e18ea1c /drivers/md/raid5.c | |
parent | 01ff5dbc0925d11c8ad76eed3bdd02d0c7e1e0f5 (diff) |
md: remove plug_cnt feature of plugging.
This seemed like a good idea at the time, but after further thought I
cannot see it making a difference other than very occasionally and
testing to try to exercise the case it is most likely to help did not
show any performance difference by removing it.
So remove the counting of active plugs and allow 'pending writes' to
be activated at any time, not just when no plugs are active.
This is only relevant when there is a write-intent bitmap, and the
updating of the bitmap will likely introduce enough delay that
the single-threading of bitmap updates will be enough to collect large
numbers of updates together.
Removing this will make it easier to centralise the unplug code, and
will clear the other for other unplug enhancements which have a
measurable effect.
Signed-off-by: NeilBrown <neilb@suse.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'drivers/md/raid5.c')
-rw-r--r-- | drivers/md/raid5.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/md/raid5.c b/drivers/md/raid5.c index 04348d76bb30..bde9da2baa39 100644 --- a/drivers/md/raid5.c +++ b/drivers/md/raid5.c | |||
@@ -4543,7 +4543,7 @@ static void raid5d(struct mddev *mddev) | |||
4543 | while (1) { | 4543 | while (1) { |
4544 | struct bio *bio; | 4544 | struct bio *bio; |
4545 | 4545 | ||
4546 | if (atomic_read(&mddev->plug_cnt) == 0 && | 4546 | if ( |
4547 | !list_empty(&conf->bitmap_list)) { | 4547 | !list_empty(&conf->bitmap_list)) { |
4548 | /* Now is a good time to flush some bitmap updates */ | 4548 | /* Now is a good time to flush some bitmap updates */ |
4549 | conf->seq_flush++; | 4549 | conf->seq_flush++; |
@@ -4553,8 +4553,7 @@ static void raid5d(struct mddev *mddev) | |||
4553 | conf->seq_write = conf->seq_flush; | 4553 | conf->seq_write = conf->seq_flush; |
4554 | activate_bit_delay(conf); | 4554 | activate_bit_delay(conf); |
4555 | } | 4555 | } |
4556 | if (atomic_read(&mddev->plug_cnt) == 0) | 4556 | raid5_activate_delayed(conf); |
4557 | raid5_activate_delayed(conf); | ||
4558 | 4557 | ||
4559 | while ((bio = remove_bio_from_retry(conf))) { | 4558 | while ((bio = remove_bio_from_retry(conf))) { |
4560 | int ok; | 4559 | int ok; |