Skip to content

Commit

Permalink
Minimize the change in the common code
Browse files Browse the repository at this point in the history
Signed-off-by: Stephen Sun <stephens@nvidia.com>
  • Loading branch information
stephenxs committed Nov 19, 2021
1 parent cacc293 commit e1e95b3
Show file tree
Hide file tree
Showing 3 changed files with 156 additions and 157 deletions.
7 changes: 4 additions & 3 deletions files/build_templates/buffers_config.j2
Original file line number Diff line number Diff line change
Expand Up @@ -110,10 +110,11 @@ def
{%- if DEVICE_NEIGHBOR is not defined %}
{%- set PORT_ACTIVE = PORT_ALL %}
{%- else %}
{%- for port in DEVICE_NEIGHBOR.keys() %}
{%- if PORT_ACTIVE.append(port) %}{%- endif %}
{%- endfor %}
{%- for port in PORT_ALL %}
{%- if port in DEVICE_NEIGHBOR.keys() %}
{%- if PORT_ACTIVE.append(port) %}{%- endif %}
{%- else %}
{%- if port not in DEVICE_NEIGHBOR.keys() %}
{%- if PORT_INACTIVE.append(port) %}{%- endif %}
{%- endif %}
{%- endfor %}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@


{
"CABLE_LENGTH": {
"AZURE": {
Expand Down Expand Up @@ -130,9 +129,6 @@
"Ethernet5|0": {
"profile" : "[BUFFER_PROFILE|ingress_lossy_profile]"
},
"Ethernet22|0": {
"profile" : "[BUFFER_PROFILE|ingress_lossy_profile]"
},
"Ethernet58|0": {
"profile" : "[BUFFER_PROFILE|ingress_lossy_profile]"
},
Expand Down Expand Up @@ -160,7 +156,7 @@
"Ethernet39|0": {
"profile" : "[BUFFER_PROFILE|ingress_lossy_profile]"
},
"Ethernet14|0": {
"Ethernet32|0": {
"profile" : "[BUFFER_PROFILE|ingress_lossy_profile]"
},
"Ethernet15|0": {
Expand All @@ -172,19 +168,19 @@
"Ethernet17|0": {
"profile" : "[BUFFER_PROFILE|ingress_lossy_profile]"
},
"Ethernet10|0": {
"Ethernet36|0": {
"profile" : "[BUFFER_PROFILE|ingress_lossy_profile]"
},
"Ethernet11|0": {
"Ethernet37|0": {
"profile" : "[BUFFER_PROFILE|ingress_lossy_profile]"
},
"Ethernet12|0": {
"profile" : "[BUFFER_PROFILE|ingress_lossy_profile]"
},
"Ethernet37|0": {
"Ethernet13|0": {
"profile" : "[BUFFER_PROFILE|ingress_lossy_profile]"
},
"Ethernet32|0": {
"Ethernet14|0": {
"profile" : "[BUFFER_PROFILE|ingress_lossy_profile]"
},
"Ethernet30|0": {
Expand All @@ -196,7 +192,7 @@
"Ethernet48|0": {
"profile" : "[BUFFER_PROFILE|ingress_lossy_profile]"
},
"Ethernet36|0": {
"Ethernet10|0": {
"profile" : "[BUFFER_PROFILE|ingress_lossy_profile]"
},
"Ethernet42|0": {
Expand All @@ -214,6 +210,9 @@
"Ethernet28|0": {
"profile" : "[BUFFER_PROFILE|ingress_lossy_profile]"
},
"Ethernet11|0": {
"profile" : "[BUFFER_PROFILE|ingress_lossy_profile]"
},
"Ethernet21|0": {
"profile" : "[BUFFER_PROFILE|ingress_lossy_profile]"
},
Expand All @@ -223,7 +222,7 @@
"Ethernet23|0": {
"profile" : "[BUFFER_PROFILE|ingress_lossy_profile]"
},
"Ethernet13|0": {
"Ethernet22|0": {
"profile" : "[BUFFER_PROFILE|ingress_lossy_profile]"
},
"Ethernet25|0": {
Expand Down Expand Up @@ -265,9 +264,6 @@
"Ethernet5|3-4": {
"profile" : "[BUFFER_PROFILE|egress_lossless_profile]"
},
"Ethernet22|3-4": {
"profile" : "[BUFFER_PROFILE|egress_lossless_profile]"
},
"Ethernet58|3-4": {
"profile" : "[BUFFER_PROFILE|egress_lossless_profile]"
},
Expand Down Expand Up @@ -295,7 +291,7 @@
"Ethernet39|3-4": {
"profile" : "[BUFFER_PROFILE|egress_lossless_profile]"
},
"Ethernet14|3-4": {
"Ethernet32|3-4": {
"profile" : "[BUFFER_PROFILE|egress_lossless_profile]"
},
"Ethernet15|3-4": {
Expand All @@ -307,19 +303,19 @@
"Ethernet17|3-4": {
"profile" : "[BUFFER_PROFILE|egress_lossless_profile]"
},
"Ethernet10|3-4": {
"Ethernet36|3-4": {
"profile" : "[BUFFER_PROFILE|egress_lossless_profile]"
},
"Ethernet11|3-4": {
"Ethernet37|3-4": {
"profile" : "[BUFFER_PROFILE|egress_lossless_profile]"
},
"Ethernet12|3-4": {
"profile" : "[BUFFER_PROFILE|egress_lossless_profile]"
},
"Ethernet37|3-4": {
"Ethernet13|3-4": {
"profile" : "[BUFFER_PROFILE|egress_lossless_profile]"
},
"Ethernet32|3-4": {
"Ethernet14|3-4": {
"profile" : "[BUFFER_PROFILE|egress_lossless_profile]"
},
"Ethernet30|3-4": {
Expand All @@ -331,7 +327,7 @@
"Ethernet48|3-4": {
"profile" : "[BUFFER_PROFILE|egress_lossless_profile]"
},
"Ethernet36|3-4": {
"Ethernet10|3-4": {
"profile" : "[BUFFER_PROFILE|egress_lossless_profile]"
},
"Ethernet42|3-4": {
Expand All @@ -349,6 +345,9 @@
"Ethernet28|3-4": {
"profile" : "[BUFFER_PROFILE|egress_lossless_profile]"
},
"Ethernet11|3-4": {
"profile" : "[BUFFER_PROFILE|egress_lossless_profile]"
},
"Ethernet21|3-4": {
"profile" : "[BUFFER_PROFILE|egress_lossless_profile]"
},
Expand All @@ -358,7 +357,7 @@
"Ethernet23|3-4": {
"profile" : "[BUFFER_PROFILE|egress_lossless_profile]"
},
"Ethernet13|3-4": {
"Ethernet22|3-4": {
"profile" : "[BUFFER_PROFILE|egress_lossless_profile]"
},
"Ethernet25|3-4": {
Expand Down Expand Up @@ -397,9 +396,6 @@
"Ethernet5|0-2": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet22|0-2": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet58|0-2": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
Expand Down Expand Up @@ -427,7 +423,7 @@
"Ethernet39|0-2": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet14|0-2": {
"Ethernet32|0-2": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet15|0-2": {
Expand All @@ -439,19 +435,19 @@
"Ethernet17|0-2": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet10|0-2": {
"Ethernet36|0-2": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet11|0-2": {
"Ethernet37|0-2": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet12|0-2": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet37|0-2": {
"Ethernet13|0-2": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet32|0-2": {
"Ethernet14|0-2": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet30|0-2": {
Expand All @@ -463,7 +459,7 @@
"Ethernet48|0-2": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet36|0-2": {
"Ethernet10|0-2": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet42|0-2": {
Expand All @@ -481,6 +477,9 @@
"Ethernet28|0-2": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet11|0-2": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet21|0-2": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
Expand All @@ -490,7 +489,7 @@
"Ethernet23|0-2": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet13|0-2": {
"Ethernet22|0-2": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet25|0-2": {
Expand Down Expand Up @@ -529,9 +528,6 @@
"Ethernet5|5-6": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet22|5-6": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet58|5-6": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
Expand Down Expand Up @@ -559,7 +555,7 @@
"Ethernet39|5-6": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet14|5-6": {
"Ethernet32|5-6": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet15|5-6": {
Expand All @@ -571,19 +567,19 @@
"Ethernet17|5-6": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet10|5-6": {
"Ethernet36|5-6": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet11|5-6": {
"Ethernet37|5-6": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet12|5-6": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet37|5-6": {
"Ethernet13|5-6": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet32|5-6": {
"Ethernet14|5-6": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet30|5-6": {
Expand All @@ -595,7 +591,7 @@
"Ethernet48|5-6": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet36|5-6": {
"Ethernet10|5-6": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet42|5-6": {
Expand All @@ -613,6 +609,9 @@
"Ethernet28|5-6": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet11|5-6": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet21|5-6": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
Expand All @@ -622,7 +621,7 @@
"Ethernet23|5-6": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet13|5-6": {
"Ethernet22|5-6": {
"profile" : "[BUFFER_PROFILE|egress_lossy_profile]"
},
"Ethernet25|5-6": {
Expand Down
Loading

0 comments on commit e1e95b3

Please sign in to comment.