Returns the Device's master.
v2: return the whole master attribute
Signed-off-by: Jan Tluka <jtluka(a)redhat.com>
---
lnst/Slave/InterfaceManager.py | 3 +++
1 file changed, 3 insertions(+)
diff --git a/lnst/Slave/InterfaceManager.py b/lnst/Slave/InterfaceManager.py
index 3d28070..697119a 100644
--- a/lnst/Slave/InterfaceManager.py
+++ b/lnst/Slave/InterfaceManager.py
@@ -593,6 +593,9 @@ class Device(object):
elif if_index not in self._master["other"]:
self._master["other"].append(if_index)
+ def get_master(self):
+ return self._master
+
def del_master(self, if_index):
if self._master["primary"] == if_index:
self._master["primary"] = None
--
2.7.4