If olt_ip specified, use host and address to enable voltha olt device
Change-Id: If276c31f2e77db5fca68b704d0191209dd5b2950
diff --git a/src/test/utils/VolthaCtrl.py b/src/test/utils/VolthaCtrl.py
index 7d6e2b5..08e02b8 100644
--- a/src/test/utils/VolthaCtrl.py
+++ b/src/test/utils/VolthaCtrl.py
@@ -447,12 +447,12 @@
if driver_configured:
device_id, status = voltha_device_ids[0], True
else:
- if olt_type.startswith('maple'):
+ if olt_type.startswith('maple') or olt_ip:
if olt_ip:
log.info('Enabling %s' %olt_type)
device_id, status = voltha.enable_device(olt_type, address = olt_ip)
else:
- log.info('OLT IP needs to be specified for maple olt')
+ log.info('OLT IP needs to be specified for %s' %olt_type)
else:
log.info('Enabling OLT instance for %s with mac %s' %(olt_type, olt_mac))
device_id, status = voltha.enable_device(olt_type, olt_mac)