From 65487da4b186825015a43e7b08eb501a90f86f05 Mon Sep 17 00:00:00 2001 From: Vitaliy Filippov Date: Mon, 21 Aug 2023 01:10:25 +0300 Subject: [PATCH] Do not include msgr_rdma.h into messenger.h --- src/messenger.cpp | 3 +++ src/messenger.h | 9 +++++---- src/msgr_stop.cpp | 3 +++ src/osd_secondary.cpp | 3 +++ 4 files changed, 14 insertions(+), 4 deletions(-) diff --git a/src/messenger.cpp b/src/messenger.cpp index 00ade889..d08d5e9a 100644 --- a/src/messenger.cpp +++ b/src/messenger.cpp @@ -11,6 +11,9 @@ #include "addr_util.h" #include "messenger.h" +#ifdef WITH_RDMA +#include "msgr_rdma.h" +#endif void osd_messenger_t::init() { diff --git a/src/messenger.h b/src/messenger.h index 6c455f67..e35f8c7d 100644 --- a/src/messenger.h +++ b/src/messenger.h @@ -18,10 +18,6 @@ #include "timerfd_manager.h" #include -#ifdef WITH_RDMA -#include "msgr_rdma.h" -#endif - #define CL_READ_HDR 1 #define CL_READ_DATA 2 #define CL_READ_REPLY_DATA 3 @@ -44,6 +40,11 @@ struct msgr_sendp_t int flags; }; +#ifdef WITH_RDMA +struct msgr_rdma_connection_t; +struct msgr_rdma_context_t; +#endif + struct osd_client_t { int refs = 0; diff --git a/src/msgr_stop.cpp b/src/msgr_stop.cpp index 451fbfad..a0068cc3 100644 --- a/src/msgr_stop.cpp +++ b/src/msgr_stop.cpp @@ -5,6 +5,9 @@ #include #include "messenger.h" +#ifdef WITH_RDMA +#include "msgr_rdma.h" +#endif void osd_messenger_t::cancel_osd_ops(osd_client_t *cl) { diff --git a/src/osd_secondary.cpp b/src/osd_secondary.cpp index 2984bba5..91939e04 100644 --- a/src/osd_secondary.cpp +++ b/src/osd_secondary.cpp @@ -2,6 +2,9 @@ // License: VNPL-1.1 (see README.md for details) #include "osd.h" +#ifdef WITH_RDMA +#include "msgr_rdma.h" +#endif #include "json11/json11.hpp"