drbd: Finish requests that completed while IO was frozen
authorPhilipp Reisner <philipp.reisner@linbit.com>
Tue, 7 Aug 2012 11:28:00 +0000 (13:28 +0200)
committerPhilipp Reisner <philipp.reisner@linbit.com>
Fri, 9 Nov 2012 13:05:47 +0000 (14:05 +0100)
commit8a0bab2a6dd05ee35777370be892daba01750712
treeb3111de93bd73df69ee330551c5f55636ae0c0e9
parente959d08d3ef6e48bc3b726bcc07a4ebb9989be94
drbd: Finish requests that completed while IO was frozen

Requests of an acked epoch are stored on the barrier_acked_requests list. In
case the private bio of such a request completes while IO on the drbd device
is suspended [req_mod(completed_ok)] then the request stays there.

When thawing IO because the fence_peer handler returned, then we use
tl_clear() to apply the connection_lost_while_pending event to all requests
on the transfer-log and the barrier_acked_requests list.

Up to now the connection_lost_while_pending event was not applied
on requests on the barrier_acked_requests list. Fixed that.

I.e. now the connection_lost_while_pending and resend events are
applied to requests on the barrier_acked_requests list. For that
it is necessary that the resend event finishes (local only)
READS correctly.

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