Skip to content

Commit 28ad5cb

Browse files
ayurkiv-nvdamssonicbld
authored andcommitted
[Mellanox] update buffers and align QoS to add support for DSCP remapping (for Dual-Tor on t1) for Mellanox-SN4700-O8C48 (#19999)
* [Mellanox] update buffers and align QoS to add support for DSCP remapping (for Dual-Tor on t1) for Mellanox-SN4700-O8C48 Signed-off-by: Andriy Yurkiv <ayurkiv@nvidia.com>
1 parent 3b4097c commit 28ad5cb

File tree

4 files changed

+92
-10
lines changed

4 files changed

+92
-10
lines changed

device/mellanox/x86_64-mlnx_msn4700-r0/Mellanox-SN4700-O8C48/buffers_defaults_t0.j2

+19-4
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{#
2-
Copyright (c) 2022-2023 NVIDIA CORPORATION & AFFILIATES.
2+
Copyright (c) 2022-2024 NVIDIA CORPORATION & AFFILIATES.
33
Apache-2.0
44
Licensed under the Apache License, Version 2.0 (the "License");
55
you may not use this file except in compliance with the License.
@@ -12,21 +12,36 @@
1212
limitations under the License.
1313
#}
1414
{% set default_cable = '5m' %}
15-
{% set ingress_lossless_pool_size = '44433408' %}
16-
{% set ingress_lossless_pool_xoff = '9576448' %}
15+
{%- if ((SYSTEM_DEFAULTS is defined) and ('tunnel_qos_remap' in SYSTEM_DEFAULTS) and (SYSTEM_DEFAULTS['tunnel_qos_remap']['status'] == 'enabled')) -%}
16+
{% set ingress_lossless_pool_size = '50397184' %}
17+
{% set ingress_lossless_pool_xoff = '2990080' %}
1718
{% set egress_lossless_pool_size = '60817392' %}
18-
{% set egress_lossy_pool_size = '44433408' %}
19+
{% set egress_lossy_pool_size = '50397184' %}
20+
{%- else -%}
21+
{% set ingress_lossless_pool_size = '51748864' %}
22+
{% set ingress_lossless_pool_xoff = '2260992' %}
23+
{% set egress_lossless_pool_size = '60817392' %}
24+
{% set egress_lossy_pool_size = '51748864' %}
25+
{%- endif -%}
1926

2027
{% import 'buffers_defaults_objects.j2' as defs with context %}
2128

2229
{%- macro generate_buffer_pool_and_profiles_with_inactive_ports(port_names_inactive) %}
2330
{{ defs.generate_buffer_pool_and_profiles_with_inactive_ports(port_names_inactive) }}
2431
{%- endmacro %}
2532

33+
{%- macro generate_queue_buffers_with_extra_lossless_queues_with_inactive_ports(port_names_active, port_names_extra_queues, port_names_inactive) %}
34+
{{ defs.generate_queue_buffers_with_extra_lossless_queues(port_names_active, port_names_extra_queues, port_names_inactive) }}
35+
{%- endmacro %}
36+
2637
{%- macro generate_profile_lists_with_inactive_ports(port_names_active, port_names_inactive) %}
2738
{{ defs.generate_profile_lists(port_names_active, port_names_inactive) }}
2839
{%- endmacro %}
2940

41+
{%- macro generate_pg_profiles_with_extra_lossless_pgs_with_inactive_ports(port_names_active, port_names_extra_pgs, port_names_inactive) %}
42+
{{ defs.generate_pg_profiles_with_extra_lossless_pgs(port_names_active, port_names_extra_pgs, port_names_inactive) }}
43+
{%- endmacro %}
44+
3045
{%- macro generate_queue_buffers_with_inactive_ports(port_names_active, port_names_inactive) %}
3146
{{ defs.generate_queue_buffers(port_names_active, port_names_inactive) }}
3247
{%- endmacro %}

device/mellanox/x86_64-mlnx_msn4700-r0/Mellanox-SN4700-O8C48/buffers_defaults_t1.j2

+19-4
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{#
2-
Copyright (c) 2022-2023 NVIDIA CORPORATION & AFFILIATES.
2+
Copyright (c) 2022-2024 NVIDIA CORPORATION & AFFILIATES.
33
Apache-2.0
44
Licensed under the Apache License, Version 2.0 (the "License");
55
you may not use this file except in compliance with the License.
@@ -12,10 +12,17 @@
1212
limitations under the License.
1313
#}
1414
{% set default_cable = '300m' %}
15-
{% set ingress_lossless_pool_size = '44089344' %}
16-
{% set ingress_lossless_pool_xoff = '9920512' %}
15+
{%- if ((SYSTEM_DEFAULTS is defined) and ('tunnel_qos_remap' in SYSTEM_DEFAULTS) and (SYSTEM_DEFAULTS['tunnel_qos_remap']['status'] == 'enabled')) -%}
16+
{% set ingress_lossless_pool_size = '43859968' %}
17+
{% set ingress_lossless_pool_xoff = '8282112' %}
1718
{% set egress_lossless_pool_size = '60817392' %}
18-
{% set egress_lossy_pool_size = '44089344' %}
19+
{% set egress_lossy_pool_size = '43859968' %}
20+
{%- else -%}
21+
{% set ingress_lossless_pool_size = '47792128' %}
22+
{% set ingress_lossless_pool_xoff = '6217728 ' %}
23+
{% set egress_lossless_pool_size = '60817392' %}
24+
{% set egress_lossy_pool_size = '47792128 ' %}
25+
{%- endif -%}
1926

2027
{% import 'buffers_defaults_objects.j2' as defs with context %}
2128

@@ -27,10 +34,18 @@
2734
{{ defs.generate_profile_lists(port_names_active, port_names_inactive) }}
2835
{%- endmacro %}
2936

37+
{%- macro generate_queue_buffers_with_extra_lossless_queues_with_inactive_ports(port_names_active, port_names_extra_queues, port_names_inactive) %}
38+
{{ defs.generate_queue_buffers_with_extra_lossless_queues(port_names_active, port_names_extra_queues, port_names_inactive) }}
39+
{%- endmacro %}
40+
3041
{%- macro generate_queue_buffers_with_inactive_ports(port_names_active, port_names_inactive) %}
3142
{{ defs.generate_queue_buffers(port_names_active, port_names_inactive) }}
3243
{%- endmacro %}
3344

45+
{%- macro generate_pg_profiles_with_extra_lossless_pgs_with_inactive_ports(port_names_active, port_names_extra_pgs, port_names_inactive) %}
46+
{{ defs.generate_pg_profiles_with_extra_lossless_pgs(port_names_active, port_names_extra_pgs, port_names_inactive) }}
47+
{%- endmacro %}
48+
3449
{%- macro generate_pg_profiles_with_inactive_ports(port_names_active, port_names_inactive) %}
3550
{{ defs.generate_pg_profiles(port_names_active, port_names_inactive) }}
3651
{%- endmacro %}

device/mellanox/x86_64-mlnx_msn4700-r0/Mellanox-SN4700-O8C48/pg_profile_lookup.ini

-1
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
##
2+
## Copyright (c) 2024 NVIDIA CORPORATION & AFFILIATES.
3+
## Apache-2.0
4+
##
5+
## Licensed under the Apache License, Version 2.0 (the "License");
6+
## you may not use this file except in compliance with the License.
7+
## You may obtain a copy of the License at
8+
##
9+
## http://www.apache.org/licenses/LICENSE-2.0
10+
##
11+
## Unless required by applicable law or agreed to in writing, software
12+
## distributed under the License is distributed on an "AS IS" BASIS,
13+
## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
## See the License for the specific language governing permissions and
15+
## limitations under the License.
16+
##
17+
# PG lossless profiles.
18+
# speed cable size xon xoff threshold
19+
10000 5m 19456 19456 16384 0
20+
25000 5m 19456 19456 17408 0
21+
40000 5m 19456 19456 19456 0
22+
50000 5m 19456 19456 21504 0
23+
100000 5m 19456 19456 37888 0
24+
200000 5m 19456 19456 43008 0
25+
400000 5m 38912 38912 73728 0
26+
10000 40m 19456 19456 16384 0
27+
25000 40m 19456 19456 18432 0
28+
40000 40m 19456 19456 21504 0
29+
50000 40m 19456 19456 23552 0
30+
100000 40m 19456 19456 43008 0
31+
200000 40m 19456 19456 51200 0
32+
400000 40m 38912 38912 91136 0
33+
10000 300m 19456 19456 19456 0
34+
25000 300m 19456 19456 26624 0
35+
40000 300m 19456 19456 34816 0
36+
50000 300m 19456 19456 40960 0
37+
100000 300m 19456 19456 75776 0
38+
200000 300m 19456 19456 118784 0
39+
400000 300m 38912 38912 225280 0
40+
10000 1500m 19456 19456 35840 0
41+
25000 1500m 19456 19456 65536 0
42+
40000 1500m 19456 19456 96256 0
43+
50000 1500m 19456 19456 117760 0
44+
100000 1500m 19456 19456 230400 0
45+
200000 1500m 19456 19456 427008 0
46+
400000 1500m 38912 38912 427008 0
47+
10000 2000m 19456 19456 41984 0
48+
25000 2000m 19456 19456 80896 0
49+
40000 2000m 19456 19456 121856 0
50+
50000 2000m 19456 19456 149504 0
51+
100000 2000m 19456 19456 293888 0
52+
200000 2000m 19456 19456 555008 0
53+
400000 2000m 38912 38912 555008 0
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
../../x86_64-mlnx_msn2700-r0/ACS-MSN2700/qos.json.j2
1+
../../x86_64-mlnx_msn4600c-r0/Mellanox-SN4600C-C64/qos.json.j2

0 commit comments

Comments
 (0)