drbd: Fix for the connection problems on high latency links
authorPhilipp Reisner <philipp.reisner@linbit.com>
Fri, 13 May 2011 10:03:55 +0000 (12:03 +0200)
committerPhilipp Reisner <philipp.reisner@linbit.com>
Tue, 24 May 2011 08:07:22 +0000 (10:07 +0200)
It seems that the real cause of all the issues where that
we did not noticed in drbd_try_connect() when the other
guy closes one socket if the round trip time gets higher
than 100ms. There were that 100ms hard coded!

Signed-off-by: Philipp Reisner <philipp.reisner@linbit.com>
Signed-off-by: Lars Ellenberg <lars.ellenberg@linbit.com>
drivers/block/drbd/drbd_receiver.c

index 0b17d426c32b5f2b15b7f5234113dd6f4a400919..b0b0ba345e83455e495f0430e17b6c245b10704a 100644 (file)
@@ -787,7 +787,7 @@ static int drbd_connect(struct drbd_conf *mdev)
                }
 
                if (sock && msock) {
-                       schedule_timeout_interruptible(HZ / 10);
+                       schedule_timeout_interruptible(mdev->net_conf->ping_timeo*HZ/10);
                        ok = drbd_socket_okay(mdev, &sock);
                        ok = drbd_socket_okay(mdev, &msock) && ok;
                        if (ok)