diff options
-rw-r--r-- | pychassisctl/chassis_control.py | 7 | ||||
-rw-r--r-- | pyfanctl/fan_control.py | 6 | ||||
-rw-r--r-- | pyflashbmc/bmc_update.py | 7 | ||||
-rw-r--r-- | pyinventorymgr/inventory_items.py | 11 | ||||
-rw-r--r-- | pysensormgr/sensor_manager2.py | 6 | ||||
-rw-r--r-- | pysystemmgr/system_manager.py | 6 |
6 files changed, 21 insertions, 22 deletions
diff --git a/pychassisctl/chassis_control.py b/pychassisctl/chassis_control.py index 20532c9..1e57936 100644 --- a/pychassisctl/chassis_control.py +++ b/pychassisctl/chassis_control.py @@ -34,10 +34,9 @@ class ChassisControlObject(DbusProperties, DbusObjectManager): return uuid def __init__(self, bus, name): - self.dbus_objects = {} - DbusProperties.__init__(self) - DbusObjectManager.__init__(self) - dbus.service.Object.__init__(self, bus, name) + super(ChassisControlObject, self).__init__( + conn=bus, + object_path=name) ## load utilized objects self.dbus_objects = { 'power_control': { diff --git a/pyfanctl/fan_control.py b/pyfanctl/fan_control.py index 85163e8..2bfdd80 100644 --- a/pyfanctl/fan_control.py +++ b/pyfanctl/fan_control.py @@ -24,9 +24,9 @@ FAN_IFACE = 'org.openbmc.SensorValue' class FanControl(DbusProperties, DbusObjectManager): def __init__(self, bus, name): - DbusProperties.__init__(self) - DbusObjectManager.__init__(self) - dbus.service.Object.__init__(self, bus, name) + super(FanControl, self).__init__( + conn=bus, + object_path=name) self.Set(IFACE_NAME, "floor", 250) self.Set(IFACE_NAME, "ceiling", 255) self.fan_intf = [] diff --git a/pyflashbmc/bmc_update.py b/pyflashbmc/bmc_update.py index e761fff..94c36d6 100644 --- a/pyflashbmc/bmc_update.py +++ b/pyflashbmc/bmc_update.py @@ -29,10 +29,9 @@ def doExtract(members, files): class BmcFlashControl(DbusProperties, DbusObjectManager): def __init__(self, bus, name): - self.dbus_objects = {} - DbusProperties.__init__(self) - DbusObjectManager.__init__(self) - dbus.service.Object.__init__(self, bus, name) + super(BmcFlashControl, self).__init__( + conn=bus, + object_path=name) self.Set(DBUS_NAME, "status", "Idle") self.Set(DBUS_NAME, "filename", "") diff --git a/pyinventorymgr/inventory_items.py b/pyinventorymgr/inventory_items.py index 456c2f3..16ae6d0 100644 --- a/pyinventorymgr/inventory_items.py +++ b/pyinventorymgr/inventory_items.py @@ -26,15 +26,16 @@ else: class Inventory(DbusProperties, DbusObjectManager): def __init__(self, bus, name): - DbusProperties.__init__(self) - DbusObjectManager.__init__(self) - dbus.service.Object.__init__(self, bus, name) + super(Inventory, self).__init__( + conn=bus, + object_path=name) class InventoryItem(DbusProperties): def __init__(self, bus, name, data): - DbusProperties.__init__(self) - dbus.service.Object.__init__(self, bus, name) + super(InventoryItem, self).__init__( + conn=bus, + object_path=name) self.name = name diff --git a/pysensormgr/sensor_manager2.py b/pysensormgr/sensor_manager2.py index 9a4bc08..4095618 100644 --- a/pysensormgr/sensor_manager2.py +++ b/pysensormgr/sensor_manager2.py @@ -19,9 +19,9 @@ OBJ_PATH = '/org/openbmc/sensors' class SensorManager(DbusProperties, DbusObjectManager): def __init__(self, bus, name): - DbusProperties.__init__(self) - DbusObjectManager.__init__(self) - dbus.service.Object.__init__(self, bus, name) + super(SensorManager, self).__init__( + conn=bus, + object_path=name) @dbus.service.method( DBUS_NAME, in_signature='ss', out_signature='') diff --git a/pysystemmgr/system_manager.py b/pysystemmgr/system_manager.py index fe786e5..716c85d 100644 --- a/pysystemmgr/system_manager.py +++ b/pysystemmgr/system_manager.py @@ -19,9 +19,9 @@ INTF_ITEM = 'org.openbmc.InventoryItem' class SystemManager(DbusProperties, DbusObjectManager): def __init__(self, bus, obj_name): - DbusProperties.__init__(self) - DbusObjectManager.__init__(self) - dbus.service.Object.__init__(self, bus, obj_name) + super(SystemManager, self).__init__( + conn=bus, + object_path=obj_name) self.bus = bus bus.add_signal_receiver( |