aboutsummaryrefslogtreecommitdiffstats
path: root/mpm/python/usrp_mpm/periph_manager/udev.py
diff options
context:
space:
mode:
Diffstat (limited to 'mpm/python/usrp_mpm/periph_manager/udev.py')
-rw-r--r--mpm/python/usrp_mpm/periph_manager/udev.py24
1 files changed, 0 insertions, 24 deletions
diff --git a/mpm/python/usrp_mpm/periph_manager/udev.py b/mpm/python/usrp_mpm/periph_manager/udev.py
index 73601e85c..6801d2163 100644
--- a/mpm/python/usrp_mpm/periph_manager/udev.py
+++ b/mpm/python/usrp_mpm/periph_manager/udev.py
@@ -42,27 +42,3 @@ def get_spidev_nodes(spi_master):
for device in context.list_devices(parent=parent, subsystem="spidev")]
return paths
-def get_uio_node(uio_name):
- """
- Return found uio device path for a give parent name
- """
- context = pyudev.Context()
- paths = [device.sys_path
- for device in context.list_devices(subsystem="uio")]
- log = get_logger('get_uio_node')
- log.debug("get_uio_node")
- log.debug("got paths: %s", paths)
- for path in paths:
- with open(os.path.join(path, "maps", "map0", "name"), "r") as uio_file:
- name = uio_file.read()
- log.debug("uio_node name: %s", name.strip())
- if name.strip() == uio_name:
- with open(os.path.join(path, "maps", "map0", "size"), "r") as uio_file:
- size = uio_file.read()
- log.debug("uio_node size: %s", size.strip())
- log.debug("uio_node syspath: %s", path)
- # device = pyudev.Device.from_sys_path(context, path)
- log.debug("got udev device")
- log.debug("device_node: %s size: %s", "/dev/uio0", size.strip())
- return ("/dev/uio0", int(size.strip()))
- return ("", 0)