linux/drivers/block/drbd
Lars Ellenberg 4eb9b3cba0 drbd: don't send out P_BARRIER with stale information
We must only send P_BARRIER for epochs we actually sent P_DATA in.

If we (re-)establish a connection, we reinitialized the
send.current_epoch_nr, but forgot to reset send.current_epoch_writes.

This could result in a spurious P_BARRIER with stale epoch information,
and a disconnect/reconnect cycle once the then "unexpected"
P_BARRIER_ACK is received:
  BAD! BarrierAck #28823 received, expected #28829!

Introduce re_init_if_first_write() and maybe_send_barrier() helpers,
and call them appropriately for read/write/set-out-of-sync requests.

Signed-off-by: Philipp Reisner <philipp.reisner@linbit.com>
Signed-off-by: Lars Ellenberg <lars.ellenberg@linbit.com>
2012-11-09 14:08:19 +01:00
..
drbd_actlog.c drbd: announce FLUSH/FUA capability to upper layers 2012-11-09 14:05:44 +01:00
drbd_bitmap.c drbd: Write all pages of the bitmap after an online resize 2012-11-09 14:05:51 +01:00
drbd_int.h drbd: Avoid NetworkFailure state during disconnect 2012-11-09 14:08:18 +01:00
drbd_interval.c drbd: Iterate over all overlapping intervals in a tree 2011-10-14 16:47:37 +02:00
drbd_interval.h drbd: Iterate over all overlapping intervals in a tree 2011-10-14 16:47:37 +02:00
drbd_main.c drbd: Protect accesses to the uuid set with a spinlock 2012-11-09 14:08:04 +01:00
drbd_nl.c drbd: Protect accesses to the uuid set with a spinlock 2012-11-09 14:08:04 +01:00
drbd_nla.c drbd: Split off netlink mandatory attribute handling into separate file 2012-11-08 16:57:45 +01:00
drbd_nla.h drbd: Split off netlink mandatory attribute handling into separate file 2012-11-08 16:57:45 +01:00
drbd_proc.c drbd: introduce stop-sector to online verify 2012-11-09 14:05:32 +01:00
drbd_receiver.c drbd: properly call drbd_rs_cancel_all() in drbd_disconnected() 2012-11-09 14:08:19 +01:00
drbd_req.c drbd: Fix completion of requests while the device is suspended 2012-11-09 14:05:50 +01:00
drbd_req.h drbd: disambiguation, s/P_DISCARD_WRITE/P_SUPERSEDED/ 2012-11-09 14:05:49 +01:00
drbd_state.c drbd: Avoid NetworkFailure state during disconnect 2012-11-09 14:08:18 +01:00
drbd_state.h drbd: Improved logging of state changes 2012-11-08 16:45:06 +01:00
drbd_strings.c drbd: Allow volumes to become primary only on one side 2012-11-04 00:16:31 +01:00
drbd_vli.h Fix common misspellings 2011-03-31 11:26:23 -03:00
drbd_worker.c drbd: don't send out P_BARRIER with stale information 2012-11-09 14:08:19 +01:00
drbd_wrappers.h drbd: Split off netlink mandatory attribute handling into separate file 2012-11-08 16:57:45 +01:00
Kconfig drbd: Kconfig fix 2009-12-29 17:38:28 +01:00
Makefile drbd: Split off netlink mandatory attribute handling into separate file 2012-11-08 16:57:45 +01:00