From 06a61dede04bb4fa567b8f96a3539730fc0c2310 Mon Sep 17 00:00:00 2001 From: Junchao-Mellanox <57339448+Junchao-Mellanox@users.noreply.github.com> Date: Wed, 1 Dec 2021 09:52:34 +0800 Subject: [PATCH] [YANG] Add trap flow counter to yang model (#9353) *[YANG] Add trap flow counter to yang model --- .../yang_model_tests/tests_config/flex_counter.json | 3 +++ .../yang-models/sonic-flex_counter.yang | 10 ++++++++++ 2 files changed, 13 insertions(+) diff --git a/src/sonic-yang-models/tests/yang_model_tests/tests_config/flex_counter.json b/src/sonic-yang-models/tests/yang_model_tests/tests_config/flex_counter.json index 056f86b3f2..47bd26d9b5 100644 --- a/src/sonic-yang-models/tests/yang_model_tests/tests_config/flex_counter.json +++ b/src/sonic-yang-models/tests/yang_model_tests/tests_config/flex_counter.json @@ -34,6 +34,9 @@ }, "ACL": { "FLEX_COUNTER_STATUS": "enable" + }, + "FLOW_CNT_TRAP": { + "FLEX_COUNTER_STATUS": "enable" } } } diff --git a/src/sonic-yang-models/yang-models/sonic-flex_counter.yang b/src/sonic-yang-models/yang-models/sonic-flex_counter.yang index 099a20a9c3..55a6ac2f3a 100644 --- a/src/sonic-yang-models/yang-models/sonic-flex_counter.yang +++ b/src/sonic-yang-models/yang-models/sonic-flex_counter.yang @@ -161,6 +161,16 @@ module sonic-flex_counter { } } + container FLOW_CNT_TRAP { + /* HOSTIF_TRAP_COUNTER_FLEX_COUNTER_GROUP */ + leaf FLEX_COUNTER_STATUS { + type flex_status; + } + leaf FLEX_COUNTER_DELAY_STATUS { + type flex_delay_status; + } + } + } /* end of container FLEX_COUNTER_TABLE */ }