diff options
author | Matthew Crymble <matthew.crymble@ni.com> | 2020-08-03 14:48:03 -0500 |
---|---|---|
committer | Aaron Rossetto <aaron.rossetto@ni.com> | 2020-08-04 15:46:54 -0500 |
commit | c13ba0d21f80fee022f31e13cad0c5b0aa712aaf (patch) | |
tree | 12ed62a09f3e2834f7d7a229153ef6dae4871873 /host/lib/transport/nirio_link.cpp | |
parent | d81816a225979ff26bf1eec454f1caddb94d0ab6 (diff) | |
download | uhd-c13ba0d21f80fee022f31e13cad0c5b0aa712aaf.tar.gz uhd-c13ba0d21f80fee022f31e13cad0c5b0aa712aaf.tar.bz2 uhd-c13ba0d21f80fee022f31e13cad0c5b0aa712aaf.zip |
X300: fix for incorrect PCIe buffer size values
added extra args to get PCIe buffer sizes from factory method
Diffstat (limited to 'host/lib/transport/nirio_link.cpp')
-rw-r--r-- | host/lib/transport/nirio_link.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/host/lib/transport/nirio_link.cpp b/host/lib/transport/nirio_link.cpp index adef8b5a0..b5c4845d8 100644 --- a/host/lib/transport/nirio_link.cpp +++ b/host/lib/transport/nirio_link.cpp @@ -170,7 +170,9 @@ nirio_link::~nirio_link() nirio_link::sptr nirio_link::make(uhd::niusrprio::niusrprio_session::sptr fpga_session, const uint32_t instance, const uhd::transport::link_params_t& default_params, - const uhd::device_addr_t& hints) + const uhd::device_addr_t& hints, + size_t& recv_buff_size, + size_t& send_buff_size) { UHD_ASSERT_THROW(default_params.num_recv_frames != 0); UHD_ASSERT_THROW(default_params.num_send_frames != 0); @@ -292,6 +294,9 @@ nirio_link::sptr nirio_link::make(uhd::niusrprio::niusrprio_session::sptr fpga_s .str()); } + recv_buff_size = link_params.num_recv_frames * link_params.recv_frame_size; + send_buff_size = link_params.num_send_frames * link_params.send_frame_size; + return nirio_link::sptr(new nirio_link(fpga_session, instance, link_params)); } |