Skip to content

Commit

Permalink
[YANG] Update YANG model for pfcwd_sw_enable (#10444)
Browse files Browse the repository at this point in the history
* Update YANG for pfcwd_sw_enable

Signed-off-by: bingwang <[email protected]>
  • Loading branch information
bingwang-ms authored Apr 4, 2022
1 parent 13aa233 commit 470d735
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 5 deletions.
6 changes: 4 additions & 2 deletions src/sonic-yang-models/tests/files/sample_config_db.json
Original file line number Diff line number Diff line change
Expand Up @@ -1603,7 +1603,8 @@
"tc_to_pg_map": "tc_to_pg_map1",
"pfc_to_queue_map": "pfc_prio_to_q_map1",
"pfc_to_pg_map" : "pfc_prio_to_pg_map1",
"pfc_enable" : "3,4"
"pfc_enable" : "3,4",
"pfcwd_sw_enable" : "3,4"
},
"Ethernet4": {
"dot1p_to_tc_map" : "Dot1p_to_tc_map2",
Expand All @@ -1612,7 +1613,8 @@
"tc_to_pg_map": "tc_to_pg_map2",
"pfc_to_queue_map": "pfc_prio_to_q_map2",
"pfc_to_pg_map" : "pfc_prio_to_pg_map2",
"pfc_enable" : "3,4"
"pfc_enable" : "3,4",
"pfcwd_sw_enable" : "3,4"
}
},

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -621,7 +621,8 @@
"pfc_to_pg_map": "map1",
"dscp_to_tc_map": "map1",
"dot1p_to_tc_map": "map1",
"pfc_enable": "3,4"
"pfc_enable": "3,4",
"pfcwd_sw_enable" : "3,4"
}
]
}
Expand Down Expand Up @@ -657,7 +658,8 @@
"pfc_to_pg_map": "map2",
"dscp_to_tc_map": "map2",
"dot1p_to_tc_map": "map2",
"pfc_enable": "3,4"
"pfc_enable": "3,4",
"pfcwd_sw_enable" : "3,4"
}
]
}
Expand Down Expand Up @@ -714,7 +716,8 @@
"PORT_QOS_MAP_LIST": [
{
"ifname": "Ethernet4",
"pfc_enable": "8"
"pfc_enable": "8",
"pfcwd_sw_enable" : "8"
}
]
}
Expand Down
8 changes: 8 additions & 0 deletions src/sonic-yang-models/yang-models/sonic-port-qos-map.yang
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,14 @@ module sonic-port-qos-map {
}
}

leaf pfcwd_sw_enable {
type string {
pattern "[0-7](,[0-7])?";
}
description
"Specify the queue(s) on which software pfc watchdog are enabled.";
}

leaf pfc_to_queue_map {
type leafref {
path "/ppqm:sonic-pfc-priority-queue-map/ppqm:MAP_PFC_PRIORITY_TO_QUEUE/ppqm:MAP_PFC_PRIORITY_TO_QUEUE_LIST/ppqm:name";
Expand Down

0 comments on commit 470d735

Please sign in to comment.