From 46b9c6278c9ce4e906d1c2ab898dff4fa82518ec Mon Sep 17 00:00:00 2001 From: Philipp Reisner Date: Thu, 4 Mar 2010 15:11:39 +0100 Subject: [PATCH 13/16] Forcing primary should also work for Consistent disks [Bugz 266] Up to now this only worked for Outdated and Inconsistent disks, that it did not worked for Consistent disks was an inconsistent omission. --- drbd/drbd_nl.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/drbd/drbd_nl.c b/drbd/drbd_nl.c index 1b2bffc..aed6643 100644 --- a/drbd/drbd_nl.c +++ b/drbd/drbd_nl.c @@ -291,8 +291,8 @@ int drbd_set_role(struct drbd_conf *mdev, enum drbd_role new_role, int force) } if (r == SS_NO_UP_TO_DATE_DISK && force && - (mdev->state.disk == D_INCONSISTENT || - mdev->state.disk == D_OUTDATED)) { + (mdev->state.disk < D_UP_TO_DATE && + mdev->state.disk >= D_INCONSISTENT)) { mask.disk = D_MASK; val.disk = D_UP_TO_DATE; forced = 1; -- 1.6.3.3