You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Enforce the order when the shared headroom pool is enabled (#2729)
What I did
Enforce the order when the shared headroom pool is enabled.
This is to backport #2699 to 202211.
Signed-off-by: Stephen Sun [email protected]
Why I did it
The current flow to enable the shared headroom pool
Configure the shared headroom pool size or over-subscribe ratio
Update lossless buffer profiles with xon == size
Calculate and update the shared headroom pool size.
In step 2, the lossless buffer profiles have been updated to values as if the shared headroom pool is enabled. However, it is enabled only in step 3, which is inconsistent between steps 2 and 3. Therefore, we open the PR to guarantee the order.
The new flow
A user configures the shared headroom pool size or over-subscribe ratio
The dynamic buffer manager invokes the vendor-specific Lua plugin to calculate the shared headroom pool size
This is the step introduced in this PR to guarantee the shared headroom pool will be enabled in advance
On Nvidia platform, a non-zero shared headroom pool is returned in this stage if the user configures the over-subscribe ratio
If a non-zero shared headroom pool is returned, the dynamic buffer manager pushes the shared headroom pool size to APPL_DB.ingress_lossless_pool and blocks until it has been updated into APPL_STATE_DB.ingress_lossless_pool (which indicates the buffer orchagent finishes handling it)
The buffer manager updates the lossless buffer profiles
The buffer manager invokes the Lua plugin to calculate the shared headroom pool size.
The flow continues as normal.
How I verified it
Manually test and regression test
0 commit comments