@@ -290,7 +290,7 @@ def po_speed_dict(po_int_dict, appl_db):
290
290
po_speed_dict = {}
291
291
return po_speed_dict
292
292
293
- def appl_db_portchannel_status_get (appl_db , config_db , po_name , status_type , portchannel_speed_dict ):
293
+ def appl_db_portchannel_status_get (appl_db , config_db , po_name , status_type , portchannel_speed_dict , combined_int_to_vlan_po_dict = None ):
294
294
"""
295
295
Get the port status
296
296
"""
@@ -301,7 +301,10 @@ def appl_db_portchannel_status_get(appl_db, config_db, po_name, status_type, por
301
301
status = portchannel_speed_dict [po_name ]
302
302
return status
303
303
if status_type == "vlan" :
304
- status = "routed"
304
+ if combined_int_to_vlan_po_dict and po_name in combined_int_to_vlan_po_dict .keys ():
305
+ status = "trunk"
306
+ else :
307
+ status = "routed"
305
308
return status
306
309
if status_type == "mtu" :
307
310
status = config_db .get (config_db .CONFIG_DB , po_table_id , status_type )
@@ -388,7 +391,7 @@ class IntfStatus(object):
388
391
appl_db_portchannel_status_get (self .appl_db , self .config_db , po , PORT_MTU_STATUS , self .portchannel_speed_dict ),
389
392
appl_db_portchannel_status_get (self .appl_db , self .config_db , po , PORT_FEC , self .portchannel_speed_dict ),
390
393
appl_db_portchannel_status_get (self .appl_db , self .config_db , po , PORT_ALIAS , self .portchannel_speed_dict ),
391
- appl_db_portchannel_status_get (self .appl_db , self .config_db , po , "vlan" , self .portchannel_speed_dict ),
394
+ appl_db_portchannel_status_get (self .appl_db , self .config_db , po , "vlan" , self .portchannel_speed_dict , self . combined_int_to_vlan_po_dict ),
392
395
appl_db_portchannel_status_get (self .appl_db , self .config_db , po , PORT_OPER_STATUS , self .portchannel_speed_dict ),
393
396
appl_db_portchannel_status_get (self .appl_db , self .config_db , po , PORT_ADMIN_STATUS , self .portchannel_speed_dict ),
394
397
appl_db_portchannel_status_get (self .appl_db , self .config_db , po , PORT_OPTICS_TYPE , self .portchannel_speed_dict ),
0 commit comments