diff options
author | Martin Braun <martin.braun@ettus.com> | 2018-04-16 13:40:47 -0700 |
---|---|---|
committer | Martin Braun <martin.braun@ettus.com> | 2018-04-17 16:48:53 -0700 |
commit | 6fd956def44f7315c47672e961e60a37fd5d1fca (patch) | |
tree | 6653fb0a652da5eb8ee1fb8efa1dc642fdeb2771 | |
parent | c2dc6d7f9a8d67fe69cd37ec75868cf321dfa58a (diff) | |
download | uhd-6fd956def44f7315c47672e961e60a37fd5d1fca.tar.gz uhd-6fd956def44f7315c47672e961e60a37fd5d1fca.tar.bz2 uhd-6fd956def44f7315c47672e961e60a37fd5d1fca.zip |
niusrprio: Refactor niusrprio_session, move out static consts
Static const attributes were causing linker issues the way there were
being used, but they were only used in niusrprio_session.cpp and thus
could be factored out.
-rw-r--r-- | host/include/uhd/transport/nirio/niusrprio_session.h | 4 | ||||
-rw-r--r-- | host/lib/transport/nirio/niusrprio_session.cpp | 10 |
2 files changed, 7 insertions, 7 deletions
diff --git a/host/include/uhd/transport/nirio/niusrprio_session.h b/host/include/uhd/transport/nirio/niusrprio_session.h index 994d8c9d2..545b5082f 100644 --- a/host/include/uhd/transport/nirio/niusrprio_session.h +++ b/host/include/uhd/transport/nirio/niusrprio_session.h @@ -106,10 +106,6 @@ private: nirio_resource_manager _resource_manager; usrprio_rpc::usrprio_rpc_client _rpc_client; boost::recursive_mutex _session_mutex; - - static const uint32_t FPGA_READY_TIMEOUT_IN_MS = 1000; - static const uint32_t SESSION_LOCK_TIMEOUT_IN_MS = 3000; - static const uint32_t SESSION_LOCK_RETRY_INT_IN_MS = 500; }; }} diff --git a/host/lib/transport/nirio/niusrprio_session.cpp b/host/lib/transport/nirio/niusrprio_session.cpp index 2f11d31e6..0cbc31592 100644 --- a/host/lib/transport/nirio/niusrprio_session.cpp +++ b/host/lib/transport/nirio/niusrprio_session.cpp @@ -6,15 +6,19 @@ // +//@TODO: Move the register defs required by the class to a common location +#include "../../usrp/x300/x300_regs.hpp" #include <uhd/transport/nirio/niusrprio_session.h> #include <uhd/transport/nirio/nirio_fifo.h> #include <uhd/transport/nirio/status.h> #include <boost/format.hpp> #include <boost/algorithm/string.hpp> -#include <stdio.h> #include <fstream> -//@TODO: Move the register defs required by the class to a common location -#include "../../usrp/x300/x300_regs.hpp" +#include <stdio.h> + +namespace { + constexpr uint32_t FPGA_READY_TIMEOUT_IN_MS = 1000; +} namespace uhd { namespace niusrprio { |