drbd: Avoid NetworkFailure state during disconnect
authorPhilipp Reisner <philipp.reisner@linbit.com>
Fri, 17 Aug 2012 12:50:22 +0000 (14:50 +0200)
committerJens Axboe <axboe@kernel.dk>
Tue, 30 Oct 2012 07:39:17 +0000 (08:39 +0100)
commit599377acb7cf3e1bdec13285096adac7ebaaaac5
treeb331f87ebae934a923e680db8c0bdfde3db409a8
parentc12a3d8c84a5e9913a97ca5e6513c913a7e5b288
drbd: Avoid NetworkFailure state during disconnect

Disconnecting is a cluster wide state change. In case the peer node agrees
to the state transition, it sends back the fact on the meta-data connection
and closes both sockets.

In case the node node that initiated the state transfer sees the closing
action on the data-socket, before the P_STATE_CHG_REPLY packet, it was
going into one of the network failure states.

At least with the fencing option set to something else thatn "dont-care",
the unclean shutdown of the connection causes a short IO freeze or
a fence operation.

Signed-off-by: Philipp Reisner <philipp.reisner@linbit.com>
Signed-off-by: Lars Ellenberg <lars.ellenberg@linbit.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/block/drbd/drbd_int.h
drivers/block/drbd/drbd_main.c
drivers/block/drbd/drbd_receiver.c