aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib/rfnoc
Commit message (Collapse)AuthorAgeFilesLines
* device3: Constraint send/recv_frame_size based on down/upstream MTUSugandha Gupta2019-05-213-5/+27
| | | | | | We need to properly contraint the send/recv_frame_size based on the minimum MTU of all the down/upstream blocks. This fixes the issue with E310 tx/rx streaming as it has smaller MTU sizes than the other usrps.
* Revert "RFNoC: Remove incorrect flush"Michael West2019-03-251-0/+19
| | | | | | This reverts commit c8e01d4bd5bef30ef6e6080c60bc8b4706eb1200. The commit introduced random phase offsets for TwinRX phase alignment.
* TwinRX: Fix duplicate write to N value in DDCmichael-west2019-03-251-2/+1
| | | | | | | The N value was getting written twice and the second value being written was 1, which works for all use cases except when using TwinRX. This change fixes several issues with TwinRX including streaming failing to stop cleanly and incorrect decimation.
* RFNoC: Remove incorrect flushMichael West2019-03-051-19/+0
| | | | | | | | | | | | Removing the flush in configure_flow_control_out(). The flush is done incorrectly because it just disables flow control and allows packets to dump onto the crossbar, which could lock it up. It is also incorrect to flush when connecting blocks. A connect should just configure the SID and flow control and let any existing data flow to the newly connected block. Flushing of a block should only be done during creation or destruction of the block. Signed-off-by: Michael West <michael.west@ettus.com>
* Revert "RFNoC: Fix flush in source_block_ctrl_base"Michael West2019-03-051-1/+18
| | | | | | This reverts commit 655b9b0f8e8f8556d434404da51aaccd124bbc3a. Signed-off-by: Michael West <michael.west@ettus.com>
* lib: Fix various type-conversion compiler warningsMartin Braun2019-03-054-5/+7
| | | | | This makes more type-conversions explicit, to reduce the number of warnings specifically for MSVC.
* RFNoC: Fix flush in source_block_ctrl_baseMichael West2019-02-181-18/+1
| | | | | | | | | | The configure_flow_control_out function was set to dump any packets onto the crossbar, which could cause issues on the crossbar and in downstream blocks. Replacing wil a call to the _flush() function in the block_ctrl_base parent class, which drops the packets so they do not get put onto the crossbar. Signed-off-by: Michael West <michael.west@ettus.com>
* RFNoC: Disable FC ACK packets for lossless linksMichael West2019-02-182-8/+15
| | | | | | | FC ACK packets are unnecessary on lossless links and degrade overall performance. This change disables those packets on all lossless links. Signed-off-by: Michael West <michael.west@ettus.com>
* fixup! RFNoC: Fix scaling of M and N values in DDC/DUCMark Meserve2019-02-081-1/+1
|
* RFNoC: Limit number of control packets in flightmichael-west2019-01-311-2/+2
| | | | | | | | Limit number of unacknowledged control packets to the number of receive frames in the transport to prevent the transport from getting locked up or being overrun by ACK packets. Signed-off-by: michael-west <michael.west@ettus.com>
* RFNoC: Fix typos in legacy_compatmichael-west2019-01-311-2/+2
| | | | Signed-off-by: michael-west <michael.west@ettus.com>
* X300: Fix tick and sample rate settingmichael-west2019-01-311-6/+8
| | | | | | | | | | | | - Removed incorrect function call to set tick rate in x300_radio_ctrl_impl. - Modified legacy compat layer to properly set tick and sample rates. These changes eliminate the tick and sample rate warnings during X300 initialization if TwinRX is used and allow for TwinRX to be used alongside other types of daughterboards in the same X300. Signed-off-by: michael-west <michael.west@ettus.com>
* RFNoC: Fix scaling of M and N values in DDC/DUCmichael-west2019-01-312-3/+10
| | | | | | | Scale the M and N values if the tick_rate differs from the sample rate. Fixes timestamps in packets when using TwinRX on X300. Signed-off-by: michael-west <michael.west@ettus.com>
* fixup! RFNoC: More graph traversal fixesmichael-west2019-01-312-4/+4
|
* RFNoC: More graph traversal fixesmichael-west2019-01-312-1/+3
| | | | | | | | | | - Store number of input and ouptput ports from block definition. - Use number of input and ouptut ports for graph traversal rather than number of connected blocks. - Fixes DAC synchronization failure errors when using only one TX channel on X300. Signed-off-by: michael-west <michael.west@ettus.com>
* lib: rfnoc: Add some missing virtual destructorsMartin Braun2019-01-223-2/+8
|
* formatting: Apply clang-format to nocscript filesMartin Braun2019-01-228-557/+499
|
* transport: muxed_zero_copy_if fixesmichael-west2019-01-211-1/+1
| | | | | | | | | | Changed muxed_zero_copy_if to make each stream buffer the same number of frames as the underlying transport and changed the size of the underlying control transport for X300 and MPMD devices to match the size of the command FIFO in order to prevent starvation of any single control transport. Added some constants to remove hard coded values. Signed-off-by: michael-west <michael.west@ettus.com>
* rfnoc: Fix detection of outstanding acks by ctrl_ifaceMartin Braun2019-01-171-4/+3
| | | | | | | There was a bug where the number of outstanding ACKS in RFNoC's ctrl_iface was derived from the number of recv frames, which was wrong. A number that was too low would effectively break timed commands on tune, which would, e.g., affect phase alignment.
* lib: rfnoc: apply clang-formatMartin Braun2019-01-1729-1905/+1859
| | | | | | This is a continuation of 967be2a4. $ clang-format -i -style=file host/lib/rfnoc/*.cpp
* formatting: remove vim hints in headersBrent Stapleton2019-01-164-4/+0
| | | | | Remove trailing vim hints in header files. This functionality will be replaced by clang-format.
* RFNoC: Fix stream command propagationmichael-west2018-12-201-1/+1
| | | | | | - Corrects parameter from output port to input port of node - Fixes issue on nodes with different number of input and output connections
* RFNoC: Fix graph traversalmichael-west2018-12-193-14/+16
| | | | | | - Allows different TX sample rates on separate channels - Prevents stream commands from being issued on wrong ports - Prevents some receive timeout errors
* Device3: Fix block control flushingBrent Stapleton2018-12-171-18/+25
| | | | | | | | | | | | | | | | | | | - Factor out the _start_drain helper function, which starts flushing data out of the block. We should always be disabling flow control after we write to the flushing registers. - Always attempt to flush when calling the _flush function. Previously, we would check if data appeared to be moving when _flush was called, and only write to the flush registers if data was moving. However, if data is stuck for some reason (for example, the block ran out of flow control credits), this check will give us a false positive, and we won't flush. Instead, we need to always begin the flushing process, then check those counters, and return once the counters stop changing. Note: we need to start flushing before disabling flow control so that the flushed data isn't flooded onto the crossbar. Co-authored-by: michael-west <michael.west@ettus.com> Co-authored-by: Sugandha Gupta <sugandha.gupta@ettus.com>
* Device3: Set default block control response SIDsBrent Stapleton2018-12-171-0/+4
| | | | | | | | | | | In the block controllers, set the default response SIDs for input and output ports. If we don't do this, the blocks may send their responses to other blocks' responses ports. For example, without this change, the DDC may send an error packet to port 0x0000, which is assigned to the DmaFIFO. With this change, the DDC would send that packet to 0xFFFF, which isn't assigned to any other block.
* rfnoc: Add halt to replay APIWade Fife2018-11-271-0/+4
| | | | | The HALT feature allows a command that takes a long time to run to be stopped while it is in progress.
* rfnoc: Fix default SPP for replayWade Fife2018-11-271-4/+3
| | | | Consolidate two constants for default replay packet size down to one.
* cmake: Update coding style to use lowercase commandsMartin Braun2018-11-141-4/+4
| | | | | | | | | | | | | | | | | Also updates our coding style file. Ancient CMake versions required upper-case commands. Later command names became case-insensitive. Now the preferred style is lower-case. Run the following shell code (with GNU compliant sed): cmake --help-command-list | grep -v "cmake version" | while read c; do echo 's/\b'"$(echo $c | tr '[:lower:]' '[:upper:]')"'\(\s*\)(/'"$c"'\1(/g' done > convert.sed \ && git ls-files -z -- bootstrap '*.cmake' '*.cmake.in' \ '*CMakeLists.txt' | xargs -0 gsed -i -f convert.sed && rm convert.sed (Make sure the backslashes don't get mangled!)
* rfnoc: Replace some [] with .at() in radio_ctrl_implMartin Braun2018-11-131-8/+8
| | | | | This makes it easier to detect errors in derived classes that expect getters in radio_ctrl_impl to also do error checking.
* block_ctrl_base: add UHD_SAFE_CALL to destructorTrung Tran2018-10-241-13/+15
| | | | | This will stop the exception throw during destructor of E310 where new FPGA image(idle image) is load.
* uhd: Add traffic counter to null source sinkCiro Nishiguchi2018-10-111-0/+19
|
* uhd: Fix rounding in ddc/duc rate calculationCiro Nishiguchi2018-10-052-2/+2
| | | | | | | | The DDC and DUC convert the requested rate to an integer before selecting a decimated / interpolated rate. This causes the selection to select a lower rate than requested in some corner cases. The effect is more pronounced when the input rate of the DDC or the output rate of the DUC is very small.
* uhd: rfnoc: add async message handlerTrung Tran2018-09-143-4/+201
|
* radio_ctrl: add disable time stampTrung Tran2018-09-141-0/+8
|
* RFNoC: Add Replay API and exampleWade Fife2018-08-292-0/+184
|
* RFNoC: Convert SR_READBACK_REG_FIFOSIZE to bytesTrung N Tran2018-08-221-3/+1
| | | | | Change the RB_FIFOSIZE register to store the FIFO size in bytes instead of log2 of bytes.
* X300: Change Ethernet bufferingMichael West2018-07-253-9/+10
| | | | | | | Ethernet buffering is now done so that most of the buffering is done in the socket buffers and multiple frames are only used to support the receive side offload of the socket I/O. Eliminates dropped packets at high full duplex rates.
* Device3: Change packet-based flow control to byte-based flow controlMartin Braun2018-07-255-41/+47
|
* rfnoc: Enabled SW flush mechanism impl'd in noc_shellAshish Chaudhari2018-07-241-2/+84
| | | | | | | | | | | - UHD will now "disconnect" the noc_block data-path from the crossbar when the block's dtor is invoked. This allows long running or slow blocks to empty out rapidly during teardown. - UHD will also attempt to flush at init time in case a block is destroyed abnormally. The goal of the flush mechanism is to not lock up the FPGA - noc_shell compat number is now 3
* rfnoc: legacy_compat: Remove superfluous variableMartin Braun2018-07-231-1/+0
|
* legacy_compat: Fix tx/rx channel map initialization for all channelsSugandha Gupta2018-07-091-5/+14
| | | | | | | | This will populate tx/rx channel map (radio and port index) considering number of channels, radios and mboards. On TwinRX and N310, the default subdev spec will now include all available channels.
* UHD: Make ctrl_iface_impl deconstructor virtualMartin Braun2018-06-221-1/+1
|
* UHD: Update copyright datesMartin Braun2018-06-222-2/+2
|
* RFNoC: Add FIR, Null, and Window block controllersMartin Braun2018-06-224-0/+282
|
* RFNoC: Add Siggen block controllerSugandha Gupta2018-06-221-0/+49
|
* rfnoc: Warn when a block key is not found in the registryMartin Braun2018-06-081-4/+7
| | | | | | | Before, a block description file could specify a block controlley key which was not mapped to a registered block controller, and it would fall back to the default. While that behaviour is desired, it was lacking a warning when it made that decision.
* X300/TwinRX: Fix for RuntimeError: Could not find block in list for device ↵Michael West2018-05-151-5/+5
| | | | 0, radio 0, and port 1
* X300: Temporary suppression of warning regarding number of input buffersMichael West2018-05-151-8/+8
|
* legacy_compat: skip fifo ports size checkTrung N Tran2018-05-091-15/+23
| | | | | | We don't need to assert error if there are not enough fifo ports to connect to radio. Radio ports still can be connected to all available fifo ports until they're running out.
* lib: Purge use of boost::assign, except for uhd::dictMartin Braun2018-05-023-18/+15
| | | | | | | Replaced with initialization lists. Note: uhd::dict does not work with initializer lists without making changes to said data structure. This commit has no functional changes, so keeping the boost::assigns for uhd::dict.