From: Andreas Gruenbacher Date: Wed, 16 Mar 2011 00:19:27 +0000 (+0100) Subject: drbd: drbd_send_state_req(): Return 0 upon success and an error code otherwise X-Git-Tag: firefly_0821_release~3680^2~1419^2~18^2~372 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=d24ae219e96b7903c712e527cde1844bddbb1311;p=firefly-linux-kernel-4.4.55.git drbd: drbd_send_state_req(): Return 0 upon success and an error code otherwise Signed-off-by: Philipp Reisner Signed-off-by: Lars Ellenberg --- diff --git a/drivers/block/drbd/drbd_int.h b/drivers/block/drbd/drbd_int.h index 1cc8dd759f11..dacc63f2dfea 100644 --- a/drivers/block/drbd/drbd_int.h +++ b/drivers/block/drbd/drbd_int.h @@ -1955,7 +1955,7 @@ static inline int drbd_send_ping_ack(struct drbd_tconn *tconn) static inline int drbd_send_state_req(struct drbd_conf *mdev, union drbd_state mask, union drbd_state val) { - return !_conn_send_state_req(mdev->tconn, mdev->vnr, P_STATE_CHG_REQ, mask, val); + return _conn_send_state_req(mdev->tconn, mdev->vnr, P_STATE_CHG_REQ, mask, val); } static inline int conn_send_state_req(struct drbd_tconn *tconn, diff --git a/drivers/block/drbd/drbd_state.c b/drivers/block/drbd/drbd_state.c index a33dda1e7bc3..1c681110580e 100644 --- a/drivers/block/drbd/drbd_state.c +++ b/drivers/block/drbd/drbd_state.c @@ -197,7 +197,7 @@ drbd_req_state(struct drbd_conf *mdev, union drbd_state mask, goto abort; } - if (!drbd_send_state_req(mdev, mask, val)) { + if (drbd_send_state_req(mdev, mask, val)) { rv = SS_CW_FAILED_BY_PEER; if (f & CS_VERBOSE) print_st_err(mdev, os, ns, rv);