drbd: Track the reasons to suspend IO in dedicated state bits
authorPhilipp Reisner <philipp.reisner@linbit.com>
Wed, 8 Sep 2010 21:20:21 +0000 (23:20 +0200)
committerPhilipp Reisner <philipp.reisner@linbit.com>
Thu, 14 Oct 2010 16:38:40 +0000 (18:38 +0200)
commitfb22c402ffdf61dd121795b5809de587185d5240
tree7c3de5410eff21b3a3b105dc63d5e2034f2c7c63
parent78db89287ce0f146a1f2a019a0b243ea4557caac
drbd: Track the reasons to suspend IO in dedicated state bits

There are three ways to get IO suspended:

 * Loss of any access to data
 * Fence-peer-handler running
 * User requested to suspend IO

Track those in different bits, so that one condition clearing its
state bit does not interfere with the other two conditions.

Only when the user resumes IO he overrules all three bits.

The fact is hidden from the user, he sees only a single suspend
bit.

Signed-off-by: Philipp Reisner <philipp.reisner@linbit.com>
Signed-off-by: Lars Ellenberg <lars.ellenberg@linbit.com>
drivers/block/drbd/drbd_int.h
drivers/block/drbd/drbd_main.c
drivers/block/drbd/drbd_nl.c
drivers/block/drbd/drbd_proc.c
drivers/block/drbd/drbd_receiver.c
drivers/block/drbd/drbd_req.c
include/linux/drbd.h