diff --git a/device/arista/x86_64-arista_7050cx3_32s/Arista-7050CX3-32S-C32/config.bcm.j2 b/device/arista/x86_64-arista_7050cx3_32s/Arista-7050CX3-32S-C32/config.bcm.j2 index 6cc4540921e4..6da9bc47c401 100644 --- a/device/arista/x86_64-arista_7050cx3_32s/Arista-7050CX3-32S-C32/config.bcm.j2 +++ b/device/arista/x86_64-arista_7050cx3_32s/Arista-7050CX3-32S-C32/config.bcm.j2 @@ -1,16 +1,24 @@ {# Construct config.bcm to include additional soc properties per specific device metadata requirement #} {%- set map_prio = '' -%} +{%- set pfcwd_sock = '' -%} {%- if DEVICE_METADATA is defined and DEVICE_METADATA['localhost'] is defined and DEVICE_METADATA['localhost']['subtype'] is defined -%} {%- set switch_subtype = DEVICE_METADATA['localhost']['subtype'] -%} {%- if 'dualtor' in switch_subtype.lower() %} {%- set map_prio = 'sai_remap_prio_on_tnl_egress=1' -%} {%- endif %} {%- endif %} +{%- if SYSTEM_DEFAULTS is defined and 'tunnel_qos_remap' in SYSTEM_DEFAULTS and SYSTEM_DEFAULTS['tunnel_qos_remap']['status'] == 'enabled' -%} +{%- set pfcwd_sock = +'hybrid_pfc_deadlock_enable=1 +pfc_deadlock_seq_control=1 +sai_pfc_dlr_init_capability=1' -%} +{%- endif %} sai_load_hw_config=/etc/bcm/flex/bcm56870_a0_premium_issu/b870.6.4.1/ l3_alpm_hit_skip=1 sai_adjust_acl_drop_in_rx_drop=1 sai_verify_incoming_chksum=0 {{ map_prio }} +{{ pfcwd_sock }} host_as_route_disable=1 use_all_splithorizon_groups=1 riot_enable=1 diff --git a/device/arista/x86_64-arista_7050cx3_32s/Arista-7050CX3-32S-D48C8/config.bcm.j2 b/device/arista/x86_64-arista_7050cx3_32s/Arista-7050CX3-32S-D48C8/config.bcm.j2 index a68ff78bab3c..d54eee299f52 100644 --- a/device/arista/x86_64-arista_7050cx3_32s/Arista-7050CX3-32S-D48C8/config.bcm.j2 +++ b/device/arista/x86_64-arista_7050cx3_32s/Arista-7050CX3-32S-D48C8/config.bcm.j2 @@ -1,16 +1,24 @@ {# Construct config.bcm to include additional soc properties per specific device metadata requirement #} {%- set map_prio = '' -%} +{%- set pfcwd_sock = '' -%} {%- if DEVICE_METADATA is defined and DEVICE_METADATA['localhost'] is defined and DEVICE_METADATA['localhost']['subtype'] is defined -%} {%- set switch_subtype = DEVICE_METADATA['localhost']['subtype'] -%} {%- if 'dualtor' in switch_subtype.lower() %} {%- set map_prio = 'sai_remap_prio_on_tnl_egress=1' -%} {%- endif %} {%- endif %} +{%- if SYSTEM_DEFAULTS is defined and 'tunnel_qos_remap' in SYSTEM_DEFAULTS and SYSTEM_DEFAULTS['tunnel_qos_remap']['status'] == 'enabled' -%} +{%- set pfcwd_sock = +'hybrid_pfc_deadlock_enable=1 +pfc_deadlock_seq_control=1 +sai_pfc_dlr_init_capability=1' -%} +{%- endif %} sai_load_hw_config=/etc/bcm/flex/bcm56870_a0_premium_issu/b870.6.4.1/ l3_alpm_hit_skip=1 sai_adjust_acl_drop_in_rx_drop=1 sai_verify_incoming_chksum=0 {{ map_prio }} +{{ pfcwd_sock }} host_as_route_disable=1 use_all_splithorizon_groups=1 riot_enable=1 diff --git a/device/arista/x86_64-arista_7260cx3_64/Arista-7260CX3-C64/config.bcm.j2 b/device/arista/x86_64-arista_7260cx3_64/Arista-7260CX3-C64/config.bcm.j2 index 7ad0311ab888..97040d332ced 100644 --- a/device/arista/x86_64-arista_7260cx3_64/Arista-7260CX3-C64/config.bcm.j2 +++ b/device/arista/x86_64-arista_7260cx3_64/Arista-7260CX3-C64/config.bcm.j2 @@ -2,6 +2,7 @@ {%- set mmu_sock = 'mmu_init_config="MSFT-TH2-Tier1"' -%} {%- set IPinIP_sock = '' -%} {%- set map_prio = '' -%} +{%- set pfcwd_sock = '' -%} {%- if DEVICE_METADATA is defined and DEVICE_METADATA['localhost'] is defined -%} {%- if DEVICE_METADATA['localhost']['type'] is defined -%} {%- set switch_role = DEVICE_METADATA['localhost']['type'] -%} @@ -12,19 +13,27 @@ {%- if DEVICE_METADATA['localhost']['subtype'] is defined -%} {%- set switch_subtype = DEVICE_METADATA['localhost']['subtype'] -%} {%- if 'dualtor' in switch_subtype.lower() %} -{%- set IPinIP_sock = 'sai_tunnel_support=1 - sai_tunnel_underlay_route_mode=1 - host_as_route_disable=1 - l3_ecmp_levels=2' -%} +{%- set IPinIP_sock = +'sai_tunnel_support=1 +sai_tunnel_underlay_route_mode=1 +host_as_route_disable=1 +l3_ecmp_levels=2' -%} {%- set map_prio = 'sai_remap_prio_on_tnl_egress=1' -%} {%- endif %} {%- endif %} {%- endif %} +{%- if SYSTEM_DEFAULTS is defined and 'tunnel_qos_remap' in SYSTEM_DEFAULTS and SYSTEM_DEFAULTS['tunnel_qos_remap']['status'] == 'enabled' -%} +{%- set pfcwd_sock = +'hybrid_pfc_deadlock_enable=1 +pfc_deadlock_seq_control=1 +sai_pfc_dlr_init_capability=1' -%} +{%- endif %} {# The following is the common soc properties that used to be named "th2-a7260cx3-64-64x100G-t1.config.bcm" #} l3_alpm_hit_skip=1 sai_adjust_acl_drop_in_rx_drop=1 {{ map_prio }} +{{ pfcwd_sock }} PHY_AN_ALLOW_PLL_CHANGE=1 arl_clean_timeout_usec=15000000 asf_mem_profile=2 diff --git a/device/arista/x86_64-arista_7260cx3_64/Arista-7260CX3-D108C10/config.bcm.j2 b/device/arista/x86_64-arista_7260cx3_64/Arista-7260CX3-D108C10/config.bcm.j2 index 2255d7149b6b..019f556edb8f 100644 --- a/device/arista/x86_64-arista_7260cx3_64/Arista-7260CX3-D108C10/config.bcm.j2 +++ b/device/arista/x86_64-arista_7260cx3_64/Arista-7260CX3-D108C10/config.bcm.j2 @@ -1,20 +1,29 @@ {# Construct config.bcm to include additional soc properties per specific device metadata requirement #} {%- set IPinIP_sock = '' -%} {%- set map_prio = '' -%} +{%- set pfcwd_sock = '' -%} {%- if DEVICE_METADATA is defined and DEVICE_METADATA['localhost'] is defined and DEVICE_METADATA['localhost']['subtype'] is defined -%} {%- set switch_subtype = DEVICE_METADATA['localhost']['subtype'] -%} {%- if 'dualtor' in switch_subtype.lower() %} -{%- set IPinIP_sock = 'sai_tunnel_support=1 - sai_tunnel_underlay_route_mode=1 - host_as_route_disable=1 - l3_ecmp_levels=2' -%} +{%- set IPinIP_sock = +'sai_tunnel_support=1 +sai_tunnel_underlay_route_mode=1 +host_as_route_disable=1 +l3_ecmp_levels=2' -%} {%- set map_prio = 'sai_remap_prio_on_tnl_egress=1' -%} {%- endif %} {%- endif %} +{%- if SYSTEM_DEFAULTS is defined and 'tunnel_qos_remap' in SYSTEM_DEFAULTS and SYSTEM_DEFAULTS['tunnel_qos_remap']['status'] == 'enabled' -%} +{%- set pfcwd_sock = +'hybrid_pfc_deadlock_enable=1 +pfc_deadlock_seq_control=1 +sai_pfc_dlr_init_capability=1' -%} +{%- endif %} {# The following is the common soc properties that used to be named "th2-a7260cx3-64-112x50G+8x100G.config.bcm" #} l3_alpm_hit_skip=1 sai_adjust_acl_drop_in_rx_drop=1 {{ map_prio }} +{{ pfcwd_sock }} PHY_AN_ALLOW_PLL_CHANGE=1 arl_clean_timeout_usec=15000000 asf_mem_profile=2 diff --git a/device/arista/x86_64-arista_7260cx3_64/Arista-7260CX3-D108C8/config.bcm.j2 b/device/arista/x86_64-arista_7260cx3_64/Arista-7260CX3-D108C8/config.bcm.j2 index 642b36312d5c..1efa8ef69567 100644 --- a/device/arista/x86_64-arista_7260cx3_64/Arista-7260CX3-D108C8/config.bcm.j2 +++ b/device/arista/x86_64-arista_7260cx3_64/Arista-7260CX3-D108C8/config.bcm.j2 @@ -1,20 +1,29 @@ {# Construct config.bcm to include additional soc properties per specific device metadata requirement #} {%- set IPinIP_sock = '' -%} {%- set map_prio = '' -%} +{%- set pfcwd_sock = '' -%} {%- if DEVICE_METADATA is defined and DEVICE_METADATA['localhost'] is defined and DEVICE_METADATA['localhost']['subtype'] is defined -%} {%- set switch_subtype = DEVICE_METADATA['localhost']['subtype'] -%} {%- if 'dualtor' in switch_subtype.lower() %} -{%- set IPinIP_sock = 'sai_tunnel_support=1 - sai_tunnel_underlay_route_mode=1 - host_as_route_disable=1 - l3_ecmp_levels=2' -%} +{%- set IPinIP_sock = +'sai_tunnel_support=1 +sai_tunnel_underlay_route_mode=1 +host_as_route_disable=1 +l3_ecmp_levels=2' -%} {%- set map_prio = 'sai_remap_prio_on_tnl_egress=1' -%} {%- endif %} {%- endif %} +{%- if SYSTEM_DEFAULTS is defined and 'tunnel_qos_remap' in SYSTEM_DEFAULTS and SYSTEM_DEFAULTS['tunnel_qos_remap']['status'] == 'enabled' -%} +{%- set pfcwd_sock = +'hybrid_pfc_deadlock_enable=1 +pfc_deadlock_seq_control=1 +sai_pfc_dlr_init_capability=1' -%} +{%- endif %} {# The following is the common soc properties that used to be named "th2-a7260cx3-64-112x50G+8x100G.config.bcm" #} l3_alpm_hit_skip=1 sai_adjust_acl_drop_in_rx_drop=1 {{ map_prio }} +{{ pfcwd_sock }} PHY_AN_ALLOW_PLL_CHANGE=1 arl_clean_timeout_usec=15000000 asf_mem_profile=2 diff --git a/device/arista/x86_64-arista_7260cx3_64/Arista-7260CX3-Q64/config.bcm.j2 b/device/arista/x86_64-arista_7260cx3_64/Arista-7260CX3-Q64/config.bcm.j2 index 5ff359e06b72..de7cac15435a 100644 --- a/device/arista/x86_64-arista_7260cx3_64/Arista-7260CX3-Q64/config.bcm.j2 +++ b/device/arista/x86_64-arista_7260cx3_64/Arista-7260CX3-Q64/config.bcm.j2 @@ -2,6 +2,7 @@ {%- set mmu_sock = 'mmu_init_config="MSFT-TH2-Tier1"' -%} {%- set IPinIP_sock = '' -%} {%- set map_prio = '' -%} +{%- set pfcwd_sock = '' -%} {%- if DEVICE_METADATA is defined and DEVICE_METADATA['localhost'] is defined -%} {%- if DEVICE_METADATA['localhost']['type'] is defined -%} {%- set switch_role = DEVICE_METADATA['localhost']['type'] -%} @@ -12,18 +13,26 @@ {%- if DEVICE_METADATA['localhost']['subtype'] is defined -%} {%- set switch_subtype = DEVICE_METADATA['localhost']['subtype'] -%} {%- if 'dualtor' in switch_subtype.lower() %} -{%- set IPinIP_sock = 'sai_tunnel_support=1 - sai_tunnel_underlay_route_mode=1 - host_as_route_disable=1 - l3_ecmp_levels=2' -%} +{%- set IPinIP_sock = +'sai_tunnel_support=1 +sai_tunnel_underlay_route_mode=1 +host_as_route_disable=1 +l3_ecmp_levels=2' -%} {%- set map_prio = 'sai_remap_prio_on_tnl_egress=1' -%} {%- endif %} {%- endif %} {%- endif %} +{%- if SYSTEM_DEFAULTS is defined and 'tunnel_qos_remap' in SYSTEM_DEFAULTS and SYSTEM_DEFAULTS['tunnel_qos_remap']['status'] == 'enabled' -%} +{%- set pfcwd_sock = +'hybrid_pfc_deadlock_enable=1 +pfc_deadlock_seq_control=1 +sai_pfc_dlr_init_capability=1' -%} +{%- endif %} {# The following is the common soc properties that used to be named "th2-a7260cx3-64-64x40G.config.bcm" #} l3_alpm_hit_skip=1 sai_adjust_acl_drop_in_rx_drop=1 {{ map_prio }} +{{ pfcwd_sock }} PHY_AN_ALLOW_PLL_CHANGE=1 arl_clean_timeout_usec=15000000 asf_mem_profile=2 diff --git a/src/sonic-config-engine/tests/data/j2_template/config.bcm.j2 b/src/sonic-config-engine/tests/data/j2_template/config.bcm.j2 index 187d40af2d4e..61aeb0eff901 100644 --- a/src/sonic-config-engine/tests/data/j2_template/config.bcm.j2 +++ b/src/sonic-config-engine/tests/data/j2_template/config.bcm.j2 @@ -2,6 +2,7 @@ {%- set mmu_sock = 'mmu_init_config="MSFT-TH2-Tier1"' -%} {%- set IPinIP_sock = '' -%} {%- set map_prio = '' -%} +{%- set pfcwd_sock = '' -%} {%- if DEVICE_METADATA is defined and DEVICE_METADATA['localhost'] is defined -%} {%- if DEVICE_METADATA['localhost']['type'] is defined -%} {%- set switch_role = DEVICE_METADATA['localhost']['type'] -%} @@ -12,17 +13,25 @@ {%- if DEVICE_METADATA['localhost']['subtype'] is defined -%} {%- set switch_subtype = DEVICE_METADATA['localhost']['subtype'] -%} {%- if 'dualtor' in switch_subtype.lower() %} -{%- set IPinIP_sock = 'sai_tunnel_support=1 - sai_tunnel_underlay_route_mode=1 - host_as_route_disable=1 - l3_ecmp_levels=2' -%} +{%- set IPinIP_sock = +'sai_tunnel_support=1 +sai_tunnel_underlay_route_mode=1 +host_as_route_disable=1 +l3_ecmp_levels=2' -%} {%- set map_prio = 'sai_remap_prio_on_tnl_egress=1' -%} {%- endif %} {%- endif %} {%- endif %} +{%- if SYSTEM_DEFAULTS is defined and 'tunnel_qos_remap' in SYSTEM_DEFAULTS and SYSTEM_DEFAULTS['tunnel_qos_remap']['status'] == 'enabled' -%} +{%- set pfcwd_sock = +'hybrid_pfc_deadlock_enable=1 +pfc_deadlock_seq_control=1 +sai_pfc_dlr_init_capability=1' -%} +{%- endif %} {# The following is the common soc properties that used to be named "th2-a7260cx3-64-64x100G-t1.config.bcm" #} l3_alpm_hit_skip=1 {{ map_prio }} {{ mmu_sock }} {{ IPinIP_sock }} +{{ pfcwd_sock }} diff --git a/src/sonic-config-engine/tests/sample_output/py3/arista7050cx3-dualtor.config.bcm b/src/sonic-config-engine/tests/sample_output/py3/arista7050cx3-dualtor.config.bcm index 7d21ac82f120..0f61b372e838 100644 --- a/src/sonic-config-engine/tests/sample_output/py3/arista7050cx3-dualtor.config.bcm +++ b/src/sonic-config-engine/tests/sample_output/py3/arista7050cx3-dualtor.config.bcm @@ -3,6 +3,9 @@ l3_alpm_hit_skip=1 sai_remap_prio_on_tnl_egress=1 mmu_init_config="MSFT-TH2-Tier0" sai_tunnel_support=1 - sai_tunnel_underlay_route_mode=1 - host_as_route_disable=1 - l3_ecmp_levels=2 +sai_tunnel_underlay_route_mode=1 +host_as_route_disable=1 +l3_ecmp_levels=2 +hybrid_pfc_deadlock_enable=1 +pfc_deadlock_seq_control=1 +sai_pfc_dlr_init_capability=1 diff --git a/src/sonic-config-engine/tests/sample_output/py3/arista7260-dualtor.config.bcm b/src/sonic-config-engine/tests/sample_output/py3/arista7260-dualtor.config.bcm index 7d21ac82f120..0f61b372e838 100644 --- a/src/sonic-config-engine/tests/sample_output/py3/arista7260-dualtor.config.bcm +++ b/src/sonic-config-engine/tests/sample_output/py3/arista7260-dualtor.config.bcm @@ -3,6 +3,9 @@ l3_alpm_hit_skip=1 sai_remap_prio_on_tnl_egress=1 mmu_init_config="MSFT-TH2-Tier0" sai_tunnel_support=1 - sai_tunnel_underlay_route_mode=1 - host_as_route_disable=1 - l3_ecmp_levels=2 +sai_tunnel_underlay_route_mode=1 +host_as_route_disable=1 +l3_ecmp_levels=2 +hybrid_pfc_deadlock_enable=1 +pfc_deadlock_seq_control=1 +sai_pfc_dlr_init_capability=1 diff --git a/src/sonic-config-engine/tests/sample_output/py3/arista7260-t1.config.bcm b/src/sonic-config-engine/tests/sample_output/py3/arista7260-t1.config.bcm index 84a917290f24..a76c2173f436 100644 --- a/src/sonic-config-engine/tests/sample_output/py3/arista7260-t1.config.bcm +++ b/src/sonic-config-engine/tests/sample_output/py3/arista7260-t1.config.bcm @@ -3,3 +3,6 @@ l3_alpm_hit_skip=1 mmu_init_config="MSFT-TH2-Tier1" +hybrid_pfc_deadlock_enable=1 +pfc_deadlock_seq_control=1 +sai_pfc_dlr_init_capability=1