@@ -2745,6 +2745,7 @@ static int kiblnd_map_tx(struct lnet_ni *ni, struct kib_tx *tx,
kiblnd_rejected(struct kib_conn *conn, int reason, void *priv, int priv_nob)
{
struct kib_peer_ni *peer_ni = conn->ibc_peer;
+ int status = -ECONNREFUSED;
LASSERT(!in_interrupt());
LASSERT(conn->ibc_state == IBLND_CONN_ACTIVE_CONNECT);
@@ -2756,6 +2757,8 @@ static int kiblnd_map_tx(struct lnet_ni *ni, struct kib_tx *tx,
break;
case IB_CM_REJ_INVALID_SERVICE_ID:
+ status = -EHOSTUNREACH;
+ peer_ni->ibp_retries++;
kiblnd_check_reconnect(conn, IBLND_MSG_VERSION, 0,
IBLND_REJECT_INVALID_SRV_ID, NULL);
CNETERR("%s rejected: no listener at %d\n",
@@ -2870,7 +2873,7 @@ static int kiblnd_map_tx(struct lnet_ni *ni, struct kib_tx *tx,
break;
}
- kiblnd_connreq_done(conn, -ECONNREFUSED);
+ kiblnd_connreq_done(conn, status);
}
static void