aboutsummaryrefslogtreecommitdiff
path: root/hw/rdma/rdma_backend.h
diff options
context:
space:
mode:
authorYuval Shaia <yuval.shaia@oracle.com>2018-12-21 16:40:17 +0200
committerMarcel Apfelbaum <marcel.apfelbaum@gmail.com>2018-12-22 11:09:56 +0200
commit46462cb1618e0a1e0a14e13bc08ffd02bc5f773e (patch)
tree1074d80609e58d5597438a9e8eab66a9a8fef0ff /hw/rdma/rdma_backend.h
parent4082e533f640426a91d1a08c3aeb6824cd65e28a (diff)
hw/rdma: Return qpn 1 if ibqp is NULL
Device is not supporting QP0, only QP1. Signed-off-by: Yuval Shaia <yuval.shaia@oracle.com> Reviewed-by: Marcel Apfelbaum <marcel.apfelbaum@gmail.com> Signed-off-by: Marcel Apfelbaum <marcel.apfelbaum@gmail.com>
Diffstat (limited to 'hw/rdma/rdma_backend.h')
-rw-r--r--hw/rdma/rdma_backend.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/rdma/rdma_backend.h b/hw/rdma/rdma_backend.h
index 86e8fe8ab6..3ccc9a2494 100644
--- a/hw/rdma/rdma_backend.h
+++ b/hw/rdma/rdma_backend.h
@@ -33,7 +33,7 @@ static inline union ibv_gid *rdma_backend_gid(RdmaBackendDev *dev)
static inline uint32_t rdma_backend_qpn(const RdmaBackendQP *qp)
{
- return qp->ibqp ? qp->ibqp->qp_num : 0;
+ return qp->ibqp ? qp->ibqp->qp_num : 1;
}
static inline uint32_t rdma_backend_mr_lkey(const RdmaBackendMR *mr)