Add missing WITH_RDMACM defines
This commit is contained in:
@@ -800,7 +800,8 @@ bool osd_messenger_t::is_rdma_enabled()
|
|||||||
{
|
{
|
||||||
return rdma_contexts.size() > 0;
|
return rdma_contexts.size() > 0;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
#ifdef WITH_RDMACM
|
||||||
bool osd_messenger_t::is_use_rdmacm()
|
bool osd_messenger_t::is_use_rdmacm()
|
||||||
{
|
{
|
||||||
return use_rdmacm;
|
return use_rdmacm;
|
||||||
|
|||||||
@@ -97,6 +97,7 @@ struct osd_wanted_peer_t
|
|||||||
json11::Json raw_address_list;
|
json11::Json raw_address_list;
|
||||||
json11::Json address_list;
|
json11::Json address_list;
|
||||||
int port = 0;
|
int port = 0;
|
||||||
|
// FIXME: Remove separate WITH_RDMACM?
|
||||||
#ifdef WITH_RDMACM
|
#ifdef WITH_RDMACM
|
||||||
int rdmacm_port = 0;
|
int rdmacm_port = 0;
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -70,6 +70,7 @@ msgr_rdma_context_t::~msgr_rdma_context_t()
|
|||||||
msgr_rdma_connection_t::~msgr_rdma_connection_t()
|
msgr_rdma_connection_t::~msgr_rdma_connection_t()
|
||||||
{
|
{
|
||||||
ctx->reserve_cqe(-max_send-max_recv);
|
ctx->reserve_cqe(-max_send-max_recv);
|
||||||
|
#ifdef WITH_RDMACM
|
||||||
if (qp && !cmid)
|
if (qp && !cmid)
|
||||||
ibv_destroy_qp(qp);
|
ibv_destroy_qp(qp);
|
||||||
if (cmid)
|
if (cmid)
|
||||||
@@ -79,6 +80,10 @@ msgr_rdma_connection_t::~msgr_rdma_connection_t()
|
|||||||
rdma_destroy_qp(cmid);
|
rdma_destroy_qp(cmid);
|
||||||
rdma_destroy_id(cmid);
|
rdma_destroy_id(cmid);
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
if (qp)
|
||||||
|
ibv_destroy_qp(qp);
|
||||||
|
#endif
|
||||||
if (recv_buffers.size())
|
if (recv_buffers.size())
|
||||||
{
|
{
|
||||||
for (auto b: recv_buffers)
|
for (auto b: recv_buffers)
|
||||||
|
|||||||
Reference in New Issue
Block a user