1 module openflowplugin-extension-nicira-match {
4 namespace "urn:opendaylight:openflowplugin:extension:nicira:match";
5 prefix "openflowplugin-nicira-match";
7 import yang-ext {prefix ext; revision-date "2013-07-09";}
8 import flow-node-inventory {prefix fni; revision-date 2013-08-19; }
9 import opendaylight-inventory {prefix inv;revision-date "2013-08-19";}
10 import sal-flow {prefix sal-flow;revision-date "2013-08-19";}
11 import packet-processing {prefix sal-packet;revision-date "2013-07-09";}
12 import openflowplugin-extension-general {prefix ext-gen;revision-date "2014-07-14";}
13 import opendaylight-flow-statistics {prefix odl-flow-stats;revision-date "2013-08-19";}
14 import opendaylight-direct-statistics {prefix odl-direct-stats;revision-date "2016-05-11";}
15 import nicira-match {prefix nicira-match;revision-date "2014-04-21";}
16 import ietf-inet-types {prefix inet; revision-date "2013-07-15";}
17 import ietf-yang-types {prefix yang; revision-date "2013-07-15";}
20 "Nicira openflow match extensions.";
22 revision "2014-07-14" {
23 description "Initial revision";
26 identity nxm-nx-reg0-key {
27 base ext-gen:extension-key;
29 identity nxm-nx-reg1-key {
30 base ext-gen:extension-key;
32 identity nxm-nx-reg2-key {
33 base ext-gen:extension-key;
35 identity nxm-nx-reg3-key {
36 base ext-gen:extension-key;
38 identity nxm-nx-reg4-key {
39 base ext-gen:extension-key;
41 identity nxm-nx-reg5-key {
42 base ext-gen:extension-key;
44 identity nxm-nx-reg6-key {
45 base ext-gen:extension-key;
47 identity nxm-nx-reg7-key {
48 base ext-gen:extension-key;
50 identity nxm-nx-tun-id-key {
51 base ext-gen:extension-key;
53 identity nxm-nx-arp-sha-key {
54 base ext-gen:extension-key;
56 identity nxm-nx-arp-tha-key {
57 base ext-gen:extension-key;
59 identity nxm-of-arp-op-key {
60 base ext-gen:extension-key;
62 identity nxm-of-arp-spa-key {
63 base ext-gen:extension-key;
65 identity nxm-of-arp-tpa-key {
66 base ext-gen:extension-key;
68 identity nxm-of-in-port-key {
69 base ext-gen:extension-key;
71 identity nxm-nx-tun-ipv4-dst-key {
72 base ext-gen:extension-key;
74 identity nxm-nx-tun-ipv4-src-key {
75 base ext-gen:extension-key;
77 identity nxm-of-eth-src-key {
78 base ext-gen:extension-key;
80 identity nxm-of-eth-dst-key {
81 base ext-gen:extension-key;
83 identity nxm-of-eth-type-key {
84 base ext-gen:extension-key;
86 identity nxm-nx-nsp-key {
87 base ext-gen:extension-key;
89 identity nxm-nx-nsi-key {
90 base ext-gen:extension-key;
92 identity nxm-nx-nshc-1-key {
93 base ext-gen:extension-key;
95 identity nxm-nx-nshc-2-key {
96 base ext-gen:extension-key;
98 identity nxm-nx-nshc-3-key {
99 base ext-gen:extension-key;
101 identity nxm-nx-nshc-4-key {
102 base ext-gen:extension-key;
104 identity nxm-of-tcp-src-key {
105 base ext-gen:extension-key;
107 identity nxm-of-tcp-dst-key {
108 base ext-gen:extension-key;
110 identity nxm-of-udp-src-key {
111 base ext-gen:extension-key;
113 identity nxm-of-udp-dst-key {
114 base ext-gen:extension-key;
116 identity nxm-nx-ct-state-key {
117 base ext-gen:extension-key;
119 identity nxm-nx-ct-zone-key {
120 base ext-gen:extension-key;
122 identity nxm-of-ip-dst-key {
123 base ext-gen:extension-key;
125 identity nxm-of-ip-src-key {
126 base ext-gen:extension-key;
128 identity nxm-of-icmp-type-key {
129 base ext-gen:extension-key;
131 identity nxm-nx-encap-eth-type-key {
132 base ext-gen:extension-key;
134 identity nxm-nx-encap-eth-src-key {
135 base ext-gen:extension-key;
137 identity nxm-nx-encap-eth-dst-key {
138 base ext-gen:extension-key;
140 identity nxm-nx-nsh-mdtype-key {
141 base ext-gen:extension-key;
143 identity nxm-nx-nsh-np-key {
144 base ext-gen:extension-key;
146 identity nxm-nx-tun-gpe-np-key {
147 base ext-gen:extension-key;
149 grouping ipv4-address-grouping {
151 type inet:ipv4-address;
154 grouping mac-address-grouping {
156 type yang:mac-address;
160 grouping nxm-nx-reg-grouping {
161 container nxm-nx-reg {
164 base nicira-match:nxm-nx-reg;
175 grouping nxm-nx-tun-id-grouping {
176 container nxm-nx-tun-id {
182 grouping nxm-nx-arp-sha-grouping {
183 container nxm-nx-arp-sha {
184 uses mac-address-grouping;
187 grouping nxm-nx-arp-tha-grouping {
188 container nxm-nx-arp-tha {
189 uses mac-address-grouping;
192 grouping nxm-of-arp-op-grouping {
193 container nxm-of-arp-op {
194 description "Prereqs: NXM_OF_ETH_TYPE must match either 0x0806 or 0x8035.";
200 grouping nxm-of-arp-spa-grouping {
201 container nxm-of-arp-spa {
202 description "Prereqs: NXM_OF_ETH_TYPE must match either 0x0806 or 0x8035.";
203 uses ipv4-address-grouping;
206 grouping nxm-of-in-port-grouping {
207 container of-in-port {
213 grouping nxm-of-tcp-src-grouping {
214 container nxm-of-tcp-src {
216 type inet:port-number;
223 grouping nxm-of-tcp-dst-grouping {
224 container nxm-of-tcp-dst {
226 type inet:port-number;
233 grouping nxm-of-udp-src-grouping {
234 container nxm-of-udp-src {
236 type inet:port-number;
243 grouping nxm-of-udp-dst-grouping {
244 container nxm-of-udp-dst {
246 type inet:port-number;
253 grouping nxm-of-arp-tpa-grouping {
254 container nxm-of-arp-tpa {
255 description "Prereqs: NXM_OF_ETH_TYPE must match either 0x0806 or 0x8035.";
256 uses ipv4-address-grouping;
259 grouping nxm-nx-tun-ipv4-dst-grouping {
260 container nxm-nx-tun-ipv4-dst {
261 uses ipv4-address-grouping;
264 grouping nxm-nx-tun-ipv4-src-grouping {
265 container nxm-nx-tun-ipv4-src {
266 uses ipv4-address-grouping;
269 grouping nxm-of-eth-src-grouping {
270 container nxm-of-eth-src {
271 uses mac-address-grouping;
274 grouping nxm-of-eth-dst-grouping {
275 container nxm-of-eth-dst {
276 uses mac-address-grouping;
279 grouping nxm-of-eth-type-grouping {
280 container nxm-of-eth-type {
286 grouping nxm-nx-nsp-grouping {
287 container nxm-nx-nsp {
293 grouping nxm-nx-nsi-grouping {
294 container nxm-nx-nsi {
300 grouping nxm-nx-nshc-1-grouping {
301 container nxm-nx-nshc-1 {
307 grouping nxm-nx-nshc-2-grouping {
308 container nxm-nx-nshc-2 {
314 grouping nxm-nx-nshc-3-grouping {
315 container nxm-nx-nshc-3 {
321 grouping nxm-nx-nshc-4-grouping {
322 container nxm-nx-nshc-4 {
328 grouping nxm-nx-ct-state-grouping {
329 container nxm-nx-ct-state {
338 grouping nxm-nx-ct-zone-grouping {
339 container nxm-nx-ct-zone {
345 grouping nxm-of-ip-dst-grouping {
346 container nxm-of-ip-dst {
347 uses ipv4-address-grouping;
350 grouping nxm-of-ip-src-grouping {
351 container nxm-of-ip-src {
352 uses ipv4-address-grouping;
355 grouping nxm-of-icmp-type-grouping {
356 container nxm-of-icmp-type {
362 grouping nxm-nx-encap-eth-type-grouping {
363 container nxm-nx-encap-eth-type {
369 grouping nxm-nx-encap-eth-src-grouping {
370 container nxm-nx-encap-eth-src {
371 uses mac-address-grouping;
374 grouping nxm-nx-encap-eth-dst-grouping {
375 container nxm-nx-encap-eth-dst {
376 uses mac-address-grouping;
379 grouping nxm-nx-nsh-mdtype-grouping {
380 container nxm-nx-nsh-mdtype {
386 grouping nxm-nx-nsh-np-grouping {
387 container nxm-nx-nsh-np {
393 grouping nxm-nx-tun-gpe-np-grouping {
394 container nxm-nx-tun-gpe-np {
402 grouping all-matches-grouping {
403 uses nxm-nx-reg-grouping;
404 uses nxm-nx-tun-id-grouping;
405 uses nxm-nx-arp-sha-grouping;
406 uses nxm-nx-arp-tha-grouping;
407 uses nxm-of-arp-op-grouping;
408 uses nxm-of-arp-spa-grouping;
409 uses nxm-of-arp-tpa-grouping;
410 uses nxm-of-in-port-grouping;
411 uses nxm-nx-tun-ipv4-dst-grouping;
412 uses nxm-nx-tun-ipv4-src-grouping;
413 uses nxm-of-eth-src-grouping;
414 uses nxm-of-eth-dst-grouping;
415 uses nxm-of-eth-type-grouping;
416 uses nxm-nx-nsp-grouping;
417 uses nxm-nx-nsi-grouping;
418 uses nxm-nx-nshc-1-grouping;
419 uses nxm-nx-nshc-2-grouping;
420 uses nxm-nx-nshc-3-grouping;
421 uses nxm-nx-nshc-4-grouping;
422 uses nxm-nx-encap-eth-type-grouping;
423 uses nxm-nx-encap-eth-src-grouping;
424 uses nxm-nx-encap-eth-dst-grouping;
425 uses nxm-nx-nsh-mdtype-grouping;
426 uses nxm-nx-nsh-np-grouping;
427 uses nxm-nx-tun-gpe-np-grouping;
428 uses nxm-of-tcp-src-grouping;
429 uses nxm-of-tcp-dst-grouping;
430 uses nxm-of-udp-src-grouping;
431 uses nxm-of-udp-dst-grouping;
432 uses nxm-nx-ct-state-grouping;
433 uses nxm-nx-ct-zone-grouping;
434 uses nxm-of-ip-dst-grouping;
435 uses nxm-of-ip-src-grouping;
436 uses nxm-of-icmp-type-grouping;
439 // MATCH augmentations
441 augment "/sal-flow:add-flow/sal-flow:input/sal-flow:match/ext-gen:extension-list/ext-gen:extension" {
442 ext:augment-identifier "nx-aug-match-rpc-add-flow";
443 uses all-matches-grouping;
445 augment "/sal-flow:remove-flow/sal-flow:input/sal-flow:match/ext-gen:extension-list/ext-gen:extension" {
446 ext:augment-identifier "nx-aug-match-rpc-remove-flow";
447 uses all-matches-grouping;
449 augment "/sal-flow:update-flow/sal-flow:input/sal-flow:original-flow/sal-flow:match/ext-gen:extension-list/ext-gen:extension" {
450 ext:augment-identifier "nx-aug-match-rpc-update-flow-original";
451 uses all-matches-grouping;
453 augment "/sal-flow:update-flow/sal-flow:input/sal-flow:updated-flow/sal-flow:match/ext-gen:extension-list/ext-gen:extension" {
454 ext:augment-identifier "nx-aug-match-rpc-update-flow-updated";
455 uses all-matches-grouping;
459 augment "/inv:nodes/inv:node/fni:table/fni:flow/fni:match/ext-gen:extension-list/ext-gen:extension" {
460 ext:augment-identifier "nx-aug-match-nodes-node-table-flow";
461 uses all-matches-grouping;
465 augment "/sal-flow:switch-flow-removed/sal-flow:match/ext-gen:extension-list/ext-gen:extension" {
466 ext:augment-identifier "nx-aug-match-notif-switch-flow-removed";
467 uses all-matches-grouping;
469 augment "/sal-packet:packet-received/sal-packet:match/ext-gen:extension-list/ext-gen:extension" {
470 ext:augment-identifier "nx-aug-match-notif-packet-in";
471 uses all-matches-grouping;
473 augment "/odl-flow-stats:flows-statistics-update/odl-flow-stats:flow-and-statistics-map-list/odl-flow-stats:match/ext-gen:extension-list/ext-gen:extension" {
474 ext:augment-identifier "nx-aug-match-notif-update-flow-stats";
475 uses all-matches-grouping;
477 augment "/odl-direct-stats:get-flow-statistics/odl-direct-stats:output/odl-direct-stats:flow-and-statistics-map-list/odl-direct-stats:match/ext-gen:extension-list/ext-gen:extension" {
478 ext:augment-identifier "nx-aug-match-rpc-get-flow-stats";
479 uses all-matches-grouping;