Skip to content

Commit

Permalink
Support different DSCP_TO_TC_MAP for T1 in dualtor deployment (#11569)
Browse files Browse the repository at this point in the history
* Support different DSCP_TO_TC_MAP for T1 in dualtor deployment
  • Loading branch information
bingwang-ms authored and yxieca committed Aug 8, 2022
1 parent bc300b4 commit fda1290
Show file tree
Hide file tree
Showing 9 changed files with 208 additions and 89 deletions.

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -51,11 +51,7 @@
{%- endmacro %}

{% import 'buffers_extra_queues.j2' as defs1 with context %}
{% import 'buffers_extra_pgs.j2' as defs2 with context %}

{%- macro generate_queue_buffers_with_extra_lossless_queues(port_names, port_names_require_extra_buffer) %}
{{ defs1.generate_queue_buffers_with_extra_lossless_queues(port_names, port_names_require_extra_buffer) }}
{%- endmacro %}
{%- macro generate_pg_buffers_with_extra_lossy_pgs(port_names, port_names_require_no_extra_pgs) %}
{{ defs2.generate_pg_buffers_with_extra_lossy_pgs(port_names, port_names_require_no_extra_pgs) }}
{%- endmacro %}
67 changes: 67 additions & 0 deletions device/common/profiles/th2/7260/BALANCED/qos.json.j2
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
{% if ('type' in DEVICE_METADATA['localhost'] and DEVICE_METADATA['localhost']['type'] == 'LeafRouter') %}
{% set different_dscp_to_tc_map = true %}
{%- macro generate_dscp_to_tc_map() %}
"DSCP_TO_TC_MAP": {
"AZURE": {
Expand Down Expand Up @@ -66,6 +67,72 @@
"61": "1",
"62": "1",
"63": "1"
},
"AZURE_UPLINK": {
"0" : "1",
"1" : "1",
"2" : "1",
"3" : "3",
"4" : "4",
"5" : "1",
"6" : "1",
"7" : "1",
"8" : "0",
"9" : "1",
"10": "1",
"11": "1",
"12": "1",
"13": "1",
"14": "1",
"15": "1",
"16": "1",
"17": "1",
"18": "1",
"19": "1",
"20": "1",
"21": "1",
"22": "1",
"23": "1",
"24": "1",
"25": "1",
"26": "1",
"27": "1",
"28": "1",
"29": "1",
"30": "1",
"31": "1",
"32": "1",
"33": "1",
"34": "1",
"35": "1",
"36": "1",
"37": "1",
"38": "1",
"39": "1",
"40": "1",
"41": "1",
"42": "1",
"43": "1",
"44": "1",
"45": "1",
"46": "5",
"47": "1",
"48": "7",
"49": "1",
"50": "1",
"51": "1",
"52": "1",
"53": "1",
"54": "1",
"55": "1",
"56": "1",
"57": "1",
"58": "1",
"59": "1",
"60": "1",
"61": "1",
"62": "1",
"63": "1"
}
},
{%- endmacro %}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,11 +51,8 @@
{%- endmacro %}

{% import 'buffers_extra_queues.j2' as defs1 with context %}
{% import 'buffers_extra_pgs.j2' as defs2 with context %}

{%- macro generate_queue_buffers_with_extra_lossless_queues(port_names, port_names_require_extra_buffer) %}
{{ defs1.generate_queue_buffers_with_extra_lossless_queues(port_names, port_names_require_extra_buffer) }}
{%- endmacro %}
{%- macro generate_pg_buffers_with_extra_lossy_pgs(port_names, port_names_require_no_extra_pgs) %}
{{ defs2.generate_pg_buffers_with_extra_lossy_pgs(port_names, port_names_require_no_extra_pgs) }}
{%- endmacro %}

66 changes: 66 additions & 0 deletions device/common/profiles/th2/7260/RDMA-CENTRIC/qos.json.j2
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,72 @@
"61": "1",
"62": "1",
"63": "1"
},
"AZURE_UPLINK": {
"0" : "1",
"1" : "1",
"2" : "1",
"3" : "3",
"4" : "4",
"5" : "1",
"6" : "1",
"7" : "1",
"8" : "0",
"9" : "1",
"10": "1",
"11": "1",
"12": "1",
"13": "1",
"14": "1",
"15": "1",
"16": "1",
"17": "1",
"18": "1",
"19": "1",
"20": "1",
"21": "1",
"22": "1",
"23": "1",
"24": "1",
"25": "1",
"26": "1",
"27": "1",
"28": "1",
"29": "1",
"30": "1",
"31": "1",
"32": "1",
"33": "1",
"34": "1",
"35": "1",
"36": "1",
"37": "1",
"38": "1",
"39": "1",
"40": "1",
"41": "1",
"42": "1",
"43": "1",
"44": "1",
"45": "1",
"46": "5",
"47": "1",
"48": "7",
"49": "1",
"50": "1",
"51": "1",
"52": "1",
"53": "1",
"54": "1",
"55": "1",
"56": "1",
"57": "1",
"58": "1",
"59": "1",
"60": "1",
"61": "1",
"62": "1",
"63": "1"
}
},
{%- endmacro %}
Expand Down
4 changes: 0 additions & 4 deletions files/build_templates/buffers_config.j2
Original file line number Diff line number Diff line change
Expand Up @@ -172,10 +172,6 @@ def
{{ defs.generate_pg_profiles_with_extra_lossless_pgs_with_inactive_ports(port_names_active, port_names_extra_queues, port_names_inactive) }},
{% elif defs.generate_pg_profiles_with_inactive_ports is defined %}
{{ defs.generate_pg_profiles_with_inactive_ports(port_names_active, port_names_inactive) }},
{% elif (defs.generate_pg_buffers_with_extra_lossy_pgs is defined) and (port_names_extra_queues != '') %}
{{ defs.generate_pg_buffers_with_extra_lossy_pgs(port_names_active, port_names_extra_queues) }}
{% elif (defs.generate_pg_buffers_with_extra_lossy_pgs_with_inactive_ports is defined) and (port_names_extra_queues != '') %}
{{ defs.generate_pg_buffers_with_extra_lossy_pgs_with_inactive_ports(port_names_active, port_names_extra_queues, port_names_inactive) }}
{% elif defs.generate_pg_profils is defined %}
{{ defs.generate_pg_profils(port_names_active) }}
{% else %}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -112,21 +112,9 @@
"Ethernet0|0": {
"profile" : "ingress_lossy_profile"
},
"Ethernet0|2": {
"profile" : "ingress_lossy_profile"
},
"Ethernet0|6": {
"profile" : "ingress_lossy_profile"
},
"Ethernet4|0": {
"profile" : "ingress_lossy_profile"
},
"Ethernet4|2": {
"profile" : "ingress_lossy_profile"
},
"Ethernet4|6": {
"profile" : "ingress_lossy_profile"
},
"Ethernet144|0": {
"profile" : "ingress_lossy_profile"
},
Expand All @@ -136,21 +124,9 @@
"Ethernet16|0": {
"profile" : "ingress_lossy_profile"
},
"Ethernet16|2": {
"profile" : "ingress_lossy_profile"
},
"Ethernet16|6": {
"profile" : "ingress_lossy_profile"
},
"Ethernet20|0": {
"profile" : "ingress_lossy_profile"
},
"Ethernet20|2": {
"profile" : "ingress_lossy_profile"
},
"Ethernet20|6": {
"profile" : "ingress_lossy_profile"
},
"Ethernet152|0": {
"profile" : "ingress_lossy_profile"
},
Expand All @@ -160,21 +136,9 @@
"Ethernet64|0": {
"profile" : "ingress_lossy_profile"
},
"Ethernet64|2": {
"profile" : "ingress_lossy_profile"
},
"Ethernet64|6": {
"profile" : "ingress_lossy_profile"
},
"Ethernet68|0": {
"profile" : "ingress_lossy_profile"
},
"Ethernet68|2": {
"profile" : "ingress_lossy_profile"
},
"Ethernet68|6": {
"profile" : "ingress_lossy_profile"
},
"Ethernet168|0": {
"profile" : "ingress_lossy_profile"
},
Expand All @@ -184,21 +148,9 @@
"Ethernet80|0": {
"profile" : "ingress_lossy_profile"
},
"Ethernet80|2": {
"profile" : "ingress_lossy_profile"
},
"Ethernet80|6": {
"profile" : "ingress_lossy_profile"
},
"Ethernet84|0": {
"profile" : "ingress_lossy_profile"
},
"Ethernet84|2": {
"profile" : "ingress_lossy_profile"
},
"Ethernet84|6": {
"profile" : "ingress_lossy_profile"
},
"Ethernet180|0": {
"profile" : "ingress_lossy_profile"
},
Expand Down
Loading

0 comments on commit fda1290

Please sign in to comment.