File tree Expand file tree Collapse file tree 5 files changed +15
-20
lines changed Expand file tree Collapse file tree 5 files changed +15
-20
lines changed Original file line number Diff line number Diff line change 1
1
2
2
module sonic-common {
3
3
namespace "http://github.com/Azure/sonic-common" ;
4
- prefix scommon ;
4
+ prefix cmn ;
5
5
6
6
organization
7
7
"SONiC" ;
Original file line number Diff line number Diff line change 1
1
module sonic-acl {
2
2
namespace "http://github.com/Azure/sonic-acl" ;
3
- prefix sacl ;
3
+ prefix acl ;
4
4
yang-version 1.1 ;
5
5
6
6
import ietf-inet-types {
@@ -117,14 +117,6 @@ module sonic-acl {
117
117
}
118
118
}
119
119
120
- leaf MIRROR_ACTION {
121
- type string {
122
- pattern '[a-zA-Z0-9]{1}([-a-zA-Z0-9_]{1,63})' {
123
- error-app-tag mirror-action-invalid;
124
- }
125
- }
126
- }
127
-
128
120
leaf IP_TYPE {
129
121
mandatory true ;
130
122
type enumeration {
@@ -181,7 +173,7 @@ module sonic-acl {
181
173
choice src_port {
182
174
case l4_src_port {
183
175
leaf L4_SRC_PORT {
184
- type uint16 ;
176
+ type inet:port-number ;
185
177
}
186
178
}
187
179
case l4_src_port_range {
@@ -198,7 +190,7 @@ module sonic-acl {
198
190
choice dst_port {
199
191
case l4_dst_port {
200
192
leaf L4_DST_PORT {
201
- type uint16 ;
193
+ type inet:port-number ;
202
194
}
203
195
}
204
196
case l4_dst_port_range {
@@ -221,11 +213,7 @@ module sonic-acl {
221
213
}
222
214
223
215
leaf DSCP {
224
- type uint8 {
225
- range "0..63" {
226
- error-app-tag dscp-invalid;
227
- }
228
- }
216
+ type inet:dscp;
229
217
}
230
218
}
231
219
}
Original file line number Diff line number Diff line change @@ -37,13 +37,15 @@ module sonic-interface {
37
37
}
38
38
}
39
39
40
+ /* Add a leafref, once VRF YANG is supported
40
41
leaf vrf-name {
41
42
type string {
42
43
pattern 'Vrf([-a-zA-Z0-9_]{1,60})' {
43
44
error-app-tag vrf-name-invalid;
44
45
}
45
46
}
46
47
}
48
+ */
47
49
48
50
}
49
51
Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ module sonic-port {
3
3
prefix prt;
4
4
5
5
import sonic-common {
6
- prefix scommon ;
6
+ prefix cmn ;
7
7
}
8
8
9
9
organization
@@ -75,7 +75,7 @@ module sonic-port {
75
75
}
76
76
77
77
leaf admin_status {
78
- type scommon :admin-status;
78
+ type cmn :admin-status;
79
79
default "down" ;
80
80
}
81
81
}
Original file line number Diff line number Diff line change @@ -1812,12 +1812,14 @@ func TestValidateEditConfig_Update_Syntax_DependentData_Redis_Positive(t *testin
1812
1812
loadConfigDB (rclient , mpi_acl_table_rule )
1813
1813
1814
1814
depDataMap := map [string ]interface {}{
1815
+ /* Use MIRROR session once supported ---
1815
1816
"MIRROR_SESSION": map[string]interface{}{
1816
1817
"everflow2": map[string]interface{}{
1817
1818
"src_ip": "10.1.0.32",
1818
1819
"dst_ip": "2.2.2.2",
1819
1820
},
1820
1821
},
1822
+ */
1821
1823
}
1822
1824
1823
1825
loadConfigDB (rclient , depDataMap )
@@ -1829,7 +1831,10 @@ func TestValidateEditConfig_Update_Syntax_DependentData_Redis_Positive(t *testin
1829
1831
cvl .OP_UPDATE ,
1830
1832
"ACL_RULE|TestACL13|Rule1" ,
1831
1833
map [string ]string {
1834
+ /* Use Mirror session when supported
1832
1835
"MIRROR_ACTION": "everflow2",
1836
+ */
1837
+ "PACKET_ACTION" : "FORWARD" ,
1833
1838
},
1834
1839
},
1835
1840
}
@@ -3403,7 +3408,7 @@ func TestValidateEditConfig_Create_Syntax_Interface_OptionalKey_Positive(t *test
3403
3408
cvl .OP_CREATE ,
3404
3409
"INTERFACE|Ethernet24" ,
3405
3410
map [string ]string {
3406
- "vrf-name" : "Vrf1" ,
3411
+ /* "vrf-name": "Vrf1", -- Enable once VRF YANG implemented */
3407
3412
},
3408
3413
},
3409
3414
}
You can’t perform that action at this time.
0 commit comments