Skip to content

[202012] [cherry-pick] Apply DSCP_TO_TC_MAP from PORT_QOS_MAP|global to switch level#2328

Merged
bingwang-ms merged 2 commits intosonic-net:202012from
bingwang-ms:apply_azure_to_switch_202012
Jun 27, 2022
Merged

[202012] [cherry-pick] Apply DSCP_TO_TC_MAP from PORT_QOS_MAP|global to switch level#2328
bingwang-ms merged 2 commits intosonic-net:202012from
bingwang-ms:apply_azure_to_switch_202012

Conversation

@bingwang-ms
Copy link
Contributor

What I did
This PR is to cherry-pick #2314 to 202012 branch after resolving conflicts.

This PR is to update the code for applying switch level DSCP_TO_TC_MAP.
After PR sonic-net/sonic-buildimage#10565, there will be two DSCP_TO_TC_MAP

  • DSCP_TO_TC_MAP|AZURE is the default map, which is used at port level and switch level
  • DSCP_TO_TC_MAP|AZURE_TUNNEL is used to remap the priority of tunnel traffic in dualtor deployment

To address the issue, an entry PORT_QOS_MAP|global will be added into config_db

"PORT_QOS_MAP": {
        "global": {
            "dscp_to_tc_map": "[DSCP_TO_TC_MAP|AZURE]"
        }
}

The entry will be consumed by qosorch, and the specified map will be applied to switch.

Why I did it
This change is to ensure the correct DSCP_TO_TC_MAP is applied to switch level.

How I verified it
Verified by a new test case test_dscp_to_tc_map_applied_to_switch

collected 2 items                                                                                                                                                                                     

test_qos_map.py::TestDscpToTcMap::test_dscp_to_tc_map_applied_to_switch PASSED                                                                                                                  [ 50%]
test_qos_map.py::test_nonflaky_dummy PASSED                                                                                                                                                     [100%]

Details if related

Signed-off-by: bingwang <wang.bing@microsoft.com>
@bingwang-ms bingwang-ms merged commit 475ae19 into sonic-net:202012 Jun 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants