diff options
author | Philipp Reisner <philipp.reisner@linbit.com> | 2011-07-06 21:04:44 (GMT) |
---|---|---|
committer | Philipp Reisner <philipp.reisner@linbit.com> | 2012-11-08 15:57:51 (GMT) |
commit | 369bea63711ae0595f6ef8c3c02bbf8a17ec608a (patch) | |
tree | c6b21e90ed8035c1d018e7be70ac26bc9d27a9e2 /drivers/block/drbd/drbd_state.c | |
parent | d5d7ebd42250620a6da2a8f6943c024391433488 (diff) | |
download | linux-fsl-qoriq-369bea63711ae0595f6ef8c3c02bbf8a17ec608a.tar.xz |
drbd: Fixed removal of volumes/devices from connected resources
When removing a volume/device we need to switch the connection
status of the peer back into WFReportParams.
Before this fix it was left in Connected state. That means that
the peer device continued to inform us about state changes, etc...
But we deleted that minor -> protocol error.
Signed-off-by: Philipp Reisner <philipp.reisner@linbit.com>
Signed-off-by: Lars Ellenberg <lars.ellenberg@linbit.com>
Diffstat (limited to 'drivers/block/drbd/drbd_state.c')
-rw-r--r-- | drivers/block/drbd/drbd_state.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/block/drbd/drbd_state.c b/drivers/block/drbd/drbd_state.c index c4d0d96..633b52c 100644 --- a/drivers/block/drbd/drbd_state.c +++ b/drivers/block/drbd/drbd_state.c @@ -201,7 +201,8 @@ static int cl_wide_st_chg(struct drbd_conf *mdev, (os.conn != C_STARTING_SYNC_S && ns.conn == C_STARTING_SYNC_S) || (os.disk != D_DISKLESS && ns.disk == D_DISKLESS))) || (os.conn >= C_CONNECTED && ns.conn == C_DISCONNECTING) || - (os.conn == C_CONNECTED && ns.conn == C_VERIFY_S); + (os.conn == C_CONNECTED && ns.conn == C_VERIFY_S) || + (os.conn == C_CONNECTED && ns.conn == C_WF_REPORT_PARAMS); } static union drbd_state @@ -1202,7 +1203,8 @@ static void after_state_ch(struct drbd_conf *mdev, union drbd_state os, } /* Do not change the order of the if above and the two below... */ - if (os.pdsk == D_DISKLESS && ns.pdsk > D_DISKLESS) { /* attach on the peer */ + if (os.pdsk == D_DISKLESS && + ns.pdsk > D_DISKLESS && ns.pdsk != D_UNKNOWN) { /* attach on the peer */ drbd_send_uuids(mdev); drbd_send_state(mdev); } |