aboutsummaryrefslogtreecommitdiffstats
path: root/host
Commit message (Collapse)AuthorAgeFilesLines
...
* rfnoc: mb_iface: Add API to query link endiannessMartin Braun2019-11-261-0/+9
|
* rfnoc: rfnoc_graph: Refactor classMartin Braun2019-11-261-110/+142
| | | | | | | - Remove duplicate calls to uhd::device::make - Do a try/catch on full class initialization - Separate setup_graph() into multiple sub-functions - Improve const-correctness
* rfnoc: DDC: Fix property propagationMartin Braun2019-11-264-85/+225
| | | | | | | | | - Combine scaling and samp_rate resolvers - Prioritize decim when user has set it for DDC: When samp_rate_in changes, either the samp_rate_out or the decim values may change to accommodate it. If decim has been set by the user (which can be determined by the valid flag), prefer changing samp_rate_out over decim.
* rfnoc: node: Make register_property() unlock RW accessMartin Braun2019-11-262-2/+14
|
* rfnoc: add rx and tx transports, and amend rfnoc_graphCiro Nishiguchi2019-11-2631-334/+4540
| | | | | | | | | | | | | | | | | | | | | | | transports: Transports build on I/O service and implements flow control and sequence number checking. The rx streamer subclass extends the streamer implementation to connect it to the rfnoc graph. It receives configuration values from property propagation and configures the streamer accordingly. It also implements the issue_stream_cmd rx_streamer API method. Add implementation of rx streamer creation and method to connect it to an rfnoc block. rfnoc_graph: Cache more connection info, clarify contract Summary of changes: - rfnoc_graph stores more information about static connections at the beginning. Some search algorithms are replaced by simpler lookups. - The contract for connect() was clarified. It is required to call connect, even for static connections.
* rfnoc: Add tracking of 'valid' bit to propertiesAlex Williams2019-11-265-18/+84
| | | | | | The valid bit helps prevent placeholder defaults from being propagated through the graph. Values that are not valid will not be forwarded.
* rfnoc: Enable users to query connections in the graphAlex Williams2019-11-265-13/+189
| | | | Implement uhd::rfnoc::rfnoc_graph::enumerate_*_connections()
* rfnoc: rfnoc_graph: Change block's subtrees to be /blocks/$BLOCKIDMartin Braun2019-11-261-2/+7
|
* rfnoc: graph: Initialize properties on all nodes during initMartin Braun2019-11-263-0/+14
| | | | | This will call init_props() on every block after the device initialization is complete, but before control returns to the user.
* rfnoc: flushing and reset blocks on graph creationBrent Stapleton2019-11-263-3/+71
| | | | | | During construction of the rfnoc_graph, flush and reset each block in each motherboard we need to enumerate. This will ensure that each block is in a clean state when we construct it's block controller.
* rfnoc: Add clock selection to blocksMartin Braun2019-11-2614-63/+133
| | | | | | | | | | | | | | | | | | | | | | | | | | During registration, blocks must now specify which clock they are using for the timebase (i.e., for timed commands) and for the ctrlport (this is used to determine the length of sleeps and polls). For example, the X300 provides bus_clk and radio_clk; typically, the former is used for the control port, and the latter for the timebase clock. Another virtual clock is called "__graph__", and it means the clock is derived from property propagation via the graph. The actual clocks are provided by the mb_iface. It has two new API calls: get_timebase_clock() and get_ctrlport_clock(), which take an argument as to which clock exactly is requested. On block initialization, those clock_iface objects are copied into the block controller. The get_tick_rate() API call for blocks now exclusively checks the timebase clock_iface, and will no longer cache the current tick rate in a separate _tick_rate member variable. Block controllers can't manually modify the clock_iface, unless they also have access to the mb_controller (like the radio block), and that mb_controller has provided said access. This commit also adds the clock selection API changes to the DDC block, the Null block, and the default block.
* rfnoc: clock_iface: Add flag for clock to be (im-)mutableMartin Braun2019-11-261-1/+21
| | | | | An immutable clock means it has a locked frequency, and attempts to change the frequency will cause an exception to be thrown.
* rfnoc: Add shutdown feature to blocksMartin Braun2019-11-2611-3/+91
| | | | | | | | On destruction, the rfnoc_graph will call shutdown() on all blocks. This allows a safe de-initialization of blocks independent of the lifetime of the noc_block_base::sptr. Also adds the shutdown feature to null_block_control.
* rfnoc: register_iface_holder: Add ability to invalidate and updateMartin Braun2019-11-263-0/+96
| | | | | This lets child classes of register_iface_holder change the register interface, or even invalidate it.
* rfnoc: rfnoc_device: Make get_mb_iface() pure virtualMartin Braun2019-11-261-22/+1
|
* rfnoc: Make a chdr_ctrl_xport using the new link APIsAlex Williams2019-11-268-135/+182
| | | | | | | | | | These changes add APIs to instantiate the new transports. However, only the control/management transport is currently implemented. It uses the chdr_ctrl_xport. Also update the mgmt_portal to use an ephemeral reference to the shared transport, to indicate that it has no ownership of the transport's memory.
* rfnoc: Add chdr_ctrl_xportAlex Williams2019-11-264-4/+276
| | | | | | | | | | | | | | chdr_ctrl_xport is a dumb-pipe transport for RFNoC control transactions and management frames. Also remove the I/O service's check on num_recv_frames and num_send_frames. The transports may request additional virtual channels, so the send_io_if and recv_io_if may not reserve additional frames, as they are shared with a previously-allocated instance. Note: this uses a mutex to force sequentual access to the chdr_ctrl_xport. This is supposed to go away when the multi threaded xport is done.
* rfnoc: noc_block_base: Store property tree reference from make_argsMartin Braun2019-11-262-1/+17
|
* rfnoc: Add mb_controller base class and X300/MPMD implementationsMartin Braun2019-11-268-0/+246
|
* gpio_atr_3000: Formatting changesBrent Stapleton2019-11-262-156/+221
| | | | | | | | Applying clang format for upcoming changes. clang-format -i --style=file host/lib/usrp/cores/gpio_atr_3000.cpp clang-format -i --style=file \ host/lib/include/uhdlib/usrp/cores/gpio_atr_3000.hpp
* cores: gpio_atr_3000: Add capability to configure register offsetMartin Braun2019-11-262-43/+59
| | | | | | The existing implementation assumes registers are spaced 4 bytes apart. In the current radio block design, all backward compatible registers are spaced 8 bytes apart. This adds a feature to configure that offset.
* rfnoc: Add device_id allocatorMartin Braun2019-11-263-0/+40
| | | | | | This is a single atomic allocator in the global uhd::rfnoc namespace, so that devices can allocate themselves device IDs without having to confer with the rest of the RFNoC infrastructure.
* rfnoc: add reg_iface_adapterMartin Braun2019-11-261-0/+121
| | | | | This converts from register_iface& to wb_iface::sptr. Useful for connecting new block controllers with older interfaces.
* tx_fe_200: make register offset controllableBrent Stapleton2019-11-262-10/+11
| | | | | | Following the changes in RX frontend controls, TX frontend register offsets are now arguments to the factory function. They default to 4, which is what the register offset was in the file before these changes.
* rx_fe_3000: Changing register address calcBrent Stapleton2019-11-262-19/+31
| | | | | | | | Changing how we calculate RX frontend register addresses to allow for different register offsets. The register addresses are now calculated in a manor similar to how gpio_atr_300_impl does register address calculations, which is to allow a reg_offset to be passes in at construction. The current default is reg_offset=4.
* lib: cores: Adapt spi_core_3000 for use with register_ifaceMartin Braun2019-11-262-50/+92
| | | | | Removes the requirement for a wb_iface, and also the requirement for regs to be 4 addresses apart.
* rfnoc: Fixed race condition in chdr_ctrl_endpointAshish Chaudhari2019-11-261-2/+4
| | | | | | The lock acquired by send_fn does not need to share the same mutex as the rest of the class. It only needs to serialize between multiple calls to send_fn. Gave send_fn it's own mutex for that reason
* rfnoc: Add check_topology() API to nodesMartin Braun2019-11-265-0/+99
| | | | | This API lets blocks decide if their current topology is OK for them, and make decisions based on their topology.
* rfnoc: rfnoc_graph: Add API to query the number of motherboardsMartin Braun2019-11-262-1/+12
|
* rfnoc: enumerate and construct block controllers, enable connect()Brent Stapleton2019-11-262-11/+217
| | | | | During construction of the rfnoc_graph, enumerate all of the connected blocks, construct their controllers, and store them in the graph.
* rfnoc: Add null block controllerMartin Braun2019-11-266-0/+360
|
* rfnoc: noc_block_base: Pass args into block on constructionMartin Braun2019-11-264-0/+14
| | | | | These args come from the framework, e.g., because the UHD session was launched with them.
* rfnoc: graph: Add commit/release APIMartin Braun2019-11-267-11/+74
|
* rfnoc: noc_block_base: Add API to reduce num portsMartin Braun2019-11-262-0/+53
| | | | This allows blocks to reduce the number of actual, available ports.
* rfnoc: Add mb_controller APIMartin Braun2019-11-2614-1/+708
| | | | | | | | | The mb_controller is an interface to hardware-specific functions of the motherboard. The API works in two ways: - The user can request access to it, and thus interact directly with the motherboard - RFNoC blocks can request access to it, if they need to interact with the motherboard themselves.
* rfnoc: SW support for FPGA byte swapperAshish Chaudhari2019-11-262-8/+37
| | | | | The management looks at the transport endianness from the packet factory to determine if the byte_swapper in the FPGA needs to be enabled
* rfnoc: Add radio block controllerMartin Braun2019-11-266-0/+1751
|
* rfnoc: Added src port, EPID getters to register_iface, 64-bit callsAshish Chaudhari2019-11-263-4/+87
| | | | - Add peek64() and poke64() convenience calls
* rfnoc: Graph and link stream manager API cleanupAshish Chaudhari2019-11-269-81/+408
|
* rfnoc: noc_block_base: Handle the tick_rate property internallyMartin Braun2019-11-265-40/+99
| | | | | | | | | | | All noc_block_base derivatives are now plugged into the tick rate system. Connected nodes can only have one tick rate among them. This implies there is also only ever one tick rate per block. set_tick_rate() is a protected API call which can be called by blocks such as radio blocks to actually set a tick rate. Other blocks would only ever read the tick rate, which is handled by the get_tick_rate() API call.
* rfnoc: node: Add API to query and set edge propertiesMartin Braun2019-11-262-7/+50
|
* rfnoc: node: Fix resolution of properties with circular dependenciesMartin Braun2019-11-262-41/+111
| | | | | | | When a node has multiple properties that depend on each other (and possible have circular dependencies), the previous version of property propagation would not correctly resolve properties that got flagged dirty during the execution of other resolvers.
* rfnoc: Enable daisy-chaining in mgmt_portalAshish Chaudhari2019-11-261-5/+14
|
* rfnoc: Added link/graph specific stream managersAshish Chaudhari2019-11-2610-27/+722
| | | | | - Fleshed out mb_iface - Managers currently only export ctrl APIs. Data APIs TBD
* rfnoc: API cleanup for ctrl/mgmt codeAshish Chaudhari2019-11-266-73/+116
| | | | | | - chdr_ctrl_endpoint can manage multiple dest EPIDs - Moved from both_xports_t to a special defs in rfnoc_common - Changed data-structures where appropriate
* rfnoc: Moved chdr types/packet class out of chdr dirAshish Chaudhari2019-11-2616-75/+99
| | | | | | - Moved chdr_packet and chdr_types from rfnoc/chdr to rfnoc and updated all references - Moved non-CHDR definitions to rfnoc_common.hpp
* uhd: add udp boost asio implementation of transport interfaceCiro Nishiguchi2019-11-269-195/+491
|
* uhdlib: transport: Add links.hppMartin Braun2019-11-261-0/+43
| | | | This contains both_links_t
* transport: Implement a single-threaded I/O serviceAlex Williams2019-11-266-0/+1100
| | | | | | | | | | | | | | | | | | | | The inline_io_service connects transports to links without any worker threads. Send operations go directly to the link, and recv will perform the I/O as part of the get_recv_buffer() call. The inline_io_service also supports muxed links natively. The receive mux is entirely inline. There is no separate thread for the inline_io_service, and that continues here. A queue is created for each client of the mux, and packets are processed as they come in. If a packet is to go up to a different client, the packet is queued up for later. When that client attempts to recv(), the queue is checked first, and the attempts to receive from the link happen ONLY if no packet was found. Also add mock transport to test I/O service APIs. Tests I/O service construction and some basic packet transmision. One case will also uses a single link that is shared between the send and recv transports. That link is muxed between two compatible but different transports.
* transport: Introduce I/O service layer between transport and linkAlex Williams2019-11-261-0/+337
| | | | | | | | | | | Split the transport into three layers to allow for greater flexibility in scheduling algorithms. The io_service will make queues on behalf of the transport and take responsibility for scheduling data transfers through the links. The transport layer is the explicit handler for flow control. This enables the possibility of a scheduling layer in between, so flow control may be offloaded on the same thread as the link.