drbd: fix for spurious fullsync (uuids rotated too fast)
authorLars Ellenberg <lars.ellenberg@linbit.com>
Thu, 7 Oct 2010 14:07:55 +0000 (16:07 +0200)
committerPhilipp Reisner <philipp.reisner@linbit.com>
Thu, 14 Oct 2010 16:38:48 +0000 (18:38 +0200)
commitaf85e8e83d160f72a10e4467852646ac08614260
treeb2c842d6129065bbdd787a810038752e6239b0ef
parente9ef7bb6f9696471ddddf0065afac8b435e5d051
drbd: fix for spurious fullsync (uuids rotated too fast)

If it was an "empty" resync, the SyncSource may have already "finished"
the resync and rotated the UUIDs, before noticing the connection loss
(and generating a new uuid, if Primary, rotating again), while the
SyncTarget did not change its uuids at all, or only got to the previous
sync-uuid.
This would then again lead to a full sync on next handshake
(see also Bug #251).

Fix:
Use explicit resync finished notification even for empty resyncs,
do not finish an empty resync implicitly on the SyncSource.

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