diff options
author | Aaron Rossetto <aaron.rossetto@ni.com> | 2019-10-17 08:44:11 -0500 |
---|---|---|
committer | Martin Braun <martin.braun@ettus.com> | 2019-11-26 12:21:32 -0800 |
commit | 0bd233e64210c6605e8a6ec1424fa81f9ea8a681 (patch) | |
tree | f97729a7bba21cdfc45ee756bee1ac0489358544 /host/lib/usrp/mpmd/mpmd_mb_iface.hpp | |
parent | 912ed28b3df13b9f9c33f2fa92867ec0ac7445fd (diff) | |
download | uhd-0bd233e64210c6605e8a6ec1424fa81f9ea8a681.tar.gz uhd-0bd233e64210c6605e8a6ec1424fa81f9ea8a681.tar.bz2 uhd-0bd233e64210c6605e8a6ec1424fa81f9ea8a681.zip |
uhd: Introduce I/O service manager
- Implement I/O service detach link methods
- The I/O service manager instantiates new I/O services or connects
links to existing I/O services based on options provided by the user
in stream_args.
- Add a streamer ID parameter to methods to create transports so that
the I/O service manager can group transports appropriately when using
offload threads.
- Change X300 and MPMD to use I/O service manager to connect links to
I/O services.
- There is now a single I/O service manager per rfnoc_graph (and it is
also stored in the graph)
- The I/O service manager now also knows the device args for the
rfnoc_graph it was created with, and can make decisions based upon
those (e.g, use a specific I/O service for DPDK, share cores between
streamers, etc.)
- The I/O Service Manager does not get any decision logic with this
commit, though
- The MB ifaces for mpmd and x300 now access this global I/O service
manager
- Add configuration of link parameters with overrides
Co-Authored-By: Martin Braun <martin.braun@ettus.com>
Co-Authored-By: Aaron Rossetto <aaron.rossetto@ni.com>
Diffstat (limited to 'host/lib/usrp/mpmd/mpmd_mb_iface.hpp')
-rw-r--r-- | host/lib/usrp/mpmd/mpmd_mb_iface.hpp | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/host/lib/usrp/mpmd/mpmd_mb_iface.hpp b/host/lib/usrp/mpmd/mpmd_mb_iface.hpp index 4e47dd35a..4e54cfc12 100644 --- a/host/lib/usrp/mpmd/mpmd_mb_iface.hpp +++ b/host/lib/usrp/mpmd/mpmd_mb_iface.hpp @@ -10,8 +10,9 @@ #include "mpmd_impl.hpp" #include "mpmd_link_if_mgr.hpp" #include <uhdlib/rfnoc/mb_iface.hpp> -#include <map> +#include <uhdlib/usrp/common/io_service_mgr.hpp> #include <unordered_map> +#include <map> namespace uhd { namespace mpmd { @@ -33,7 +34,8 @@ public: uhd::endianness_t get_endianness(const uhd::rfnoc::device_id_t local_device_id); uhd::rfnoc::device_id_t get_remote_device_id(); std::vector<uhd::rfnoc::device_id_t> get_local_device_ids(); - uhd::transport::adapter_id_t get_adapter_id(const uhd::rfnoc::device_id_t local_device_id); + uhd::transport::adapter_id_t get_adapter_id( + const uhd::rfnoc::device_id_t local_device_id); void reset_network(); uhd::rfnoc::clock_iface::sptr get_clock_iface(const std::string& clock_name); uhd::rfnoc::chdr_ctrl_xport::sptr make_ctrl_transport( @@ -44,14 +46,16 @@ public: const uhd::rfnoc::sep_id_pair_t& epids, const uhd::rfnoc::sw_buff_t pyld_buff_fmt, const uhd::rfnoc::sw_buff_t mdata_buff_fmt, - const uhd::device_addr_t& xport_args); + const uhd::device_addr_t& xport_args, + const std::string& streamer_id); uhd::rfnoc::chdr_tx_data_xport::uptr make_tx_data_transport( uhd::rfnoc::mgmt::mgmt_portal& mgmt_portal, const uhd::rfnoc::sep_addr_pair_t& addrs, const uhd::rfnoc::sep_id_pair_t& epids, const uhd::rfnoc::sw_buff_t pyld_buff_fmt, const uhd::rfnoc::sw_buff_t mdata_buff_fmt, - const uhd::device_addr_t& xport_args); + const uhd::device_addr_t& xport_args, + const std::string& streamer_id); private: uhd::device_addr_t _mb_args; @@ -59,8 +63,10 @@ private: xport::mpmd_link_if_mgr::uptr _link_if_mgr; uhd::rfnoc::device_id_t _remote_device_id; std::map<uhd::rfnoc::device_id_t, size_t> _local_device_id_map; - std::unordered_map<uhd::rfnoc::device_id_t, uhd::transport::adapter_id_t> _adapter_map; + std::unordered_map<uhd::rfnoc::device_id_t, uhd::transport::adapter_id_t> + _adapter_map; std::map<std::string, uhd::rfnoc::clock_iface::sptr> _clock_ifaces; + uhd::usrp::io_service_mgr::sptr _io_srv_mgr; }; }} /* namespace uhd::mpmd */ |