aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib/rfnoc/source_block_ctrl_base.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'host/lib/rfnoc/source_block_ctrl_base.cpp')
-rw-r--r--host/lib/rfnoc/source_block_ctrl_base.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/host/lib/rfnoc/source_block_ctrl_base.cpp b/host/lib/rfnoc/source_block_ctrl_base.cpp
index 656ab26af..d06b6632d 100644
--- a/host/lib/rfnoc/source_block_ctrl_base.cpp
+++ b/host/lib/rfnoc/source_block_ctrl_base.cpp
@@ -143,6 +143,16 @@ void source_block_ctrl_base::configure_flow_control_out(const bool enable_fc_out
sr_write(SR_FLOW_CTRL_EN, config, block_port);
}
+size_t source_block_ctrl_base::get_mtu(size_t block_port) const
+{
+ if (_tree->exists(_root_path / "mtu" / std::to_string(block_port))) {
+ return _tree->access<size_t>(_root_path / "mtu" / std::to_string(block_port))
+ .get();
+ }
+ return 0;
+}
+
+
/***********************************************************************
* Hooks
**********************************************************************/