3 namespace "urn:opendaylight:params:xml:ns:yang:v3po";
6 revision "2015-01-05" {
7 description "Initial revision of v3po model";
13 import ietf-interfaces {
16 import ietf-yang-types {
19 import ietf-inet-types {
29 typedef bridge-domain-ref {
31 path "/vpp/bridge-domains/bridge-domain/name";
34 "This type is used by to reference a bridge domain table";
37 typedef bridged-virtual-interface-ref {
39 path "/if:interfaces/if:interface/l2/bridged-virtual-interface";
42 "This type is used by to reference a bridged virtual interface";
45 identity vxlan-tunnel {
46 base if:interface-type;
50 // FIXME: should be in a vxlan-specific model
51 description "VNI used in a VXLAN tunnel";
57 grouping bridge-domain-attributes {
62 "Enable/disable L2 flooding.";
68 "Enable/disable L2 forwarding.";
74 "Enable/disable L2 learning.";
76 leaf unknown-unicast-flood {
80 leaf arp-termination {
86 augment /if:interfaces/if:interface {
87 ext:augment-identifier "vpp-interface-augmentation";
89 // FIXME using ietf-interfaces model for vpp interfaces makes it hard to implement because:
90 // 1. The link between interface type and this augmentation is unclear
91 // 2. Only this augmentation with combination of ifc type is trigger to do something for vpp, what if user only configures base interface stuff ? + We need to get leaves defined by ietf-interfaces when we are processing this augment
94 when "../if:type = 'ianaift:ethernetCsmacd'";
102 "The size, in octets, of the largest packet that the
103 hardware interface will send and receive.";
113 // FIXME: this should be in an vxlan-specific extension
114 when "../if:type = 'v3po:vxlan-tunnel'";
117 /* mandatory true; */
118 type inet:ipv4-address;
121 /* mandatory true; */
122 type inet:ipv4-address;
125 /* mandatory true; */
134 "Parameters for configuring Layer2 features on interfaces.";
135 must "(not (../if:ipv4[if:enabled = 'true']/if:address/if:ip) and " +
136 "not (../if:ipv6[if:enabled = 'true']/if:address/if:ip))";
138 choice interconnection {
139 case xconnect-based {
140 leaf xconnect-outgoing-interface {
141 /* Don't allow selection of this interface */
142 must "../../if:name != current()";
143 type if:interface-ref;
150 type bridge-domain-ref;
152 "Interfaces in a bridge-domain forward packets to other
153 interfaces in the same bridge-domain based on
154 destination mac address.";
156 leaf split-horizon-group {
157 when "../bridge-domain";
163 "Interface's split-horizon group. Interfaces in the same
164 bridge-domain and split-horizon group can not forward
165 packets between each other. ";
167 leaf bridged-virtual-interface {
168 when "../bridge-domain";
172 "Interface forward packets in the bridge-domain
173 associated with the BVI.";
184 container bridge-domains {
187 // TODO: where does this come from?
194 uses bridge-domain-attributes;
200 type yang:phys-address;
209 leaf outgoing-interface {
210 type if:interface-ref;
217 augment /if:interfaces-state/if:interface {
218 ext:augment-identifier "vpp-interface-state-augmentation";
224 when "../if:type = 'ianaift:ethernetCsmacd'";
228 leaf manufacturer-description {
239 when "../if:type = 'v3po:vxlan-tunnel'";
242 type inet:ipv4-address;
245 type inet:ipv4-address;
255 choice interconnection {
256 case xconnect-based {
257 leaf xconnect-outgoing-interface {
258 type if:interface-ref;
263 type bridge-domain-ref;
265 leaf split-horizon-group {
268 leaf bridged-virtual-interface {
276 augment /if:interfaces-state/if:interface/if:statistics {
277 ext:augment-identifier "vpp-interface-statistics-augmentation";
278 leaf in-errors-no-buf {
281 leaf in-errors-miss {
284 leaf out-discards-fifo-full {
289 container vpp-state {
293 "VPP operational data";
295 container bridge-domains {
296 // FIXME: Should this live in bridge-domain.yang in a modular fashion ?
304 uses bridge-domain-attributes;
310 type if:interface-state-ref;
313 leaf split-horizon-group {
317 leaf bridged-virtual-interface {
326 type yang:phys-address;
331 leaf outgoing-interface {
332 when "../v3po:action = 'forward'";
333 type if:interface-state-ref;
342 leaf bridged-virtual-interface {
343 when "../v3po:action = 'forward'";
348 "bridge-domain operational data";
356 leaf build-directory {