aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib/transport
diff options
context:
space:
mode:
authorMichael West <michael.west@ettus.com>2019-06-19 13:25:32 -0700
committermichael-west <michael.west@ettus.com>2019-06-28 08:21:09 -0700
commit3f7b937d3fbabe0a885bdcaf8137502528db6e68 (patch)
treeb10d741b615cf9707420a7e24276d0ca67858c4b /host/lib/transport
parent55b9f7309f6f49eccd1157e898b77dc9a6afd238 (diff)
downloaduhd-3f7b937d3fbabe0a885bdcaf8137502528db6e68.tar.gz
uhd-3f7b937d3fbabe0a885bdcaf8137502528db6e68.tar.bz2
uhd-3f7b937d3fbabe0a885bdcaf8137502528db6e68.zip
Device3: Fix MTU and default frame sizes
The latest changes to the get_*x_stream() functions to calculate the MTU for the channel caused default frame size values to be ignored. This change fixes that by changing the key from "send/recv_frame_size" to "mtu" and then changing the implementations of make_transport() constrain the frame size values based on the "mtu" value as well as any device and/or transport-specific limits. Signed-off-by: Michael West <michael.west@ettus.com>
Diffstat (limited to 'host/lib/transport')
-rw-r--r--host/lib/transport/udp_zero_copy.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/host/lib/transport/udp_zero_copy.cpp b/host/lib/transport/udp_zero_copy.cpp
index 6d615570f..e3df80da6 100644
--- a/host/lib/transport/udp_zero_copy.cpp
+++ b/host/lib/transport/udp_zero_copy.cpp
@@ -384,6 +384,11 @@ udp_zero_copy::sptr udp_zero_copy::make(const std::string& addr,
xport_params.send_frame_size = UDP_ZERO_COPY_DEFAULT_FRAME_SIZE;
}
+ UHD_LOG_TRACE("UDP",
+ "send_frame_size: " << xport_params.send_frame_size);
+ UHD_LOG_TRACE("UDP",
+ "recv_frame_size: " << xport_params.recv_frame_size);
+
if (xport_params.recv_buff_size == 0) {
UHD_LOG_TRACE("UDP", "Using default value for recv_buff_size");
xport_params.recv_buff_size = std::max(UDP_ZERO_COPY_DEFAULT_BUFF_SIZE,