summaryrefslogtreecommitdiffstats
path: root/drivers/block/drbd/drbd_receiver.c
diff options
context:
space:
mode:
authorPhilipp Reisner2012-08-28 16:48:03 +0200
committerPhilipp Reisner2012-11-09 14:11:08 +0100
commit19fffd7b0303e8843aa2decfd43fa57c9d511409 (patch)
tree19ac111fafeec46eac2b0e8cee4f41f4327a1129 /drivers/block/drbd/drbd_receiver.c
parentdrbd: Fix postponed requests (diff)
downloadkernel-qcow2-linux-19fffd7b0303e8843aa2decfd43fa57c9d511409.tar.gz
kernel-qcow2-linux-19fffd7b0303e8843aa2decfd43fa57c9d511409.tar.xz
kernel-qcow2-linux-19fffd7b0303e8843aa2decfd43fa57c9d511409.zip
drbd: Call drbd_md_sync() explicitly after a state change on the connection
Without this, the meta-data gets updates after 5 seconds by the md_sync_timer. Better to do it immeditaly after a state change. If the asender detects a network failure, it may take a bit until the worker processes the according after-conn-state-change work item. The worker might be blocked in sending something, i.e. it takes until it gets into its timeout. That is 6 seconds by default which is longer than the 5 seconds of the md_sync_timer. 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 d5afa0a81fd0..fed34a7bef4a 100644
--- a/drivers/block/drbd/drbd_receiver.c
+++ b/drivers/block/drbd/drbd_receiver.c
@@ -5390,6 +5390,7 @@ int drbd_asender(struct drbd_thread *thi)
if (0) {
reconnect:
conn_request_state(tconn, NS(conn, C_NETWORK_FAILURE), CS_HARD);
+ conn_md_sync(tconn);
}
if (0) {
disconnect: