Skip to content

Commit

Permalink
Update tests and transfer attributes
Browse files Browse the repository at this point in the history
  • Loading branch information
kcudnik committed Sep 2, 2023
1 parent 3de3a94 commit b0b55ce
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
12 changes: 12 additions & 0 deletions meta/SaiSerialize.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -492,6 +492,18 @@ sai_status_t transfer_attribute(
RETURN_ON_ERROR(transfer_list(src_attr.value.ipprefixlist, dst_attr.value.ipprefixlist, countOnly));
break;

case SAI_ATTR_VALUE_TYPE_PORT_FREQUENCY_OFFSET_PPM_LIST:
RETURN_ON_ERROR(transfer_list(src_attr.value.portfrequencyoffsetppmlist, dst_attr.value.portfrequencyoffsetppmlist, countOnly));
break;

case SAI_ATTR_VALUE_TYPE_PORT_SNR_LIST:
RETURN_ON_ERROR(transfer_list(src_attr.value.portsnrlist, dst_attr.value.portsnrlist, countOnly));
break;

case SAI_ATTR_VALUE_TYPE_ACL_CHAIN_LIST:
RETURN_ON_ERROR(transfer_list(src_attr.value.aclchainlist, dst_attr.value.aclchainlist, countOnly));
break;

default:
SWSS_LOG_THROW("sai attr value %s is not implemented, FIXME", sai_serialize_attr_value_type(serialization_type).c_str());
}
Expand Down
3 changes: 3 additions & 0 deletions unittest/meta/TestSaiSerialize.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,9 @@ TEST(SaiSerialize, sai_serialize_attr_value)
case SAI_ATTR_VALUE_TYPE_SEGMENT_LIST:
case SAI_ATTR_VALUE_TYPE_TLV_LIST:
case SAI_ATTR_VALUE_TYPE_MAP_LIST:
case SAI_ATTR_VALUE_TYPE_PORT_FREQUENCY_OFFSET_PPM_LIST:
case SAI_ATTR_VALUE_TYPE_PORT_SNR_LIST:
case SAI_ATTR_VALUE_TYPE_ACL_CHAIN_LIST:
continue;

default:
Expand Down

0 comments on commit b0b55ce

Please sign in to comment.