Skip to content

Commit 8837dc2

Browse files
committed
[qos] add raw tag around the jinja2 sample code (#984)
Signed-off-by: Ying Xie <[email protected]>
1 parent 5edbb79 commit 8837dc2

File tree

3 files changed

+15
-1
lines changed

3 files changed

+15
-1
lines changed

doc/qos/reclaim-reserved-buffer.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,7 @@ The following snippet of code is to generate `PORT_INACTIVE` which contains all
166166
They need to be moved from the middle of `buffer_template.j2` to the place just before the vendor specific template is imported, so that the vendor specific template has access to `PORT_INACTIVE`.
167167

168168
```json
169+
{% raw %} # ignore this line please
169170
{%- set PORT_ALL = [] %}
170171

171172
{%- if PORT is not defined %}
@@ -192,16 +193,19 @@ They need to be moved from the middle of `buffer_template.j2` to the place just
192193

193194
{# Import default values from device HWSKU folder #}
194195
{%- import 'buffers_defaults_%s.j2' % filename_postfix as defs with context %}
196+
{% endraw %} # ignore this line please
195197
```
196198

197199
The vairable `port_names_inactive` also need to be generated by the following snipped of code.
198200

199201
```json
202+
{% raw %} # ignore this line please
200203
{%- set port_names_list_inactive = [] %}
201204
{%- for port in PORT_INACTIVE %}
202205
{%- if port_names_list_inactive.append(port) %}{%- endif %}
203206
{%- endfor %}
204207
{%- set port_names_inactive = port_names_list_inactive | join(',') %}
208+
{% endraw %} # ignore this line please
205209
```
206210

207211
##### 7.1.1.2 Macro to generate buffer pool and profiles #####
@@ -211,6 +215,7 @@ Zero buffer profiles should be defined for ingress/egress and lossless/lossy tra
211215
This macro is defined in vendor specific buffer template files.
212216

213217
```json
218+
{% raw %} # ignore this line please
214219
{%- macro generate_buffer_pool_and_profiles() %}
215220
"BUFFER_POOL": {
216221
{%- if dynamic_mode is not defined and PORT_INACTIVE is defined and PORT_INACTIVE|length > 0 %}
@@ -302,6 +307,7 @@ This macro is defined in vendor specific buffer template files.
302307
}
303308
},
304309
{%- endmacro %}
310+
{% endraw %} # ignore this line please
305311
```
306312

307313
##### 7.1.1.3 Macro to apply zero buffer profiles to inactive ports #####
@@ -321,6 +327,7 @@ These macros are defined in vendor specific buffer template files.
321327
generate_profile_lists_with_inactive_ports:
322328

323329
```json
330+
{% raw %} # ignore this line please
324331
{%- macro generate_profile_lists_with_inactive_ports(port_names_active, port_names_inactive) %}
325332
"BUFFER_PORT_INGRESS_PROFILE_LIST": {
326333
{% for port in port_names_active.split(',') %}
@@ -365,11 +372,13 @@ generate_profile_lists_with_inactive_ports:
365372
{% endif %}
366373
}
367374
{%- endmacro %}
375+
{% endraw %} # ignore this line please
368376
```
369377

370378
generate_pg_profiles_with_inactive_ports:
371379

372380
```json
381+
{% raw %} # ignore this line please
373382
{%- macro generate_pg_profiles(port_names_active, port_names_inactive) %}
374383
"BUFFER_PG": {
375384
{% for port in port_names_active.split(',') %}
@@ -403,11 +412,13 @@ generate_pg_profiles_with_inactive_ports:
403412
{% endif %}
404413
}
405414
{%- endmacro %}
415+
{% endraw %} # ignore this line please
406416
```
407417

408418
generate_queue_buffers_with_inactive_ports:
409419

410420
```json
421+
{% raw %} # ignore this line please
411422
{%- macro generate_queue_buffers(port_names_active, port_names_inactive) %}
412423
"BUFFER_QUEUE": {
413424
{% for port in port_names_active.split(',') %}
@@ -466,6 +477,7 @@ generate_queue_buffers_with_inactive_ports:
466477
{% endif %}
467478
}
468479
{%- endmacro %}
480+
{% endraw %} # ignore this line please
469481
```
470482

471483
Assume port `Ethernet0` is admin down, an example is:

doc/subport/sonic-sub-port-intf-hld.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,7 @@ Example configuration:
172172
"Ethernet0.100|192.0.0.1/21": {},
173173
"Ethernet0.100|fc0a::/112": {}
174174
"Eth64.10": {
175-
vlan : 100,
175+
"vlan" : 100,
176176
"admin_status" : "up"
177177
},
178178
"Eth64.10|192.168.0.1/21": {},

doc/vxlan/Overlay ECMP with BFD.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -143,13 +143,15 @@ VNET_ROUTE_TUNNEL_TABLE:{{vnet_name}}:{{prefix}}
143143

144144
Proposed:
145145
```
146+
{% raw %} # ignore this line please
146147
VNET_ROUTE_TUNNEL_TABLE:{{vnet_name}}:{{prefix}}
147148
"endpoint": {{ip_address1},{ip_address2},...}
148149
"endpoint_monitor": {{ip_address1},{ip_address2},...} (OPTIONAL)
149150
"mac_address":{{mac_address1},{mac_address2},...} (OPTIONAL)
150151
"vni": {{vni1},{vni2},...} (OPTIONAL)
151152
"weight": {{w1},{w2},...} (OPTIONAL)
152153
“profile”: {{profile_name}} (OPTIONAL)
154+
{% endraw %} # ignore this line please
153155
```
154156

155157
```

0 commit comments

Comments
 (0)