summaryrefslogtreecommitdiffstats
path: root/drivers/infiniband
diff options
context:
space:
mode:
authorAndrew Boyer <andrew.boyer@dell.com>2016-11-23 12:39:19 -0500
committerDoug Ledford <dledford@redhat.com>2016-12-12 16:31:45 -0500
commit2a7a85487e5432424eef7a394ed26ef1d8f0d192 (patch)
tree6ed310851c7451d46d451773e1c419614dc8f2ad /drivers/infiniband
parentdd753d87436ce7ef2a958d684b38d5acc99c9f5c (diff)
downloadblackbird-obmc-linux-2a7a85487e5432424eef7a394ed26ef1d8f0d192.tar.gz
blackbird-obmc-linux-2a7a85487e5432424eef7a394ed26ef1d8f0d192.zip
IB/rxe: Don't update the response PSN unless it's going forwards
A client might post a read followed by a send. The partner receives and acknowledges both transactions, posting an RCQ entry for the send, but something goes wrong with the read ACK. When the client retries the read, the partner's responder processes the duplicate read but incorrectly resets the PSN to the value preceding the original send. When the duplicate send arrives, the responder cannot tell that it is a duplicate, so the responder generates a duplicate RCQ entry, confusing the client. Signed-off-by: Andrew Boyer <andrew.boyer@dell.com> Reviewed-by: Yonatan Cohen <yonatanc@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com>
Diffstat (limited to 'drivers/infiniband')
-rw-r--r--drivers/infiniband/sw/rxe/rxe_resp.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/infiniband/sw/rxe/rxe_resp.c b/drivers/infiniband/sw/rxe/rxe_resp.c
index dd3d88adc003..cb3fd4cb0daa 100644
--- a/drivers/infiniband/sw/rxe/rxe_resp.c
+++ b/drivers/infiniband/sw/rxe/rxe_resp.c
@@ -742,7 +742,8 @@ static enum resp_states read_reply(struct rxe_qp *qp,
} else {
qp->resp.res = NULL;
qp->resp.opcode = -1;
- qp->resp.psn = res->cur_psn;
+ if (psn_compare(res->cur_psn, qp->resp.psn) >= 0)
+ qp->resp.psn = res->cur_psn;
state = RESPST_CLEANUP;
}
OpenPOWER on IntegriCloud