diff --git a/sonic-xcvrd/scripts/xcvrd b/sonic-xcvrd/scripts/xcvrd index 48f110a73..0732d843a 100644 --- a/sonic-xcvrd/scripts/xcvrd +++ b/sonic-xcvrd/scripts/xcvrd @@ -254,23 +254,11 @@ def post_port_sfp_info_to_db(logical_port_name, table, transceiver_dict, try: port_info_dict = _wrapper_get_transceiver_info(physical_port) if port_info_dict is not None: + port_info_dict['application_advertisement'] = port_info_dict.get('application_advertisement', 'N/A') + transceiver_dict[physical_port]=port_info_dict - fvs = swsscommon.FieldValuePairs([('type', port_info_dict['type']), - ('hardware_rev', port_info_dict['hardware_rev']), - ('serial', port_info_dict['serial']), - ('manufacturer', port_info_dict['manufacturer']), - ('model', port_info_dict['model']), - ('vendor_oui',port_info_dict['vendor_oui']), - ('vendor_date',port_info_dict['vendor_date']), - ('connector',port_info_dict['connector']), - ('encoding',port_info_dict['encoding']), - ('ext_identifier',port_info_dict['ext_identifier']), - ('ext_rateselect_compliance',port_info_dict['ext_rateselect_compliance']), - ('cable_type',port_info_dict['cable_type']), - ('cable_length',port_info_dict['cable_length']), - ('specification_compliance',port_info_dict['specification_compliance']), - ('nominal_bit_rate',port_info_dict['nominal_bit_rate']), - ('application_advertisement',port_info_dict['application_advertisement'] if 'application_advertisement' in port_info_dict else 'N/A')]) + + fvs = swsscommon.FieldValuePairs(list(port_info_dict.items())) table.set(port_name, fvs) else: return SFP_EEPROM_NOT_READY