-
Notifications
You must be signed in to change notification settings - Fork 143
Expand file tree
/
Copy pathsonic-port.yang
More file actions
107 lines (86 loc) · 1.9 KB
/
Copy pathsonic-port.yang
File metadata and controls
107 lines (86 loc) · 1.9 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
module sonic-port {
namespace "http://github.com/Azure/sonic-port";
prefix prt;
import sonic-common {
prefix cmn;
}
organization
"SONiC";
contact
"SONiC";
description
"SONIC PORT";
revision 2021-03-15 {
description
"Added fec.";
}
revision 2019-05-15 {
description
"Initial revision.";
}
container sonic-port {
container PORT {
list PORT_LIST {
key "ifname";
leaf ifname {
type string {
pattern "Ethernet([1-3][0-9]{3}|[1-9][0-9]{2}|[1-9][0-9]|[0-9])" {
error-message "Invalid interface name";
error-app-tag interface-name-invalid;
}
}
}
leaf index {
type uint16;
mandatory true;
}
leaf speed {
type uint64 {
range "1000|10000|25000|40000|50000|100000|400000" {
error-message "Invalid Ethernet interface speed";
error-app-tag port-speed-invalid;
}
}
}
leaf valid_speeds {
type string;
}
leaf alias {
type string {
pattern '[ -~]{0,64}';
}
}
leaf description {
type string {
pattern '[ -~]{0,64}';
}
}
leaf mtu{
type uint32 {
range "1312..9216" {
error-message "Invalid MTU value";
error-app-tag mtu-invalid;
}
}
default 9100;
}
leaf lanes {
type string;
mandatory true;
}
leaf admin_status {
type cmn:admin-status;
default "down";
}
leaf fec {
type string {
pattern "(none|rs|fc)" {
error-message "Invalid interface FEC mode";
error-app-tag fec-mode-invalid;
}
}
}
}
}
}
}