Some rdma devices don't support srq(shared receive queue).
Check hardware attribute if ceph is configured to use srq.
Signed-off-by: Changcheng Liu <changcheng.liu@aliyun.com>
ceph_assert(NetHandler(cct).set_nonblock(device->ctxt->async_fd) == 0);
support_srq = cct->_conf->ms_async_rdma_support_srq;
- if (support_srq)
+ if (support_srq) {
+ ceph_assert(device->device_attr.max_srq);
rx_queue_len = device->device_attr.max_srq_wr;
+ }
else
rx_queue_len = device->device_attr.max_qp_wr;
if (rx_queue_len > cct->_conf->ms_async_rdma_receive_queue_len) {