aboutsummaryrefslogtreecommitdiff
path: root/drivers/block/drbd/drbd_nl.c
diff options
context:
space:
mode:
authorPhilipp Reisner <philipp.reisner@linbit.com>2011-07-06 23:04:44 +0200
committerPhilipp Reisner <philipp.reisner@linbit.com>2012-11-08 16:57:51 +0100
commit369bea63711ae0595f6ef8c3c02bbf8a17ec608a (patch)
treec6b21e90ed8035c1d018e7be70ac26bc9d27a9e2 /drivers/block/drbd/drbd_nl.c
parentd5d7ebd42250620a6da2a8f6943c024391433488 (diff)
downloadvexpress-lsk-369bea63711ae0595f6ef8c3c02bbf8a17ec608a.tar.gz
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_nl.c')
-rw-r--r--drivers/block/drbd/drbd_nl.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/block/drbd/drbd_nl.c b/drivers/block/drbd/drbd_nl.c
index b39f5dc0f47..4e1beb7ee83 100644
--- a/drivers/block/drbd/drbd_nl.c
+++ b/drivers/block/drbd/drbd_nl.c
@@ -3061,6 +3061,8 @@ static enum drbd_ret_code adm_delete_minor(struct drbd_conf *mdev)
* we may want to delete a minor from a live replication group.
*/
mdev->state.role == R_SECONDARY) {
+ _drbd_request_state(mdev, NS(conn, C_WF_REPORT_PARAMS),
+ CS_VERBOSE + CS_WAIT_COMPLETE);
idr_remove(&mdev->tconn->volumes, mdev->vnr);
idr_remove(&minors, mdev_to_minor(mdev));
del_gendisk(mdev->vdisk);