Created experimenter subtype for vendor's actions
[openflowjava.git] / openflow-extension-nicira / src / main / yang / nicira-match.yang
1 module nicira-match {
2     yang-version 1;
3
4     namespace "urn:opendaylight:openflow:extension:nicira:match";
5     prefix "nicira-match";
6     
7     import openflow-extensible-match {prefix ofoxm;}
8     import openflow-types {prefix oft;}
9     import ietf-yang-types {prefix yang; revision-date "2010-09-24";}
10     import yang-ext {prefix ext; revision-date "2013-07-09";}
11
12     description 
13         "Nicira openflow extensions of match.";
14
15     revision "2014-04-21" {
16         description "Initial revision";
17     }
18
19     identity nxm-nx-reg {
20         base ofoxm:match-field;
21     }
22
23     identity nxm-nx-reg0 {
24         base nxm-nx-reg;
25     }
26     identity nxm-nx-reg1 {
27         base nxm-nx-reg;
28     }
29     identity nxm-nx-reg2 {
30         base nxm-nx-reg;
31     }
32     identity nxm-nx-reg3 {
33         base nxm-nx-reg;
34     }
35     identity nxm-nx-reg4 {
36         base nxm-nx-reg;
37     }
38     identity nxm-nx-reg5 {
39         base nxm-nx-reg;
40     }
41     identity nxm-nx-reg6 {
42         base nxm-nx-reg;
43     }
44     identity nxm-nx-reg7 {
45         base nxm-nx-reg;
46     }
47     identity nxm-nx-tun-id {
48         base ofoxm:match-field;
49     }
50     identity nxm-nx-arp-sha {
51         base ofoxm:match-field;
52     }
53     identity nxm-nx-arp-tha {
54         base ofoxm:match-field;
55     }
56     identity nxm-of-arp-op {
57         base ofoxm:match-field;
58     }
59     identity nxm-of-arp-spa {
60         base ofoxm:match-field;
61     }
62     identity nxm-of-arp-tpa {
63         base ofoxm:match-field;
64     }
65     identity nxm-nx-tun-ipv4-dst {
66         base ofoxm:match-field;
67     }
68     identity nxm-nx-tun-ipv4-src {
69         base ofoxm:match-field;
70     }
71     identity nxm-of-eth-src {
72         base ofoxm:match-field;
73     }
74     identity nxm-of-eth-dst {
75         base ofoxm:match-field;
76     }
77     identity nxm-of-eth-type {
78         base ofoxm:match-field;
79     }
80
81     grouping ofj-nxm-nx-match-reg-grouping {
82         container reg-values {
83             leaf value {
84                 type uint32;
85             }
86         }
87     }
88     grouping ofj-nxm-nx-match-tun-id-grouping {
89         container tun-id-values {
90             leaf value {
91                 type uint64;
92             }
93         }
94     }
95     grouping ofj-nxm-nx-match-arp-sha-grouping {
96         container arp-sha-values {
97             leaf mac-address {
98                 type yang:mac-address;
99             }
100         }
101     }
102     grouping ofj-nxm-nx-match-arp-tha-grouping {
103         container arp-tha-values {
104             leaf mac-address {
105                 type yang:mac-address;
106             }
107         }
108     }
109     grouping ofj-nxm-of-match-arp-op-grouping {
110         container arp-op-values {
111             leaf value {
112                 type uint16;
113             }
114         }
115     }
116     grouping ofj-nxm-of-match-arp-spa-grouping {
117         container arp-spa-values {
118             leaf value {
119                 type uint32;
120             }
121         }
122     }
123     grouping ofj-nxm-of-match-arp-tpa-grouping {
124         container arp-tpa-values {
125             leaf value {
126                 type uint32;
127             }
128         }
129     }
130     grouping ofj-nxm-nx-match-tun-ipv4-dst-grouping {
131         container tun-ipv4-dst-values {
132             leaf value {
133                 type uint32;
134             }
135         }
136     }
137     grouping ofj-nxm-nx-match-tun-ipv4-src-grouping {
138         container tun-ipv4-src-values {
139             leaf value {
140                 type uint32;
141             }
142         }
143     }
144     grouping ofj-nxm-of-match-eth-src-grouping {
145         container eth-src-values {
146             leaf mac-address {
147                 type yang:mac-address;
148             }
149         }
150     }
151     grouping ofj-nxm-of-match-eth-dst-grouping {
152         container eth-dst-values {
153             leaf mac-address {
154                 type yang:mac-address;
155             }
156         }
157     }
158     grouping ofj-nxm-of-match-eth-type-grouping {
159         container eth-type-values {
160             leaf value {
161                 type uint16;
162             }
163         }
164     }
165
166     augment "/ofoxm:oxm-container/ofoxm:match-entries" {
167         ext:augment-identifier "ofj-aug_nx_match";
168         uses ofj-nxm-nx-match-reg-grouping;
169         uses ofj-nxm-nx-match-tun-id-grouping;
170         uses ofj-nxm-nx-match-arp-sha-grouping;
171         uses ofj-nxm-nx-match-arp-tha-grouping;
172         uses ofj-nxm-of-match-arp-op-grouping;
173         uses ofj-nxm-of-match-arp-spa-grouping;
174         uses ofj-nxm-of-match-arp-tpa-grouping;
175         uses ofj-nxm-nx-match-tun-ipv4-dst-grouping;
176         uses ofj-nxm-nx-match-tun-ipv4-src-grouping;
177         uses ofj-nxm-of-match-eth-src-grouping;
178         uses ofj-nxm-of-match-eth-dst-grouping;
179         uses ofj-nxm-of-match-eth-type-grouping;
180     }
181
182 }