aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/block/drbd/drbd_receiver.c
diff options
context:
space:
mode:
authorLars Ellenberg <lars.ellenberg@linbit.com>2011-01-20 04:32:05 -0500
committerPhilipp Reisner <philipp.reisner@linbit.com>2011-03-10 05:47:56 -0500
commit79a30d2d71f7be862de93228fe9b919ef664af52 (patch)
tree00f2e8a2adc5f284d50fe529eb1bae37c4eb5c2f /drivers/block/drbd/drbd_receiver.c
parent54b956abef2c1ab339fd01792e69e4a921a5e487 (diff)
drbd: queue bitmap writeout more intelligently
The "lazy writeout" of cleared bitmap pages happens during resync, and should happen again once the resync finishes cleanly, or is aborted. If resync finished cleanly, or was aborted because of peer disk failure, we trigger the writeout from worker context in the after state change work. If resync was aborted because of connection failure, we should not immediately trigger bitmap writeout, but rather postpone the writeout to after the connection cleanup happened. We now do it in the receiver context from drbd_disconnect(). If resync was aborted because of local disk failure, well, there is nothing to write to anymore. Signed-off-by: Philipp Reisner <philipp.reisner@linbit.com> Signed-off-by: Lars Ellenberg <lars.ellenberg@linbit.com>
Diffstat (limited to 'drivers/block/drbd/drbd_receiver.c')
-rw-r--r--drivers/block/drbd/drbd_receiver.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/block/drbd/drbd_receiver.c b/drivers/block/drbd/drbd_receiver.c
index 3ccc6c33a330..432fe8f6b5d2 100644
--- a/drivers/block/drbd/drbd_receiver.c
+++ b/drivers/block/drbd/drbd_receiver.c
@@ -3811,6 +3811,7 @@ static void drbd_disconnect(struct drbd_conf *mdev)
3811 3811
3812 fp = FP_DONT_CARE; 3812 fp = FP_DONT_CARE;
3813 if (get_ldev(mdev)) { 3813 if (get_ldev(mdev)) {
3814 drbd_bitmap_io(mdev, &drbd_bm_write, "write from disconnect");
3814 fp = mdev->ldev->dc.fencing; 3815 fp = mdev->ldev->dc.fencing;
3815 put_ldev(mdev); 3816 put_ldev(mdev);
3816 } 3817 }