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>
This commit is contained in:
parent
4082e533f6
commit
46462cb161
|
@ -33,7 +33,7 @@ static inline union ibv_gid *rdma_backend_gid(RdmaBackendDev *dev)
|
||||||
|
|
||||||
static inline uint32_t rdma_backend_qpn(const RdmaBackendQP *qp)
|
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)
|
static inline uint32_t rdma_backend_mr_lkey(const RdmaBackendMR *mr)
|
||||||
|
|
Loading…
Reference in a new issue