aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* rfnoc: adding RFNoC Python APIBrent Stapleton2020-01-025-0/+273
| | | | | | | | Adding Python bindings for the RFNoC API. This includes the rfnoc_graph, noc_block_base, and several other supporting classes. Templated functions are not currently supported. For example, `rfnoc_graph::get_block` can only return the basic block controller.
* rfnoc: fix typosBrent Stapleton2020-01-021-2/+2
| | | | Fixes: 967be2a4e82b ("uhd: mpm: apply clang-format to all files")
* uhd: fix for exception due to use of unconstructed mutexPatrick Sisterhen2020-01-021-4/+5
| | | | | | In chdr_ctrl_endpoint recv_thread, _recv_thread was starting at construction time and trying to lock mutex, but due to member declaration in class, mutex was not yet constructed
* examples: Add options to benchmark_rateMichael West2020-01-021-19/+39
| | | | | | | | - Add option for high or normal thread priority with default set to high - Add rx_delay and tx_delay options to dynamically set start delays (default of 0.25 seconds for TX and 0.05 seconds for RX) Signed-off-by: Michael West <michael.west@ettus.com>
* multi_usrp: unify GPIO access typeBrent Stapleton2019-12-301-1/+1
| | | | | | | | GPIOs in the property tree are registered as uint32_t's, so the get_gpio_attr function should use that type as well. This resolves a property tree runtime_error when running the `gpio` example with a B2xx device.
* tests: fixup compiler warningBrent Stapleton2019-12-301-1/+1
| | | | Fixes cb40069b ("tests: Port polling-mode dpdk_test to new DPDK...")
* Tests: Fix subdev for N300 streaming testsmichael-west2019-12-301-6/+6
| | | | Signed-off-by: michael-west <michael.west@ettus.com>
* examples: benchmark_rate dpdk recv/send thread priority elevationmattprost2019-12-201-0/+13
| | | | | | | | | | Improves dpdk streaming performance for benchmark_rate by elevating thread priority of the send and recv threads. It does this conditionally, if use_dpdk=1 was passed in through the command line args. Admittedly, this is not a perfect solution, as it does not account for the case when a dpdk user is utilizing a config file to pass in that information. The scope of this fix does seem appropriate for an example.
* dpdk: Change client to wait on member variableCiro Nishiguchi2019-12-201-8/+12
| | | | | | Waiting on queue status seems to not always work, the queue state seems to not be updated immediately after pushing an item onto it when queried from a different thread.
* usrp: Change default number of data frames for X300Ciro Nishiguchi2019-12-201-16/+20
| | | | | | Change the default number of frames so that it works well when using offload threads, including DPDK. This matches the default number of frames in mpmd.
* transport,usrp: Make available packet-based flow controlAlex Williams2019-12-207-46/+61
| | | | | | | | DPDK provides a fixed number of fixed-size buffers for the receive window, so it needs packet-based flow control to avoid dropping packets. This change enables counting by packets. Co-authored-by: Ciro Nishiguchi <ciro.nishiguchi@ni.com>
* tests: Port polling-mode dpdk_test to new DPDK frameworkAlex Williams2019-12-203-83/+121
| | | | | | The mock_send_transport and mock_recv_transport are used, which ends up with two layers of flow control. More work may be needed here for comparisons with the old data.
* rfnoc: Make chdr_ctrl_xport recv_io callbacks have symbolsAlex Williams2019-12-202-26/+50
| | | | This helps a little with debugging (for breakpoints).
* transport: Fix comment on recv_io_if::fc_callback_tAlex Williams2019-12-201-1/+1
| | | | It referenced the wrong function for releasing recv buffers.
* usrp: Add I/O service manager for DPDKCiro Nishiguchi2019-12-203-0/+93
|
* lib: Remove dpdk_zero_copy filesMartin Braun2019-12-2014-3420/+0
| | | | These were left here as a reference.
* x300,mpmd: Enable DPDKMartin Braun2019-12-2012-465/+216
| | | | | | | | | | | | | | x300: - Remove obsolete variables from x300_eth_mgr and X300 motherboard components - Added some documentation / comments - Use constrained device args in more places - Enables the use of use_dpdk=1 - Switches between regular (kernel-based) and DPDK UDP mpmd: - Merge link_if_ctrl for udp and dpdk_udp - Update cmake options
* dpdk: Add new DPDK stack to integrate with I/O servicesAlex Williams2019-12-2018-352/+2633
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | docs: Update DPDK docs with new parameters: Parameter names have had their hyphens changed to underscores, and the I/O CPU argument is now named after the lcores and reflects the naming used by DPDK. transport: Add new udp_dpdk_link, based atop the new APIs: This link is tightly coupled with the DPDK I/O service. The link class carries all the address information to communicate with the other host, and it can send packets directly through the DPDK NIC ports. However, for receiving packets, the I/O service must pull the packets from the DMA queue and attach them to the appropriate link object. The link object merely formats the frame_buff object underneath, which is embedded in the rte_mbuf container. For get_recv_buff, the link will pull buffers only from its internal queue (the one filled by the I/O service). transport: Add DPDK-specific I/O service: The I/O service is split into two parts, the user threads and the I/O worker threads. The user threads submit requests through various appropriate queues, and the I/O threads perform all the I/O on their behalf. This includes routing UDP packets to the correct receiver and getting the MAC address of a destination (by performing the ARP request and handling the ARP replies). The DPDK context stores I/O services. The context spawns all I/O services on init(), and I/O services can be fetched from the dpdk_ctx object by using a port ID. I/O service clients: The clients have two lockless ring buffers. One is to get a buffer from the I/O service; the other is to release a buffer back to the I/O service. Threads sleeping on buffer I/O are kept in a separate list from the service queue and are processed in the course of doing RX or TX. The list nodes are embedded in the dpdk_io_if, and the head of the list is on the dpdk_io_service. The I/O service will transfer the embedded wait_req to the list if it cannot acquire the mutex to complete the condition for waking. Co-authored-by: Martin Braun <martin.braun@ettus.com> Co-authored-by: Ciro Nishiguchi <ciro.nishiguchi@ni.com> Co-authored-by: Brent Stapleton <brent.stapleton@ettus.com>
* transport: Fix uninitialized offload I/O service _client_typeAlex Williams2019-12-201-5/+2
| | | | | | The client type is kept in _offload_thread_params, but a separate, unitialized field is checked in member functions. Remove the duplicate and switch the checks over. This fixes offload_io_srv_test.
* tests: Add more tests for max rate streamingCiro Nishiguchi2019-12-184-89/+469
| | | | | Add more tests to compare streaming rates with previous releases. Changed the output string to a table.
* prefs: Output debug trace when config file cannot be located or loadedAaron Rossetto2019-12-172-8/+14
|
* tools: typo in x3x0 dpdk fpga_funcverif testmattprost2019-12-171-3/+3
|
* X310: update UBX/SBX gain settings for phase alignment testingerickshepherdNI2019-12-131-3/+3
| | | | | Update UBX and SBX gain settings in the manual for phase alignment testing.
* docs: Add note about DPDK needing to be built as shared librariesAaron Rossetto2019-12-131-1/+10
|
* tests: Install all stream performance scriptsBrent Stapleton2019-12-061-1/+3
| | | | | | | Install all of the streaming performance tests scripts, not just the X300 one. Fixes: 2bf1f0acaa35 ("tests: Add script to execute batch of bench...")
* tests: Add tests to exercise max streaming rates and report resultsCiro Nishiguchi2019-12-063-0/+1008
|
* tests: Add script to execute batch of benchmark_rate runsCiro Nishiguchi2019-12-065-0/+424
| | | | | Script runs benchmark_rate repeatedly, parses results, and calculates average, min, and max of each value reported.
* utils: algorithm: Add missing include uhd/config.hppMartin Braun2019-12-051-0/+1
|
* ddc: fixup decimation propertyBrent Stapleton2019-12-051-2/+2
| | | | | | | | - Use coerce_decim(), not int(), to coerce the decimation rate - Fix typo Fixes: a36fc4604f9b ("rfnoc: DDC: Fix property propagation") Fixes: 36853315741a ("rfnoc: Add DDC block controller")
* prefs: Set init_done flag to true after loading config filesMartin Braun2019-12-051-0/+1
| | | | | | | The prefs API is supposed to load the config files once, and stash them away for the process to consume at will. Because the init_done is never set, it will read the config files every time it's asked for them. This is usually not a problem, but it causes the logging output to be messy.
* docs: fixing doxygen errors reported during makesteviez2019-12-039-20/+25
|
* e31x: Fix filter bank and antenna switching for channel 0Sugandha Gupta2019-12-023-43/+60
| | | | | | The filter bank and antenna switches have different configuration for channel 0 and channel 1. This commit fixes the issue where channel 0 produces only noise due to incorrect switches.
* rfnoc: DDC/DUC: Fix fp-issues with samp_rate propertiesBrent Stapleton2019-11-272-6/+67
| | | | | | Only update DDC/DUC samp_rate properties if the number is substantially different (don't update for sub-1Hz property calculations). This fixes resolver exceptions for certain rates.
* ddc: Applying clang-formatBrent Stapleton2019-11-271-8/+7
|
* rfnoc: graph: Add logging to resolver errorsBrent Stapleton2019-11-271-1/+6
|
* images: Update images package for UHD 4.0Sugandha Gupta2019-11-261-12/+12
| | | | | Updates FPGA images for X3xx, N3xx, E320 and B200 series. All Gen-3 devices receive a compat number bump.
* utils: tasks: Use uhd::set_thread_name()Martin Braun2019-11-261-3/+1
| | | | | This is a more portable option to set thread names. References to pthreads are now limited to thread.cpp, where they belong.
* mpmd: Name the claimer task threadMartin Braun2019-11-261-13/+15
| | | | | We call set_thread_name() on the claimer loop so the thread can be identified using OS utilities.
* x300: pcie manager updatesVirendra Kakade2019-11-262-129/+93
| | | | Signed-off-by: Virendra Kakade <virendra.kakade@ni.com>
* rfnoc: fix packet swapping from U32 to U64Virendra Kakade2019-11-261-5/+8
| | | | Signed-off-by: Virendra Kakade <virendra.kakade@ni.com>
* rfnoc: fix incorrect long fifo wait timeoutsVirendra Kakade2019-11-261-2/+2
| | | | | | | This fixes behavior where we would get long 100 sec timeouts on fifo waits instead of 100 ms timeouts. Signed-off-by: Virendra Kakade <virendra.kakade@ni.com>
* mpm: mg: Make set_master_clock_rate() an async callMartin Braun2019-11-262-2/+17
| | | | | | The ad9371 call set_master_clock_rate() can take a while depending on the rate change, so make it asynchronous in order not to lock out the reclaimer loop.
* mg: Turn the set-lock into a recursive mutexMartin Braun2019-11-262-15/+15
| | | | | Individual API calls might have to call each other (e.g., like set_rate() will call set_rx_frequency()), which would cause a deadlock.
* mg: Always set MCR on both daughterboardsMartin Braun2019-11-263-12/+33
| | | | | | | | | | | | | | | | | The N310 cannot set the MCR for its daughterboards separately. This patch modifies the radio block controller such that any block controller, when requested to change the master clock rate, will first change Radio 0, and then Radio 1. This fixes the following issues: - In multi_usrp, calling set_master_clock_rate() will not necessarily call set_rate() on the radios in any particular order, which will break when calling Radio 1 first - In RFNoC apps, it wasn't possible to run off of slot B alone without this change. Note: When calling set_rate() on one radio, the other radio is in an invalid state until its set_rate() is also called.
* lib: Add DPDK service queueAlex Williams2019-11-262-0/+302
| | | | | | | This is a data structure intended for use by the DPDK I/O service. It uses DPDK's lockless ring in multi-producer, single-consumer mode to allow clients to submit requests to the DPDK I/O service's worker thread. Clients can specify a timeout for the requests to be fulfilled.
* rfnoc: fix invalid access when sending packet with no samplesCiro Nishiguchi2019-11-261-1/+3
|
* mpm: e31x: Remove superfluous code from e31x_periphsMartin Braun2019-11-262-14/+2
| | | | | | | | | - ref_locked failure would throw a warning, even though this can happen in normal operations, and the return value of the get_ref_locked() function is all the info needed - get_fpga_type() doesn't need to be called from e31x_periphs, because it is not read from the motherboard registers (is read from the EEPROM)
* mpmd: Fix get_mboard_name()Martin Braun2019-11-261-1/+1
| | | | | It used to produce the individual name of the USRP, but it should return a product name.
* mpm: e31x: Fix setting of clock sourceMartin Braun2019-11-261-4/+1
| | | | | | | The clock source on E310 is always internal. This patch removes the variables regarding the clock source (since they are superfluous). This fixes a bug where self._clock_source on the e31x class would never get initialized.
* mpm: e310: Enable GPS sensorsMartin Braun2019-11-262-5/+70
| | | | The GPS sensors are pulled in via gpsd_iface.