Skip to content

Commit

Permalink
[vslib]: Fix missing MACsec Create Port action (sonic-net#770)
Browse files Browse the repository at this point in the history
Missing MACsec Create Port action in SwitchStateBase::create. This bug will cause MACsec SC Crate action fail.

Signed-off-by: Ze Gan <ganze718@gmail.com>
  • Loading branch information
Pterosaur authored Jan 22, 2021
1 parent 02d0371 commit aaf5b98
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions vslib/src/SwitchStateBase.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,13 @@ sai_status_t SwitchStateBase::create(
return createHostif(object_id, switch_id, attr_count, attr_list);
}

if (object_type == SAI_OBJECT_TYPE_MACSEC_PORT)
{
sai_object_id_t object_id;
sai_deserialize_object_id(serializedObjectId, object_id);
return createMACsecPort(object_id, switch_id, attr_count, attr_list);
}

if (object_type == SAI_OBJECT_TYPE_MACSEC_SC)
{
sai_object_id_t object_id;
Expand Down

0 comments on commit aaf5b98

Please sign in to comment.