Skip to content

Commit

Permalink
Remove Flex Counter before removing the ENI object
Browse files Browse the repository at this point in the history
Signed-off-by: Vivek Reddy <vkarri@nvidia.com>
  • Loading branch information
vivekrnv committed Aug 22, 2024
1 parent 8b6dbdb commit d4e6f90
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions orchagent/dash/dashorch.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -483,6 +483,9 @@ bool DashOrch::removeEniObject(const string& eni)
SWSS_LOG_ENTER();

EniEntry entry = eni_entries_[eni];

removeEniFromFC(entry.eni_id, eni);

sai_status_t status = sai_dash_eni_api->remove_eni(entry.eni_id);
if (status != SAI_STATUS_SUCCESS)
{
Expand All @@ -499,8 +502,6 @@ bool DashOrch::removeEniObject(const string& eni)
}
}

removeEniFromFC(entry.eni_id, eni);

gCrmOrch->decCrmResUsedCounter(CrmResourceType::CRM_DASH_ENI);

SWSS_LOG_NOTICE("Removed ENI object for %s", eni.c_str());
Expand Down

0 comments on commit d4e6f90

Please sign in to comment.