From 5b18614d39f5cebdd8bf3bf6e5acf3a34f204191 Mon Sep 17 00:00:00 2001 From: Brent Stapleton Date: Fri, 20 Jul 2018 16:07:38 -0700 Subject: uio: mpm: Fixup for opening mboard-regs UIO - 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/python/usrp_mpm/liberiotable.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'mpm/python/usrp_mpm/liberiotable.py') diff --git a/mpm/python/usrp_mpm/liberiotable.py b/mpm/python/usrp_mpm/liberiotable.py index 19226345b..d732eedcb 100644 --- a/mpm/python/usrp_mpm/liberiotable.py +++ b/mpm/python/usrp_mpm/liberiotable.py @@ -47,7 +47,7 @@ class LiberioDispatcherTable(object): self.poke32(addr, data) # Poke reg for destination channel try: - with self._regs.open(): + with self._regs: poke_and_trace( 0 + 4 * sid.dst_ep, dma_channel, -- cgit v1.2.3