aboutsummaryrefslogtreecommitdiffstats
path: root/mpm/python/usrp_mpm/sys_utils/uio.py
Commit message (Collapse)AuthorAgeFilesLines
* mpm: Make contextmanagers exception-safeLane Kolbly2020-03-031-2/+4
| | | | When making context managers in Python, the yield statement has to be wrapped in a try/finally clause in order to properly clean up after exceptions happen.
* uio: mpm: Fixup for opening mboard-regs UIOBrent Stapleton2018-07-231-11/+20
| | | | | | | | | - Fix the syntax to open mboard-regs UIO objects, and change the open() and close() functions to be private. - We were calling open() twice in every context manager line- once manually, and once in __enter__. This commit corrects those usages, and allows the context manager to fully manage the opening and closing of UIO objects.
* mpm: uio: Fix use of loggerMartin Braun2018-07-191-1/+2
| | | | When logger==None, it uio.py would fail.
* mpm: adding reference counters to UIOBrent Stapleton2018-03-141-5/+39
| | | | | | | | | | | | UIO objects now count references on open and close calls. This should prevent problems with nested function calls that open/close the same UIO object. References counts are not atomic -- this is intended for nesting with statements within the same thread context. Reviewed-by: Martin Braun <martin.braun@ettus.com> Reviewed-by: Trung Tran <trung.tran@ettus.com>
* mpm: Update all license headersMartin Braun2018-02-191-2/+2
| | | | | - Fix typo in company name (missing 'a') - Updated SPDX license identifier to version 3.0
* mpm: Harmonize all license headerMartin Braun2017-12-221-13/+2
| | | | Now uses SPDX headers everywhere.
* mpm: UIOs now open only when necessaryBrent Stapleton2017-12-221-32/+36
| | | | | | | Refactoring to use the C++-based UIO objects. The Liberio and Ethernet objects now open the UIO before using it, and close it once done. Reviewed-By: Martin Braun <martin.braun@ettus.com>
* mpm: Harmonize imports, tidy + sort modulesMartin Braun2017-12-221-0/+167
- Moved nijesdcore to cores/ - Moved udev, net, dtoverlay, uio to sys_utils/ - Made all imports non-relative (except in __init__.py files) - Removed some unnecessary imports - Reordered some imports for Python conventions