Skip to content

Commit

Permalink
Wait until all the attribs are recieved
Browse files Browse the repository at this point in the history
Signed-off-by: Vivek Reddy Karri <vkarri@nvidia.com>
  • Loading branch information
vivekrnv committed Aug 31, 2022
1 parent a4b8992 commit 9700711
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions orchagent/portsorch.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2615,6 +2615,15 @@ bool PortsOrch::addPort(const set<int> &lane_set, uint32_t speed, int an, string
{
SWSS_LOG_ENTER();

if (!speed || lane_set.empty())
{
/*
speed and lane list are mandatory attributes for the initial create_port call
This check is required because the incoming notifs may not be atomic
*/
return true;
}

vector<uint32_t> lanes(lane_set.begin(), lane_set.end());

sai_attribute_t attr;
Expand Down

0 comments on commit 9700711

Please sign in to comment.