diff options
author | Sean Hefty <sean.hefty@intel.com> | 2012-06-14 22:49:09 +0200 |
---|---|---|
committer | Roland Dreier <roland@purestorage.com> | 2012-06-20 05:04:04 +0200 |
commit | 4dd81e895655c59bd19d7a8f03a5de1310f4aeb6 (patch) | |
tree | 9d6904827a5bf03ec9b34b5c8f5b04b05ffecc45 /drivers | |
parent | Merge tag 'rdma-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/rolan... (diff) | |
download | linux-4dd81e895655c59bd19d7a8f03a5de1310f4aeb6.tar.xz linux-4dd81e895655c59bd19d7a8f03a5de1310f4aeb6.zip |
RDMA/cma: QP type check on received REQs should be AND not OR
Change || check to the intended && when checking the QP type in a
received connection request against the listening endpoint.
Signed-off-by: Sean Hefty <sean.hefty@intel.com>
Signed-off-by: Roland Dreier <roland@purestorage.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/infiniband/core/cma.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/infiniband/core/cma.c b/drivers/infiniband/core/cma.c index 55d5642eb10a..2e826f9702c6 100644 --- a/drivers/infiniband/core/cma.c +++ b/drivers/infiniband/core/cma.c @@ -1184,7 +1184,7 @@ static void cma_set_req_event_data(struct rdma_cm_event *event, static int cma_check_req_qp_type(struct rdma_cm_id *id, struct ib_cm_event *ib_event) { - return (((ib_event->event == IB_CM_REQ_RECEIVED) || + return (((ib_event->event == IB_CM_REQ_RECEIVED) && (ib_event->param.req_rcvd.qp_type == id->qp_type)) || ((ib_event->event == IB_CM_SIDR_REQ_RECEIVED) && (id->qp_type == IB_QPT_UD)) || |