diff options
author | Jenny Derzhavetz <jennyf@mellanox.com> | 2016-02-24 19:23:58 +0200 |
---|---|---|
committer | Sasha Levin <sasha.levin@oracle.com> | 2016-04-18 08:50:53 -0400 |
commit | 3c6961458165c0ec909d68191bff4de7bdf50549 (patch) | |
tree | 519a6aed1e73b5673c8a434f1040b0d9f6fb0ca6 | |
parent | 78243d0a1221f06af96a8952cd5ac71cd1fe5376 (diff) | |
download | lwn-3c6961458165c0ec909d68191bff4de7bdf50549.tar.gz lwn-3c6961458165c0ec909d68191bff4de7bdf50549.zip |
iser-target: Fix identification of login rx descriptor type
[ Upstream commit b89a7c25462b164db280abc3b05d4d9d888d40e9 ]
Once connection request is accepted, one rx descriptor
is posted to receive login request. This descriptor has rx type,
but is outside the main pool of rx descriptors, and thus
was mistreated as tx type.
Signed-off-by: Jenny Derzhavetz <jennyf@mellanox.com>
Signed-off-by: Sagi Grimberg <sagig@mellanox.com>
Cc: stable@vger.kernel.org # v3.10+
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
Signed-off-by: Sasha Levin <sasha.levin@oracle.com>
-rw-r--r-- | drivers/infiniband/ulp/isert/ib_isert.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/infiniband/ulp/isert/ib_isert.c b/drivers/infiniband/ulp/isert/ib_isert.c index 353e2ab090ee..7b6973d754b4 100644 --- a/drivers/infiniband/ulp/isert/ib_isert.c +++ b/drivers/infiniband/ulp/isert/ib_isert.c @@ -2059,7 +2059,8 @@ is_isert_tx_desc(struct isert_conn *isert_conn, void *wr_id) void *start = isert_conn->rx_descs; int len = ISERT_QP_MAX_RECV_DTOS * sizeof(*isert_conn->rx_descs); - if (wr_id >= start && wr_id < start + len) + if ((wr_id >= start && wr_id < start + len) || + (wr_id == isert_conn->login_req_buf)) return false; return true; |