ADTRAN ONU: fix import path to KPI shared library
Change-Id: I855ad856e9c879910a05b1850fcb1cf5947f2ddf
diff --git a/voltha/adapters/adtran_onu/adtran_onu.py b/voltha/adapters/adtran_onu/adtran_onu.py
index 1e05f02..6ee3c1b 100755
--- a/voltha/adapters/adtran_onu/adtran_onu.py
+++ b/voltha/adapters/adtran_onu/adtran_onu.py
@@ -40,7 +40,7 @@
device_handler_class=AdtranOnuHandler,
name='adtran_onu',
vendor='Adtran Inc.',
- version='0.12',
+ version='0.13',
device_type='adtran_onu',
vendor_id='ADTN',
accepts_add_remove_flow_updates=False), # TODO: Support flow-mods
diff --git a/voltha/adapters/adtran_onu/adtran_onu_handler.py b/voltha/adapters/adtran_onu/adtran_onu_handler.py
index ff69b22..c5a9803 100644
--- a/voltha/adapters/adtran_onu/adtran_onu_handler.py
+++ b/voltha/adapters/adtran_onu/adtran_onu_handler.py
@@ -23,7 +23,7 @@
from omci.omci import OMCI
from voltha.extensions.alarms.adapter_alarms import AdapterAlarms
-from voltha.extensions.pki.onu.onu_pm_metrics import OnuPmMetrics
+from voltha.extensions.kpi.onu.onu_pm_metrics import OnuPmMetrics
from uuid import uuid4
from twisted.internet import reactor
@@ -263,6 +263,15 @@
# Start things up for this ONU Handler.
self.enabled = True
+ # reference of uni_port is required when re-enabling the device if
+ # it was disabled previously
+ # Need to query ONU for number of supported uni ports
+ # For now, temporarily set number of ports to 1 - port #2
+ parent_device = self.adapter_agent.get_device(device.parent_id)
+ self.logical_device_id = parent_device.parent_id
+ assert self.logical_device_id, 'Invalid logical device ID'
+ self.adapter_agent.update_device(device)
+
############################################################################
# Setup PM configuration for this device
# Pass in ONU specific options
@@ -278,15 +287,6 @@
self.log.info("initial-pm-config", pm_config=pm_config)
self.adapter_agent.update_device_pm_config(pm_config, init=True)
- # reference of uni_port is required when re-enabling the device if
- # it was disabled previously
- # Need to query ONU for number of supported uni ports
- # For now, temporarily set number of ports to 1 - port #2
- parent_device = self.adapter_agent.get_device(device.parent_id)
- self.logical_device_id = parent_device.parent_id
- assert self.logical_device_id, 'Invalid logical device ID'
- self.adapter_agent.update_device(device)
-
############################################################################
# Setup Alarm handler
self.alarms = AdapterAlarms(self.adapter_agent, device.id, self.logical_device_id)