aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPhilipp Reisner <philipp.reisner@linbit.com>2010-05-10 10:03:10 -0400
committerPhilipp Reisner <philipp.reisner@linbit.com>2010-10-14 08:39:38 -0400
commit905cd7d8ac9b18e1f122b90dbebe1246b1c364fd (patch)
tree6b69cbbfc35ea954b0bd4ad1da5f541fe8aca003
parent5ba82308ea766b33404cb130a88fe4113d9c20a3 (diff)
drbd: Removed redundant error checks in the request code path
Signed-off-by: Philipp Reisner <philipp.reisner@linbit.com> Signed-off-by: Lars Ellenberg <lars.ellenberg@linbit.com>
-rw-r--r--drivers/block/drbd/drbd_req.c15
1 files changed, 0 insertions, 15 deletions
diff --git a/drivers/block/drbd/drbd_req.c b/drivers/block/drbd/drbd_req.c
index 39c2cc3614e4..48647589aa0d 100644
--- a/drivers/block/drbd/drbd_req.c
+++ b/drivers/block/drbd/drbd_req.c
@@ -984,21 +984,6 @@ static int drbd_fail_request_early(struct drbd_conf *mdev, int is_write)
984 return 1; 984 return 1;
985 } 985 }
986 986
987 /*
988 * Paranoia: we might have been primary, but sync target, or
989 * even diskless, then lost the connection.
990 * This should have been handled (panic? suspend?) somewhere
991 * else. But maybe it was not, so check again here.
992 * Caution: as long as we do not have a read/write lock on mdev,
993 * to serialize state changes, this is racy, since we may lose
994 * the connection *after* we test for the cstate.
995 */
996 if (mdev->state.disk < D_UP_TO_DATE && mdev->state.pdsk < D_UP_TO_DATE) {
997 if (__ratelimit(&drbd_ratelimit_state))
998 dev_err(DEV, "Sorry, I have no access to good data anymore.\n");
999 return 1;
1000 }
1001
1002 return 0; 987 return 0;
1003} 988}
1004 989