[Dynamic buffer calculation][Mellanox] Enhance the logic to identify buffer pools and profiles#2498
Merged
neethajohn merged 2 commits intosonic-net:masterfrom Nov 2, 2022
Conversation
Collaborator
Author
|
/azpw run |
Collaborator
|
/AzurePipelines run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
Collaborator
Author
|
/azpw run |
Collaborator
|
/AzurePipelines run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
Collaborator
Author
|
/azpw run |
Collaborator
|
/AzurePipelines run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
Collaborator
Author
|
Failed by the following issue which is not relevant to the PR. |
Collaborator
Author
I see the following error message from the vs switch In the test case, there is no logic to remove the vlan interface. Looks like it should be constantly failing. I was just curious how the test got passed previously... |
neethajohn
reviewed
Oct 31, 2022
Signed-off-by: Stephen Sun <stephens@nvidia.com>
b5011e3 to
e0ab764
Compare
Collaborator
Author
|
another error relevant to WR |
Collaborator
Author
|
/azpw run |
Collaborator
|
/AzurePipelines run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
Collaborator
Author
|
Test issue fixed by #2504 |
Collaborator
Author
|
Again |
Collaborator
Author
|
/azpw run |
Collaborator
|
/AzurePipelines run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
neethajohn
approved these changes
Nov 2, 2022
yxieca
pushed a commit
that referenced
this pull request
Nov 3, 2022
…buffer pools and profiles (#2498) Signed-off-by: Stephen Sun <stephens@nvidia.com> What I did Originally, it was assumed the names of all the buffer pools follow the community buffer pool name convention ({ingress|egress}_{lossless|lossy}_pool). The heuristic algorithm to identify buffer pools and profiles was designed based on the assumption. However, some users can define the buffer pool names in other ways, which breaks the logic in the Lua plugin and introduces degradation, the pool sizes of those pools can not be generated the additional reserved memory for lossy PG can not be calculated In this PR, the logic is improved to tolerate the case. Signed-off-by: Stephen Sun stephens@nvidia.com How I verified it Manually and regression test. It has been covered by regression test and vs test. No new test case is required. Details if related Separate the buffer pools into two tables according to the direction. Iterate all the profiles, generating and recording the type (lossless/lossy) for each ingress profile which is identified by checking the pool it references Identify buffer profiles for lossy PG by checking the type (lossless/lossy) generated in 2 instead of the hardcoded name ingress_lossy_profile
7 tasks
Janetxxx
pushed a commit
to Janetxxx/sonic-swss
that referenced
this pull request
Nov 10, 2025
…buffer pools and profiles (sonic-net#2498) Signed-off-by: Stephen Sun <stephens@nvidia.com> What I did Originally, it was assumed the names of all the buffer pools follow the community buffer pool name convention ({ingress|egress}_{lossless|lossy}_pool). The heuristic algorithm to identify buffer pools and profiles was designed based on the assumption. However, some users can define the buffer pool names in other ways, which breaks the logic in the Lua plugin and introduces degradation, the pool sizes of those pools can not be generated the additional reserved memory for lossy PG can not be calculated In this PR, the logic is improved to tolerate the case. Signed-off-by: Stephen Sun stephens@nvidia.com How I verified it Manually and regression test. It has been covered by regression test and vs test. No new test case is required. Details if related Separate the buffer pools into two tables according to the direction. Iterate all the profiles, generating and recording the type (lossless/lossy) for each ingress profile which is identified by checking the pool it references Identify buffer profiles for lossy PG by checking the type (lossless/lossy) generated in 2 instead of the hardcoded name ingress_lossy_profile
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What I did
Originally, it was assumed the names of all the buffer pools follow the community buffer pool name convention (
{ingress|egress}_{lossless|lossy}_pool). The heuristic algorithm to identify buffer pools and profiles was designed based on the assumption.However, some users can define the buffer pool names in other ways, which breaks the logic in the Lua plugin and introduces degradation,
In this PR, the logic is improved to tolerate the case.
Signed-off-by: Stephen Sun stephens@nvidia.com
Why I did it
How I verified it
Manually and regression test.
It has been covered by regression test and vs test. No new test case is required.
Details if related
2instead of the hardcoded nameingress_lossy_profile