File tree Expand file tree Collapse file tree 3 files changed +102
-3
lines changed
Expand file tree Collapse file tree 3 files changed +102
-3
lines changed Original file line number Diff line number Diff line change 175175 },
176176 "PORT_WITH_NO_LANES_ON_MULT_ASIC_VS_2" : {
177177 "desc" : " PORT_WITH_NO_LANES_ON_MULT_ASIC_VS_2 no failure."
178+ },
179+ "PORT_VALID_DAMPING_AIED_TEST" : {
180+ "desc" : " PORT_VALID_DAMPING_AIED_TEST no failure."
181+ },
182+ "PORT_VALID_DAMPING_AIED_MONITOR_TEST" : {
183+ "desc" : " PORT_VALID_DAMPING_AIED_MONITOR_TEST no failure."
184+ },
185+ "PORT_INVALID_DAMPING_ALGORITHM_TEST" : {
186+ "desc" : " PORT_INVALID_DAMPING_ALGORITHM_TEST invalid algorithm pattern failure." ,
187+ "eStrKey" : " Pattern" ,
188+ "eStr" : [" disabled|aied|aied-monitor" ]
189+ },
190+ "PORT_INVALID_DAMPING_HALFLIFE_GT_MAXSUPPRESS_TEST" : {
191+ "desc" : " PORT_INVALID_DAMPING_HALFLIFE_GT_MAXSUPPRESS_TEST must condition failure." ,
192+ "eStrKey" : " Must" ,
193+ "eStr" : [" decay_half_life must be less than or equal to max_suppress_time" ]
178194 }
179195
180-
181-
182196}
Original file line number Diff line number Diff line change 10131013 "alias" : " etp1a" ,
10141014 "speed" : 100000 ,
10151015 "role" : " Int"
1016-
1016+
1017+ }
1018+ ]
1019+ }
1020+ }
1021+ },
1022+
1023+ "PORT_VALID_DAMPING_AIED_TEST" : {
1024+ "sonic-port:sonic-port" : {
1025+ "sonic-port:PORT" : {
1026+ "PORT_LIST" : [
1027+ {
1028+ "name" : " Ethernet8" ,
1029+ "alias" : " eth8" ,
1030+ "lanes" : " 65" ,
1031+ "speed" : 25000 ,
1032+ "link_event_damping_algorithm" : " aied" ,
1033+ "max_suppress_time" : 20 ,
1034+ "decay_half_life" : 5 ,
1035+ "suppress_threshold" : 2000 ,
1036+ "reuse_threshold" : 1000 ,
1037+ "flap_penalty" : 1000
1038+ }
1039+ ]
1040+ }
1041+ }
1042+ },
1043+
1044+ "PORT_VALID_DAMPING_AIED_MONITOR_TEST" : {
1045+ "sonic-port:sonic-port" : {
1046+ "sonic-port:PORT" : {
1047+ "PORT_LIST" : [
1048+ {
1049+ "name" : " Ethernet8" ,
1050+ "alias" : " eth8" ,
1051+ "lanes" : " 65" ,
1052+ "speed" : 25000 ,
1053+ "link_event_damping_algorithm" : " aied-monitor" ,
1054+ "max_suppress_time" : 20 ,
1055+ "decay_half_life" : 5 ,
1056+ "suppress_threshold" : 2000 ,
1057+ "reuse_threshold" : 1000 ,
1058+ "flap_penalty" : 1000
1059+ }
1060+ ]
1061+ }
1062+ }
1063+ },
1064+
1065+ "PORT_INVALID_DAMPING_ALGORITHM_TEST" : {
1066+ "sonic-port:sonic-port" : {
1067+ "sonic-port:PORT" : {
1068+ "PORT_LIST" : [
1069+ {
1070+ "name" : " Ethernet8" ,
1071+ "alias" : " eth8" ,
1072+ "lanes" : " 65" ,
1073+ "speed" : 25000 ,
1074+ "link_event_damping_algorithm" : " invalid_value"
1075+ }
1076+ ]
1077+ }
1078+ }
1079+ },
1080+
1081+ "PORT_INVALID_DAMPING_HALFLIFE_GT_MAXSUPPRESS_TEST" : {
1082+ "sonic-port:sonic-port" : {
1083+ "sonic-port:PORT" : {
1084+ "PORT_LIST" : [
1085+ {
1086+ "name" : " Ethernet8" ,
1087+ "alias" : " eth8" ,
1088+ "lanes" : " 65" ,
1089+ "speed" : 25000 ,
1090+ "link_event_damping_algorithm" : " aied" ,
1091+ "max_suppress_time" : 10 ,
1092+ "decay_half_life" : 15 ,
1093+ "suppress_threshold" : 2000 ,
1094+ "reuse_threshold" : 1000 ,
1095+ "flap_penalty" : 1000
10171096 }
10181097 ]
10191098 }
Original file line number Diff line number Diff line change @@ -276,6 +276,9 @@ module sonic-port{
276276 Must be less than or equal to max_suppress_time.
277277 A value of 0 means this parameter is not configured.
278278 Industry default: 5 seconds." ;
279+ must "current() = 0 or ../max_suppress_time = 0 or current() <= ../max_suppress_time" {
280+ error-message "decay_half_life must be less than or equal to max_suppress_time" ;
281+ }
279282 type uint32 ;
280283 default 0 ;
281284 }
@@ -297,6 +300,9 @@ module sonic-port{
297300 Must be less than or equal to suppress_threshold.
298301 A value of 0 means this parameter is not configured.
299302 Industry default: 1000." ;
303+ must "current() = 0 or ../suppress_threshold = 0 or current() <= ../suppress_threshold" {
304+ error-message "reuse_threshold must be less than or equal to suppress_threshold" ;
305+ }
300306 type uint32 ;
301307 default 0 ;
302308 }
You can’t perform that action at this time.
0 commit comments