753349032fa86ca88a569a3ee87af8255d0715fb
[govpp.git] / binapi / l2 / l2.ba.go
1 // Code generated by GoVPP's binapi-generator. DO NOT EDIT.
2 // versions:
3 //  binapi-generator: v0.5.0-dev
4 //  VPP:              22.02-release
5 // source: /usr/share/vpp/api/core/l2.api.json
6
7 // Package l2 contains generated bindings for API file l2.api.
8 //
9 // Contents:
10 //   3 enums
11 //   3 structs
12 //  62 messages
13 //
14 package l2
15
16 import (
17         "strconv"
18
19         api "git.fd.io/govpp.git/api"
20         ethernet_types "git.fd.io/govpp.git/binapi/ethernet_types"
21         interface_types "git.fd.io/govpp.git/binapi/interface_types"
22         ip_types "git.fd.io/govpp.git/binapi/ip_types"
23         codec "git.fd.io/govpp.git/codec"
24 )
25
26 // This is a compile-time assertion to ensure that this generated file
27 // is compatible with the GoVPP api package it is being compiled against.
28 // A compilation error at this line likely means your copy of the
29 // GoVPP api package needs to be updated.
30 const _ = api.GoVppAPIPackageIsVersion2
31
32 const (
33         APIFile    = "l2"
34         APIVersion = "3.1.0"
35         VersionCrc = 0xfc6b8fd2
36 )
37
38 // BdFlags defines enum 'bd_flags'.
39 type BdFlags uint32
40
41 const (
42         BRIDGE_API_FLAG_NONE     BdFlags = 0
43         BRIDGE_API_FLAG_LEARN    BdFlags = 1
44         BRIDGE_API_FLAG_FWD      BdFlags = 2
45         BRIDGE_API_FLAG_FLOOD    BdFlags = 4
46         BRIDGE_API_FLAG_UU_FLOOD BdFlags = 8
47         BRIDGE_API_FLAG_ARP_TERM BdFlags = 16
48         BRIDGE_API_FLAG_ARP_UFWD BdFlags = 32
49 )
50
51 var (
52         BdFlags_name = map[uint32]string{
53                 0:  "BRIDGE_API_FLAG_NONE",
54                 1:  "BRIDGE_API_FLAG_LEARN",
55                 2:  "BRIDGE_API_FLAG_FWD",
56                 4:  "BRIDGE_API_FLAG_FLOOD",
57                 8:  "BRIDGE_API_FLAG_UU_FLOOD",
58                 16: "BRIDGE_API_FLAG_ARP_TERM",
59                 32: "BRIDGE_API_FLAG_ARP_UFWD",
60         }
61         BdFlags_value = map[string]uint32{
62                 "BRIDGE_API_FLAG_NONE":     0,
63                 "BRIDGE_API_FLAG_LEARN":    1,
64                 "BRIDGE_API_FLAG_FWD":      2,
65                 "BRIDGE_API_FLAG_FLOOD":    4,
66                 "BRIDGE_API_FLAG_UU_FLOOD": 8,
67                 "BRIDGE_API_FLAG_ARP_TERM": 16,
68                 "BRIDGE_API_FLAG_ARP_UFWD": 32,
69         }
70 )
71
72 func (x BdFlags) String() string {
73         s, ok := BdFlags_name[uint32(x)]
74         if ok {
75                 return s
76         }
77         str := func(n uint32) string {
78                 s, ok := BdFlags_name[uint32(n)]
79                 if ok {
80                         return s
81                 }
82                 return "BdFlags(" + strconv.Itoa(int(n)) + ")"
83         }
84         for i := uint32(0); i <= 32; i++ {
85                 val := uint32(x)
86                 if val&(1<<i) != 0 {
87                         if s != "" {
88                                 s += "|"
89                         }
90                         s += str(1 << i)
91                 }
92         }
93         if s == "" {
94                 return str(uint32(x))
95         }
96         return s
97 }
98
99 // L2PortType defines enum 'l2_port_type'.
100 type L2PortType uint32
101
102 const (
103         L2_API_PORT_TYPE_NORMAL L2PortType = 0
104         L2_API_PORT_TYPE_BVI    L2PortType = 1
105         L2_API_PORT_TYPE_UU_FWD L2PortType = 2
106 )
107
108 var (
109         L2PortType_name = map[uint32]string{
110                 0: "L2_API_PORT_TYPE_NORMAL",
111                 1: "L2_API_PORT_TYPE_BVI",
112                 2: "L2_API_PORT_TYPE_UU_FWD",
113         }
114         L2PortType_value = map[string]uint32{
115                 "L2_API_PORT_TYPE_NORMAL": 0,
116                 "L2_API_PORT_TYPE_BVI":    1,
117                 "L2_API_PORT_TYPE_UU_FWD": 2,
118         }
119 )
120
121 func (x L2PortType) String() string {
122         s, ok := L2PortType_name[uint32(x)]
123         if ok {
124                 return s
125         }
126         return "L2PortType(" + strconv.Itoa(int(x)) + ")"
127 }
128
129 // MacEventAction defines enum 'mac_event_action'.
130 type MacEventAction uint32
131
132 const (
133         MAC_EVENT_ACTION_API_ADD    MacEventAction = 0
134         MAC_EVENT_ACTION_API_DELETE MacEventAction = 1
135         MAC_EVENT_ACTION_API_MOVE   MacEventAction = 2
136 )
137
138 var (
139         MacEventAction_name = map[uint32]string{
140                 0: "MAC_EVENT_ACTION_API_ADD",
141                 1: "MAC_EVENT_ACTION_API_DELETE",
142                 2: "MAC_EVENT_ACTION_API_MOVE",
143         }
144         MacEventAction_value = map[string]uint32{
145                 "MAC_EVENT_ACTION_API_ADD":    0,
146                 "MAC_EVENT_ACTION_API_DELETE": 1,
147                 "MAC_EVENT_ACTION_API_MOVE":   2,
148         }
149 )
150
151 func (x MacEventAction) String() string {
152         s, ok := MacEventAction_name[uint32(x)]
153         if ok {
154                 return s
155         }
156         return "MacEventAction(" + strconv.Itoa(int(x)) + ")"
157 }
158
159 // BdIPMac defines type 'bd_ip_mac'.
160 type BdIPMac struct {
161         BdID uint32                    `binapi:"u32,name=bd_id" json:"bd_id,omitempty"`
162         IP   ip_types.Address          `binapi:"address,name=ip" json:"ip,omitempty"`
163         Mac  ethernet_types.MacAddress `binapi:"mac_address,name=mac" json:"mac,omitempty"`
164 }
165
166 // BridgeDomainSwIf defines type 'bridge_domain_sw_if'.
167 type BridgeDomainSwIf struct {
168         Context   uint32                         `binapi:"u32,name=context" json:"context,omitempty"`
169         SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
170         Shg       uint8                          `binapi:"u8,name=shg" json:"shg,omitempty"`
171 }
172
173 // MacEntry defines type 'mac_entry'.
174 type MacEntry struct {
175         SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
176         MacAddr   ethernet_types.MacAddress      `binapi:"mac_address,name=mac_addr" json:"mac_addr,omitempty"`
177         Action    MacEventAction                 `binapi:"mac_event_action,name=action" json:"action,omitempty"`
178         Flags     uint8                          `binapi:"u8,name=flags" json:"flags,omitempty"`
179 }
180
181 // BdIPMacAddDel defines message 'bd_ip_mac_add_del'.
182 type BdIPMacAddDel struct {
183         IsAdd bool    `binapi:"bool,name=is_add,default=true" json:"is_add,omitempty"`
184         Entry BdIPMac `binapi:"bd_ip_mac,name=entry" json:"entry,omitempty"`
185 }
186
187 func (m *BdIPMacAddDel) Reset()               { *m = BdIPMacAddDel{} }
188 func (*BdIPMacAddDel) GetMessageName() string { return "bd_ip_mac_add_del" }
189 func (*BdIPMacAddDel) GetCrcString() string   { return "0257c869" }
190 func (*BdIPMacAddDel) GetMessageType() api.MessageType {
191         return api.RequestMessage
192 }
193
194 func (m *BdIPMacAddDel) Size() (size int) {
195         if m == nil {
196                 return 0
197         }
198         size += 1      // m.IsAdd
199         size += 4      // m.Entry.BdID
200         size += 1      // m.Entry.IP.Af
201         size += 1 * 16 // m.Entry.IP.Un
202         size += 1 * 6  // m.Entry.Mac
203         return size
204 }
205 func (m *BdIPMacAddDel) Marshal(b []byte) ([]byte, error) {
206         if b == nil {
207                 b = make([]byte, m.Size())
208         }
209         buf := codec.NewBuffer(b)
210         buf.EncodeBool(m.IsAdd)
211         buf.EncodeUint32(m.Entry.BdID)
212         buf.EncodeUint8(uint8(m.Entry.IP.Af))
213         buf.EncodeBytes(m.Entry.IP.Un.XXX_UnionData[:], 16)
214         buf.EncodeBytes(m.Entry.Mac[:], 6)
215         return buf.Bytes(), nil
216 }
217 func (m *BdIPMacAddDel) Unmarshal(b []byte) error {
218         buf := codec.NewBuffer(b)
219         m.IsAdd = buf.DecodeBool()
220         m.Entry.BdID = buf.DecodeUint32()
221         m.Entry.IP.Af = ip_types.AddressFamily(buf.DecodeUint8())
222         copy(m.Entry.IP.Un.XXX_UnionData[:], buf.DecodeBytes(16))
223         copy(m.Entry.Mac[:], buf.DecodeBytes(6))
224         return nil
225 }
226
227 // BdIPMacAddDelReply defines message 'bd_ip_mac_add_del_reply'.
228 type BdIPMacAddDelReply struct {
229         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
230 }
231
232 func (m *BdIPMacAddDelReply) Reset()               { *m = BdIPMacAddDelReply{} }
233 func (*BdIPMacAddDelReply) GetMessageName() string { return "bd_ip_mac_add_del_reply" }
234 func (*BdIPMacAddDelReply) GetCrcString() string   { return "e8d4e804" }
235 func (*BdIPMacAddDelReply) GetMessageType() api.MessageType {
236         return api.ReplyMessage
237 }
238
239 func (m *BdIPMacAddDelReply) Size() (size int) {
240         if m == nil {
241                 return 0
242         }
243         size += 4 // m.Retval
244         return size
245 }
246 func (m *BdIPMacAddDelReply) Marshal(b []byte) ([]byte, error) {
247         if b == nil {
248                 b = make([]byte, m.Size())
249         }
250         buf := codec.NewBuffer(b)
251         buf.EncodeInt32(m.Retval)
252         return buf.Bytes(), nil
253 }
254 func (m *BdIPMacAddDelReply) Unmarshal(b []byte) error {
255         buf := codec.NewBuffer(b)
256         m.Retval = buf.DecodeInt32()
257         return nil
258 }
259
260 // BdIPMacDetails defines message 'bd_ip_mac_details'.
261 type BdIPMacDetails struct {
262         Entry BdIPMac `binapi:"bd_ip_mac,name=entry" json:"entry,omitempty"`
263 }
264
265 func (m *BdIPMacDetails) Reset()               { *m = BdIPMacDetails{} }
266 func (*BdIPMacDetails) GetMessageName() string { return "bd_ip_mac_details" }
267 func (*BdIPMacDetails) GetCrcString() string   { return "545af86a" }
268 func (*BdIPMacDetails) GetMessageType() api.MessageType {
269         return api.ReplyMessage
270 }
271
272 func (m *BdIPMacDetails) Size() (size int) {
273         if m == nil {
274                 return 0
275         }
276         size += 4      // m.Entry.BdID
277         size += 1      // m.Entry.IP.Af
278         size += 1 * 16 // m.Entry.IP.Un
279         size += 1 * 6  // m.Entry.Mac
280         return size
281 }
282 func (m *BdIPMacDetails) Marshal(b []byte) ([]byte, error) {
283         if b == nil {
284                 b = make([]byte, m.Size())
285         }
286         buf := codec.NewBuffer(b)
287         buf.EncodeUint32(m.Entry.BdID)
288         buf.EncodeUint8(uint8(m.Entry.IP.Af))
289         buf.EncodeBytes(m.Entry.IP.Un.XXX_UnionData[:], 16)
290         buf.EncodeBytes(m.Entry.Mac[:], 6)
291         return buf.Bytes(), nil
292 }
293 func (m *BdIPMacDetails) Unmarshal(b []byte) error {
294         buf := codec.NewBuffer(b)
295         m.Entry.BdID = buf.DecodeUint32()
296         m.Entry.IP.Af = ip_types.AddressFamily(buf.DecodeUint8())
297         copy(m.Entry.IP.Un.XXX_UnionData[:], buf.DecodeBytes(16))
298         copy(m.Entry.Mac[:], buf.DecodeBytes(6))
299         return nil
300 }
301
302 // BdIPMacDump defines message 'bd_ip_mac_dump'.
303 type BdIPMacDump struct {
304         BdID uint32 `binapi:"u32,name=bd_id" json:"bd_id,omitempty"`
305 }
306
307 func (m *BdIPMacDump) Reset()               { *m = BdIPMacDump{} }
308 func (*BdIPMacDump) GetMessageName() string { return "bd_ip_mac_dump" }
309 func (*BdIPMacDump) GetCrcString() string   { return "c25fdce6" }
310 func (*BdIPMacDump) GetMessageType() api.MessageType {
311         return api.RequestMessage
312 }
313
314 func (m *BdIPMacDump) Size() (size int) {
315         if m == nil {
316                 return 0
317         }
318         size += 4 // m.BdID
319         return size
320 }
321 func (m *BdIPMacDump) Marshal(b []byte) ([]byte, error) {
322         if b == nil {
323                 b = make([]byte, m.Size())
324         }
325         buf := codec.NewBuffer(b)
326         buf.EncodeUint32(m.BdID)
327         return buf.Bytes(), nil
328 }
329 func (m *BdIPMacDump) Unmarshal(b []byte) error {
330         buf := codec.NewBuffer(b)
331         m.BdID = buf.DecodeUint32()
332         return nil
333 }
334
335 // BdIPMacFlush defines message 'bd_ip_mac_flush'.
336 type BdIPMacFlush struct {
337         BdID uint32 `binapi:"u32,name=bd_id" json:"bd_id,omitempty"`
338 }
339
340 func (m *BdIPMacFlush) Reset()               { *m = BdIPMacFlush{} }
341 func (*BdIPMacFlush) GetMessageName() string { return "bd_ip_mac_flush" }
342 func (*BdIPMacFlush) GetCrcString() string   { return "c25fdce6" }
343 func (*BdIPMacFlush) GetMessageType() api.MessageType {
344         return api.RequestMessage
345 }
346
347 func (m *BdIPMacFlush) Size() (size int) {
348         if m == nil {
349                 return 0
350         }
351         size += 4 // m.BdID
352         return size
353 }
354 func (m *BdIPMacFlush) Marshal(b []byte) ([]byte, error) {
355         if b == nil {
356                 b = make([]byte, m.Size())
357         }
358         buf := codec.NewBuffer(b)
359         buf.EncodeUint32(m.BdID)
360         return buf.Bytes(), nil
361 }
362 func (m *BdIPMacFlush) Unmarshal(b []byte) error {
363         buf := codec.NewBuffer(b)
364         m.BdID = buf.DecodeUint32()
365         return nil
366 }
367
368 // BdIPMacFlushReply defines message 'bd_ip_mac_flush_reply'.
369 type BdIPMacFlushReply struct {
370         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
371 }
372
373 func (m *BdIPMacFlushReply) Reset()               { *m = BdIPMacFlushReply{} }
374 func (*BdIPMacFlushReply) GetMessageName() string { return "bd_ip_mac_flush_reply" }
375 func (*BdIPMacFlushReply) GetCrcString() string   { return "e8d4e804" }
376 func (*BdIPMacFlushReply) GetMessageType() api.MessageType {
377         return api.ReplyMessage
378 }
379
380 func (m *BdIPMacFlushReply) Size() (size int) {
381         if m == nil {
382                 return 0
383         }
384         size += 4 // m.Retval
385         return size
386 }
387 func (m *BdIPMacFlushReply) Marshal(b []byte) ([]byte, error) {
388         if b == nil {
389                 b = make([]byte, m.Size())
390         }
391         buf := codec.NewBuffer(b)
392         buf.EncodeInt32(m.Retval)
393         return buf.Bytes(), nil
394 }
395 func (m *BdIPMacFlushReply) Unmarshal(b []byte) error {
396         buf := codec.NewBuffer(b)
397         m.Retval = buf.DecodeInt32()
398         return nil
399 }
400
401 // BridgeDomainAddDel defines message 'bridge_domain_add_del'.
402 type BridgeDomainAddDel struct {
403         BdID    uint32 `binapi:"u32,name=bd_id" json:"bd_id,omitempty"`
404         Flood   bool   `binapi:"bool,name=flood" json:"flood,omitempty"`
405         UuFlood bool   `binapi:"bool,name=uu_flood" json:"uu_flood,omitempty"`
406         Forward bool   `binapi:"bool,name=forward" json:"forward,omitempty"`
407         Learn   bool   `binapi:"bool,name=learn" json:"learn,omitempty"`
408         ArpTerm bool   `binapi:"bool,name=arp_term" json:"arp_term,omitempty"`
409         ArpUfwd bool   `binapi:"bool,name=arp_ufwd" json:"arp_ufwd,omitempty"`
410         MacAge  uint8  `binapi:"u8,name=mac_age" json:"mac_age,omitempty"`
411         BdTag   string `binapi:"string[64],name=bd_tag" json:"bd_tag,omitempty"`
412         IsAdd   bool   `binapi:"bool,name=is_add,default=true" json:"is_add,omitempty"`
413 }
414
415 func (m *BridgeDomainAddDel) Reset()               { *m = BridgeDomainAddDel{} }
416 func (*BridgeDomainAddDel) GetMessageName() string { return "bridge_domain_add_del" }
417 func (*BridgeDomainAddDel) GetCrcString() string   { return "600b7170" }
418 func (*BridgeDomainAddDel) GetMessageType() api.MessageType {
419         return api.RequestMessage
420 }
421
422 func (m *BridgeDomainAddDel) Size() (size int) {
423         if m == nil {
424                 return 0
425         }
426         size += 4  // m.BdID
427         size += 1  // m.Flood
428         size += 1  // m.UuFlood
429         size += 1  // m.Forward
430         size += 1  // m.Learn
431         size += 1  // m.ArpTerm
432         size += 1  // m.ArpUfwd
433         size += 1  // m.MacAge
434         size += 64 // m.BdTag
435         size += 1  // m.IsAdd
436         return size
437 }
438 func (m *BridgeDomainAddDel) Marshal(b []byte) ([]byte, error) {
439         if b == nil {
440                 b = make([]byte, m.Size())
441         }
442         buf := codec.NewBuffer(b)
443         buf.EncodeUint32(m.BdID)
444         buf.EncodeBool(m.Flood)
445         buf.EncodeBool(m.UuFlood)
446         buf.EncodeBool(m.Forward)
447         buf.EncodeBool(m.Learn)
448         buf.EncodeBool(m.ArpTerm)
449         buf.EncodeBool(m.ArpUfwd)
450         buf.EncodeUint8(m.MacAge)
451         buf.EncodeString(m.BdTag, 64)
452         buf.EncodeBool(m.IsAdd)
453         return buf.Bytes(), nil
454 }
455 func (m *BridgeDomainAddDel) Unmarshal(b []byte) error {
456         buf := codec.NewBuffer(b)
457         m.BdID = buf.DecodeUint32()
458         m.Flood = buf.DecodeBool()
459         m.UuFlood = buf.DecodeBool()
460         m.Forward = buf.DecodeBool()
461         m.Learn = buf.DecodeBool()
462         m.ArpTerm = buf.DecodeBool()
463         m.ArpUfwd = buf.DecodeBool()
464         m.MacAge = buf.DecodeUint8()
465         m.BdTag = buf.DecodeString(64)
466         m.IsAdd = buf.DecodeBool()
467         return nil
468 }
469
470 // BridgeDomainAddDelReply defines message 'bridge_domain_add_del_reply'.
471 type BridgeDomainAddDelReply struct {
472         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
473 }
474
475 func (m *BridgeDomainAddDelReply) Reset()               { *m = BridgeDomainAddDelReply{} }
476 func (*BridgeDomainAddDelReply) GetMessageName() string { return "bridge_domain_add_del_reply" }
477 func (*BridgeDomainAddDelReply) GetCrcString() string   { return "e8d4e804" }
478 func (*BridgeDomainAddDelReply) GetMessageType() api.MessageType {
479         return api.ReplyMessage
480 }
481
482 func (m *BridgeDomainAddDelReply) Size() (size int) {
483         if m == nil {
484                 return 0
485         }
486         size += 4 // m.Retval
487         return size
488 }
489 func (m *BridgeDomainAddDelReply) Marshal(b []byte) ([]byte, error) {
490         if b == nil {
491                 b = make([]byte, m.Size())
492         }
493         buf := codec.NewBuffer(b)
494         buf.EncodeInt32(m.Retval)
495         return buf.Bytes(), nil
496 }
497 func (m *BridgeDomainAddDelReply) Unmarshal(b []byte) error {
498         buf := codec.NewBuffer(b)
499         m.Retval = buf.DecodeInt32()
500         return nil
501 }
502
503 // BridgeDomainDetails defines message 'bridge_domain_details'.
504 type BridgeDomainDetails struct {
505         BdID           uint32                         `binapi:"u32,name=bd_id" json:"bd_id,omitempty"`
506         Flood          bool                           `binapi:"bool,name=flood" json:"flood,omitempty"`
507         UuFlood        bool                           `binapi:"bool,name=uu_flood" json:"uu_flood,omitempty"`
508         Forward        bool                           `binapi:"bool,name=forward" json:"forward,omitempty"`
509         Learn          bool                           `binapi:"bool,name=learn" json:"learn,omitempty"`
510         ArpTerm        bool                           `binapi:"bool,name=arp_term" json:"arp_term,omitempty"`
511         ArpUfwd        bool                           `binapi:"bool,name=arp_ufwd" json:"arp_ufwd,omitempty"`
512         MacAge         uint8                          `binapi:"u8,name=mac_age" json:"mac_age,omitempty"`
513         BdTag          string                         `binapi:"string[64],name=bd_tag" json:"bd_tag,omitempty"`
514         BviSwIfIndex   interface_types.InterfaceIndex `binapi:"interface_index,name=bvi_sw_if_index" json:"bvi_sw_if_index,omitempty"`
515         UuFwdSwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=uu_fwd_sw_if_index" json:"uu_fwd_sw_if_index,omitempty"`
516         NSwIfs         uint32                         `binapi:"u32,name=n_sw_ifs" json:"-"`
517         SwIfDetails    []BridgeDomainSwIf             `binapi:"bridge_domain_sw_if[n_sw_ifs],name=sw_if_details" json:"sw_if_details,omitempty"`
518 }
519
520 func (m *BridgeDomainDetails) Reset()               { *m = BridgeDomainDetails{} }
521 func (*BridgeDomainDetails) GetMessageName() string { return "bridge_domain_details" }
522 func (*BridgeDomainDetails) GetCrcString() string   { return "0fa506fd" }
523 func (*BridgeDomainDetails) GetMessageType() api.MessageType {
524         return api.ReplyMessage
525 }
526
527 func (m *BridgeDomainDetails) Size() (size int) {
528         if m == nil {
529                 return 0
530         }
531         size += 4  // m.BdID
532         size += 1  // m.Flood
533         size += 1  // m.UuFlood
534         size += 1  // m.Forward
535         size += 1  // m.Learn
536         size += 1  // m.ArpTerm
537         size += 1  // m.ArpUfwd
538         size += 1  // m.MacAge
539         size += 64 // m.BdTag
540         size += 4  // m.BviSwIfIndex
541         size += 4  // m.UuFwdSwIfIndex
542         size += 4  // m.NSwIfs
543         for j1 := 0; j1 < len(m.SwIfDetails); j1++ {
544                 var s1 BridgeDomainSwIf
545                 _ = s1
546                 if j1 < len(m.SwIfDetails) {
547                         s1 = m.SwIfDetails[j1]
548                 }
549                 size += 4 // s1.Context
550                 size += 4 // s1.SwIfIndex
551                 size += 1 // s1.Shg
552         }
553         return size
554 }
555 func (m *BridgeDomainDetails) Marshal(b []byte) ([]byte, error) {
556         if b == nil {
557                 b = make([]byte, m.Size())
558         }
559         buf := codec.NewBuffer(b)
560         buf.EncodeUint32(m.BdID)
561         buf.EncodeBool(m.Flood)
562         buf.EncodeBool(m.UuFlood)
563         buf.EncodeBool(m.Forward)
564         buf.EncodeBool(m.Learn)
565         buf.EncodeBool(m.ArpTerm)
566         buf.EncodeBool(m.ArpUfwd)
567         buf.EncodeUint8(m.MacAge)
568         buf.EncodeString(m.BdTag, 64)
569         buf.EncodeUint32(uint32(m.BviSwIfIndex))
570         buf.EncodeUint32(uint32(m.UuFwdSwIfIndex))
571         buf.EncodeUint32(uint32(len(m.SwIfDetails)))
572         for j0 := 0; j0 < len(m.SwIfDetails); j0++ {
573                 var v0 BridgeDomainSwIf // SwIfDetails
574                 if j0 < len(m.SwIfDetails) {
575                         v0 = m.SwIfDetails[j0]
576                 }
577                 buf.EncodeUint32(v0.Context)
578                 buf.EncodeUint32(uint32(v0.SwIfIndex))
579                 buf.EncodeUint8(v0.Shg)
580         }
581         return buf.Bytes(), nil
582 }
583 func (m *BridgeDomainDetails) Unmarshal(b []byte) error {
584         buf := codec.NewBuffer(b)
585         m.BdID = buf.DecodeUint32()
586         m.Flood = buf.DecodeBool()
587         m.UuFlood = buf.DecodeBool()
588         m.Forward = buf.DecodeBool()
589         m.Learn = buf.DecodeBool()
590         m.ArpTerm = buf.DecodeBool()
591         m.ArpUfwd = buf.DecodeBool()
592         m.MacAge = buf.DecodeUint8()
593         m.BdTag = buf.DecodeString(64)
594         m.BviSwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
595         m.UuFwdSwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
596         m.NSwIfs = buf.DecodeUint32()
597         m.SwIfDetails = make([]BridgeDomainSwIf, m.NSwIfs)
598         for j0 := 0; j0 < len(m.SwIfDetails); j0++ {
599                 m.SwIfDetails[j0].Context = buf.DecodeUint32()
600                 m.SwIfDetails[j0].SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
601                 m.SwIfDetails[j0].Shg = buf.DecodeUint8()
602         }
603         return nil
604 }
605
606 // BridgeDomainDump defines message 'bridge_domain_dump'.
607 type BridgeDomainDump struct {
608         BdID      uint32                         `binapi:"u32,name=bd_id,default=4294967295" json:"bd_id,omitempty"`
609         SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index,default=4294967295" json:"sw_if_index,omitempty"`
610 }
611
612 func (m *BridgeDomainDump) Reset()               { *m = BridgeDomainDump{} }
613 func (*BridgeDomainDump) GetMessageName() string { return "bridge_domain_dump" }
614 func (*BridgeDomainDump) GetCrcString() string   { return "74396a43" }
615 func (*BridgeDomainDump) GetMessageType() api.MessageType {
616         return api.RequestMessage
617 }
618
619 func (m *BridgeDomainDump) Size() (size int) {
620         if m == nil {
621                 return 0
622         }
623         size += 4 // m.BdID
624         size += 4 // m.SwIfIndex
625         return size
626 }
627 func (m *BridgeDomainDump) Marshal(b []byte) ([]byte, error) {
628         if b == nil {
629                 b = make([]byte, m.Size())
630         }
631         buf := codec.NewBuffer(b)
632         buf.EncodeUint32(m.BdID)
633         buf.EncodeUint32(uint32(m.SwIfIndex))
634         return buf.Bytes(), nil
635 }
636 func (m *BridgeDomainDump) Unmarshal(b []byte) error {
637         buf := codec.NewBuffer(b)
638         m.BdID = buf.DecodeUint32()
639         m.SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
640         return nil
641 }
642
643 // BridgeDomainSetDefaultLearnLimit defines message 'bridge_domain_set_default_learn_limit'.
644 type BridgeDomainSetDefaultLearnLimit struct {
645         LearnLimit uint32 `binapi:"u32,name=learn_limit" json:"learn_limit,omitempty"`
646 }
647
648 func (m *BridgeDomainSetDefaultLearnLimit) Reset() { *m = BridgeDomainSetDefaultLearnLimit{} }
649 func (*BridgeDomainSetDefaultLearnLimit) GetMessageName() string {
650         return "bridge_domain_set_default_learn_limit"
651 }
652 func (*BridgeDomainSetDefaultLearnLimit) GetCrcString() string { return "f097ffce" }
653 func (*BridgeDomainSetDefaultLearnLimit) GetMessageType() api.MessageType {
654         return api.RequestMessage
655 }
656
657 func (m *BridgeDomainSetDefaultLearnLimit) Size() (size int) {
658         if m == nil {
659                 return 0
660         }
661         size += 4 // m.LearnLimit
662         return size
663 }
664 func (m *BridgeDomainSetDefaultLearnLimit) Marshal(b []byte) ([]byte, error) {
665         if b == nil {
666                 b = make([]byte, m.Size())
667         }
668         buf := codec.NewBuffer(b)
669         buf.EncodeUint32(m.LearnLimit)
670         return buf.Bytes(), nil
671 }
672 func (m *BridgeDomainSetDefaultLearnLimit) Unmarshal(b []byte) error {
673         buf := codec.NewBuffer(b)
674         m.LearnLimit = buf.DecodeUint32()
675         return nil
676 }
677
678 // BridgeDomainSetDefaultLearnLimitReply defines message 'bridge_domain_set_default_learn_limit_reply'.
679 type BridgeDomainSetDefaultLearnLimitReply struct {
680         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
681 }
682
683 func (m *BridgeDomainSetDefaultLearnLimitReply) Reset() { *m = BridgeDomainSetDefaultLearnLimitReply{} }
684 func (*BridgeDomainSetDefaultLearnLimitReply) GetMessageName() string {
685         return "bridge_domain_set_default_learn_limit_reply"
686 }
687 func (*BridgeDomainSetDefaultLearnLimitReply) GetCrcString() string { return "e8d4e804" }
688 func (*BridgeDomainSetDefaultLearnLimitReply) GetMessageType() api.MessageType {
689         return api.ReplyMessage
690 }
691
692 func (m *BridgeDomainSetDefaultLearnLimitReply) Size() (size int) {
693         if m == nil {
694                 return 0
695         }
696         size += 4 // m.Retval
697         return size
698 }
699 func (m *BridgeDomainSetDefaultLearnLimitReply) Marshal(b []byte) ([]byte, error) {
700         if b == nil {
701                 b = make([]byte, m.Size())
702         }
703         buf := codec.NewBuffer(b)
704         buf.EncodeInt32(m.Retval)
705         return buf.Bytes(), nil
706 }
707 func (m *BridgeDomainSetDefaultLearnLimitReply) Unmarshal(b []byte) error {
708         buf := codec.NewBuffer(b)
709         m.Retval = buf.DecodeInt32()
710         return nil
711 }
712
713 // BridgeDomainSetLearnLimit defines message 'bridge_domain_set_learn_limit'.
714 type BridgeDomainSetLearnLimit struct {
715         BdID       uint32 `binapi:"u32,name=bd_id" json:"bd_id,omitempty"`
716         LearnLimit uint32 `binapi:"u32,name=learn_limit" json:"learn_limit,omitempty"`
717 }
718
719 func (m *BridgeDomainSetLearnLimit) Reset()               { *m = BridgeDomainSetLearnLimit{} }
720 func (*BridgeDomainSetLearnLimit) GetMessageName() string { return "bridge_domain_set_learn_limit" }
721 func (*BridgeDomainSetLearnLimit) GetCrcString() string   { return "89c52b5f" }
722 func (*BridgeDomainSetLearnLimit) GetMessageType() api.MessageType {
723         return api.RequestMessage
724 }
725
726 func (m *BridgeDomainSetLearnLimit) Size() (size int) {
727         if m == nil {
728                 return 0
729         }
730         size += 4 // m.BdID
731         size += 4 // m.LearnLimit
732         return size
733 }
734 func (m *BridgeDomainSetLearnLimit) Marshal(b []byte) ([]byte, error) {
735         if b == nil {
736                 b = make([]byte, m.Size())
737         }
738         buf := codec.NewBuffer(b)
739         buf.EncodeUint32(m.BdID)
740         buf.EncodeUint32(m.LearnLimit)
741         return buf.Bytes(), nil
742 }
743 func (m *BridgeDomainSetLearnLimit) Unmarshal(b []byte) error {
744         buf := codec.NewBuffer(b)
745         m.BdID = buf.DecodeUint32()
746         m.LearnLimit = buf.DecodeUint32()
747         return nil
748 }
749
750 // BridgeDomainSetLearnLimitReply defines message 'bridge_domain_set_learn_limit_reply'.
751 type BridgeDomainSetLearnLimitReply struct {
752         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
753 }
754
755 func (m *BridgeDomainSetLearnLimitReply) Reset() { *m = BridgeDomainSetLearnLimitReply{} }
756 func (*BridgeDomainSetLearnLimitReply) GetMessageName() string {
757         return "bridge_domain_set_learn_limit_reply"
758 }
759 func (*BridgeDomainSetLearnLimitReply) GetCrcString() string { return "e8d4e804" }
760 func (*BridgeDomainSetLearnLimitReply) GetMessageType() api.MessageType {
761         return api.ReplyMessage
762 }
763
764 func (m *BridgeDomainSetLearnLimitReply) Size() (size int) {
765         if m == nil {
766                 return 0
767         }
768         size += 4 // m.Retval
769         return size
770 }
771 func (m *BridgeDomainSetLearnLimitReply) Marshal(b []byte) ([]byte, error) {
772         if b == nil {
773                 b = make([]byte, m.Size())
774         }
775         buf := codec.NewBuffer(b)
776         buf.EncodeInt32(m.Retval)
777         return buf.Bytes(), nil
778 }
779 func (m *BridgeDomainSetLearnLimitReply) Unmarshal(b []byte) error {
780         buf := codec.NewBuffer(b)
781         m.Retval = buf.DecodeInt32()
782         return nil
783 }
784
785 // BridgeDomainSetMacAge defines message 'bridge_domain_set_mac_age'.
786 type BridgeDomainSetMacAge struct {
787         BdID   uint32 `binapi:"u32,name=bd_id" json:"bd_id,omitempty"`
788         MacAge uint8  `binapi:"u8,name=mac_age" json:"mac_age,omitempty"`
789 }
790
791 func (m *BridgeDomainSetMacAge) Reset()               { *m = BridgeDomainSetMacAge{} }
792 func (*BridgeDomainSetMacAge) GetMessageName() string { return "bridge_domain_set_mac_age" }
793 func (*BridgeDomainSetMacAge) GetCrcString() string   { return "b537ad7b" }
794 func (*BridgeDomainSetMacAge) GetMessageType() api.MessageType {
795         return api.RequestMessage
796 }
797
798 func (m *BridgeDomainSetMacAge) Size() (size int) {
799         if m == nil {
800                 return 0
801         }
802         size += 4 // m.BdID
803         size += 1 // m.MacAge
804         return size
805 }
806 func (m *BridgeDomainSetMacAge) Marshal(b []byte) ([]byte, error) {
807         if b == nil {
808                 b = make([]byte, m.Size())
809         }
810         buf := codec.NewBuffer(b)
811         buf.EncodeUint32(m.BdID)
812         buf.EncodeUint8(m.MacAge)
813         return buf.Bytes(), nil
814 }
815 func (m *BridgeDomainSetMacAge) Unmarshal(b []byte) error {
816         buf := codec.NewBuffer(b)
817         m.BdID = buf.DecodeUint32()
818         m.MacAge = buf.DecodeUint8()
819         return nil
820 }
821
822 // BridgeDomainSetMacAgeReply defines message 'bridge_domain_set_mac_age_reply'.
823 type BridgeDomainSetMacAgeReply struct {
824         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
825 }
826
827 func (m *BridgeDomainSetMacAgeReply) Reset()               { *m = BridgeDomainSetMacAgeReply{} }
828 func (*BridgeDomainSetMacAgeReply) GetMessageName() string { return "bridge_domain_set_mac_age_reply" }
829 func (*BridgeDomainSetMacAgeReply) GetCrcString() string   { return "e8d4e804" }
830 func (*BridgeDomainSetMacAgeReply) GetMessageType() api.MessageType {
831         return api.ReplyMessage
832 }
833
834 func (m *BridgeDomainSetMacAgeReply) Size() (size int) {
835         if m == nil {
836                 return 0
837         }
838         size += 4 // m.Retval
839         return size
840 }
841 func (m *BridgeDomainSetMacAgeReply) Marshal(b []byte) ([]byte, error) {
842         if b == nil {
843                 b = make([]byte, m.Size())
844         }
845         buf := codec.NewBuffer(b)
846         buf.EncodeInt32(m.Retval)
847         return buf.Bytes(), nil
848 }
849 func (m *BridgeDomainSetMacAgeReply) Unmarshal(b []byte) error {
850         buf := codec.NewBuffer(b)
851         m.Retval = buf.DecodeInt32()
852         return nil
853 }
854
855 // BridgeFlags defines message 'bridge_flags'.
856 type BridgeFlags struct {
857         BdID  uint32  `binapi:"u32,name=bd_id" json:"bd_id,omitempty"`
858         IsSet bool    `binapi:"bool,name=is_set" json:"is_set,omitempty"`
859         Flags BdFlags `binapi:"bd_flags,name=flags" json:"flags,omitempty"`
860 }
861
862 func (m *BridgeFlags) Reset()               { *m = BridgeFlags{} }
863 func (*BridgeFlags) GetMessageName() string { return "bridge_flags" }
864 func (*BridgeFlags) GetCrcString() string   { return "1b0c5fbd" }
865 func (*BridgeFlags) GetMessageType() api.MessageType {
866         return api.RequestMessage
867 }
868
869 func (m *BridgeFlags) Size() (size int) {
870         if m == nil {
871                 return 0
872         }
873         size += 4 // m.BdID
874         size += 1 // m.IsSet
875         size += 4 // m.Flags
876         return size
877 }
878 func (m *BridgeFlags) Marshal(b []byte) ([]byte, error) {
879         if b == nil {
880                 b = make([]byte, m.Size())
881         }
882         buf := codec.NewBuffer(b)
883         buf.EncodeUint32(m.BdID)
884         buf.EncodeBool(m.IsSet)
885         buf.EncodeUint32(uint32(m.Flags))
886         return buf.Bytes(), nil
887 }
888 func (m *BridgeFlags) Unmarshal(b []byte) error {
889         buf := codec.NewBuffer(b)
890         m.BdID = buf.DecodeUint32()
891         m.IsSet = buf.DecodeBool()
892         m.Flags = BdFlags(buf.DecodeUint32())
893         return nil
894 }
895
896 // BridgeFlagsReply defines message 'bridge_flags_reply'.
897 type BridgeFlagsReply struct {
898         Retval                 int32  `binapi:"i32,name=retval" json:"retval,omitempty"`
899         ResultingFeatureBitmap uint32 `binapi:"u32,name=resulting_feature_bitmap" json:"resulting_feature_bitmap,omitempty"`
900 }
901
902 func (m *BridgeFlagsReply) Reset()               { *m = BridgeFlagsReply{} }
903 func (*BridgeFlagsReply) GetMessageName() string { return "bridge_flags_reply" }
904 func (*BridgeFlagsReply) GetCrcString() string   { return "29b2a2b3" }
905 func (*BridgeFlagsReply) GetMessageType() api.MessageType {
906         return api.ReplyMessage
907 }
908
909 func (m *BridgeFlagsReply) Size() (size int) {
910         if m == nil {
911                 return 0
912         }
913         size += 4 // m.Retval
914         size += 4 // m.ResultingFeatureBitmap
915         return size
916 }
917 func (m *BridgeFlagsReply) Marshal(b []byte) ([]byte, error) {
918         if b == nil {
919                 b = make([]byte, m.Size())
920         }
921         buf := codec.NewBuffer(b)
922         buf.EncodeInt32(m.Retval)
923         buf.EncodeUint32(m.ResultingFeatureBitmap)
924         return buf.Bytes(), nil
925 }
926 func (m *BridgeFlagsReply) Unmarshal(b []byte) error {
927         buf := codec.NewBuffer(b)
928         m.Retval = buf.DecodeInt32()
929         m.ResultingFeatureBitmap = buf.DecodeUint32()
930         return nil
931 }
932
933 // BviCreate defines message 'bvi_create'.
934 type BviCreate struct {
935         Mac          ethernet_types.MacAddress `binapi:"mac_address,name=mac" json:"mac,omitempty"`
936         UserInstance uint32                    `binapi:"u32,name=user_instance,default=4294967295" json:"user_instance,omitempty"`
937 }
938
939 func (m *BviCreate) Reset()               { *m = BviCreate{} }
940 func (*BviCreate) GetMessageName() string { return "bvi_create" }
941 func (*BviCreate) GetCrcString() string   { return "f5398559" }
942 func (*BviCreate) GetMessageType() api.MessageType {
943         return api.RequestMessage
944 }
945
946 func (m *BviCreate) Size() (size int) {
947         if m == nil {
948                 return 0
949         }
950         size += 1 * 6 // m.Mac
951         size += 4     // m.UserInstance
952         return size
953 }
954 func (m *BviCreate) Marshal(b []byte) ([]byte, error) {
955         if b == nil {
956                 b = make([]byte, m.Size())
957         }
958         buf := codec.NewBuffer(b)
959         buf.EncodeBytes(m.Mac[:], 6)
960         buf.EncodeUint32(m.UserInstance)
961         return buf.Bytes(), nil
962 }
963 func (m *BviCreate) Unmarshal(b []byte) error {
964         buf := codec.NewBuffer(b)
965         copy(m.Mac[:], buf.DecodeBytes(6))
966         m.UserInstance = buf.DecodeUint32()
967         return nil
968 }
969
970 // BviCreateReply defines message 'bvi_create_reply'.
971 type BviCreateReply struct {
972         Retval    int32                          `binapi:"i32,name=retval" json:"retval,omitempty"`
973         SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
974 }
975
976 func (m *BviCreateReply) Reset()               { *m = BviCreateReply{} }
977 func (*BviCreateReply) GetMessageName() string { return "bvi_create_reply" }
978 func (*BviCreateReply) GetCrcString() string   { return "5383d31f" }
979 func (*BviCreateReply) GetMessageType() api.MessageType {
980         return api.ReplyMessage
981 }
982
983 func (m *BviCreateReply) Size() (size int) {
984         if m == nil {
985                 return 0
986         }
987         size += 4 // m.Retval
988         size += 4 // m.SwIfIndex
989         return size
990 }
991 func (m *BviCreateReply) Marshal(b []byte) ([]byte, error) {
992         if b == nil {
993                 b = make([]byte, m.Size())
994         }
995         buf := codec.NewBuffer(b)
996         buf.EncodeInt32(m.Retval)
997         buf.EncodeUint32(uint32(m.SwIfIndex))
998         return buf.Bytes(), nil
999 }
1000 func (m *BviCreateReply) Unmarshal(b []byte) error {
1001         buf := codec.NewBuffer(b)
1002         m.Retval = buf.DecodeInt32()
1003         m.SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
1004         return nil
1005 }
1006
1007 // BviDelete defines message 'bvi_delete'.
1008 type BviDelete struct {
1009         SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
1010 }
1011
1012 func (m *BviDelete) Reset()               { *m = BviDelete{} }
1013 func (*BviDelete) GetMessageName() string { return "bvi_delete" }
1014 func (*BviDelete) GetCrcString() string   { return "f9e6675e" }
1015 func (*BviDelete) GetMessageType() api.MessageType {
1016         return api.RequestMessage
1017 }
1018
1019 func (m *BviDelete) Size() (size int) {
1020         if m == nil {
1021                 return 0
1022         }
1023         size += 4 // m.SwIfIndex
1024         return size
1025 }
1026 func (m *BviDelete) Marshal(b []byte) ([]byte, error) {
1027         if b == nil {
1028                 b = make([]byte, m.Size())
1029         }
1030         buf := codec.NewBuffer(b)
1031         buf.EncodeUint32(uint32(m.SwIfIndex))
1032         return buf.Bytes(), nil
1033 }
1034 func (m *BviDelete) Unmarshal(b []byte) error {
1035         buf := codec.NewBuffer(b)
1036         m.SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
1037         return nil
1038 }
1039
1040 // BviDeleteReply defines message 'bvi_delete_reply'.
1041 type BviDeleteReply struct {
1042         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
1043 }
1044
1045 func (m *BviDeleteReply) Reset()               { *m = BviDeleteReply{} }
1046 func (*BviDeleteReply) GetMessageName() string { return "bvi_delete_reply" }
1047 func (*BviDeleteReply) GetCrcString() string   { return "e8d4e804" }
1048 func (*BviDeleteReply) GetMessageType() api.MessageType {
1049         return api.ReplyMessage
1050 }
1051
1052 func (m *BviDeleteReply) Size() (size int) {
1053         if m == nil {
1054                 return 0
1055         }
1056         size += 4 // m.Retval
1057         return size
1058 }
1059 func (m *BviDeleteReply) Marshal(b []byte) ([]byte, error) {
1060         if b == nil {
1061                 b = make([]byte, m.Size())
1062         }
1063         buf := codec.NewBuffer(b)
1064         buf.EncodeInt32(m.Retval)
1065         return buf.Bytes(), nil
1066 }
1067 func (m *BviDeleteReply) Unmarshal(b []byte) error {
1068         buf := codec.NewBuffer(b)
1069         m.Retval = buf.DecodeInt32()
1070         return nil
1071 }
1072
1073 // L2ArpTermEvent defines message 'l2_arp_term_event'.
1074 type L2ArpTermEvent struct {
1075         PID       uint32                         `binapi:"u32,name=pid" json:"pid,omitempty"`
1076         IP        ip_types.Address               `binapi:"address,name=ip" json:"ip,omitempty"`
1077         SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
1078         Mac       ethernet_types.MacAddress      `binapi:"mac_address,name=mac" json:"mac,omitempty"`
1079 }
1080
1081 func (m *L2ArpTermEvent) Reset()               { *m = L2ArpTermEvent{} }
1082 func (*L2ArpTermEvent) GetMessageName() string { return "l2_arp_term_event" }
1083 func (*L2ArpTermEvent) GetCrcString() string   { return "6963e07a" }
1084 func (*L2ArpTermEvent) GetMessageType() api.MessageType {
1085         return api.EventMessage
1086 }
1087
1088 func (m *L2ArpTermEvent) Size() (size int) {
1089         if m == nil {
1090                 return 0
1091         }
1092         size += 4      // m.PID
1093         size += 1      // m.IP.Af
1094         size += 1 * 16 // m.IP.Un
1095         size += 4      // m.SwIfIndex
1096         size += 1 * 6  // m.Mac
1097         return size
1098 }
1099 func (m *L2ArpTermEvent) Marshal(b []byte) ([]byte, error) {
1100         if b == nil {
1101                 b = make([]byte, m.Size())
1102         }
1103         buf := codec.NewBuffer(b)
1104         buf.EncodeUint32(m.PID)
1105         buf.EncodeUint8(uint8(m.IP.Af))
1106         buf.EncodeBytes(m.IP.Un.XXX_UnionData[:], 16)
1107         buf.EncodeUint32(uint32(m.SwIfIndex))
1108         buf.EncodeBytes(m.Mac[:], 6)
1109         return buf.Bytes(), nil
1110 }
1111 func (m *L2ArpTermEvent) Unmarshal(b []byte) error {
1112         buf := codec.NewBuffer(b)
1113         m.PID = buf.DecodeUint32()
1114         m.IP.Af = ip_types.AddressFamily(buf.DecodeUint8())
1115         copy(m.IP.Un.XXX_UnionData[:], buf.DecodeBytes(16))
1116         m.SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
1117         copy(m.Mac[:], buf.DecodeBytes(6))
1118         return nil
1119 }
1120
1121 // L2FibClearTable defines message 'l2_fib_clear_table'.
1122 type L2FibClearTable struct{}
1123
1124 func (m *L2FibClearTable) Reset()               { *m = L2FibClearTable{} }
1125 func (*L2FibClearTable) GetMessageName() string { return "l2_fib_clear_table" }
1126 func (*L2FibClearTable) GetCrcString() string   { return "51077d14" }
1127 func (*L2FibClearTable) GetMessageType() api.MessageType {
1128         return api.RequestMessage
1129 }
1130
1131 func (m *L2FibClearTable) Size() (size int) {
1132         if m == nil {
1133                 return 0
1134         }
1135         return size
1136 }
1137 func (m *L2FibClearTable) Marshal(b []byte) ([]byte, error) {
1138         if b == nil {
1139                 b = make([]byte, m.Size())
1140         }
1141         buf := codec.NewBuffer(b)
1142         return buf.Bytes(), nil
1143 }
1144 func (m *L2FibClearTable) Unmarshal(b []byte) error {
1145         return nil
1146 }
1147
1148 // L2FibClearTableReply defines message 'l2_fib_clear_table_reply'.
1149 type L2FibClearTableReply struct {
1150         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
1151 }
1152
1153 func (m *L2FibClearTableReply) Reset()               { *m = L2FibClearTableReply{} }
1154 func (*L2FibClearTableReply) GetMessageName() string { return "l2_fib_clear_table_reply" }
1155 func (*L2FibClearTableReply) GetCrcString() string   { return "e8d4e804" }
1156 func (*L2FibClearTableReply) GetMessageType() api.MessageType {
1157         return api.ReplyMessage
1158 }
1159
1160 func (m *L2FibClearTableReply) Size() (size int) {
1161         if m == nil {
1162                 return 0
1163         }
1164         size += 4 // m.Retval
1165         return size
1166 }
1167 func (m *L2FibClearTableReply) Marshal(b []byte) ([]byte, error) {
1168         if b == nil {
1169                 b = make([]byte, m.Size())
1170         }
1171         buf := codec.NewBuffer(b)
1172         buf.EncodeInt32(m.Retval)
1173         return buf.Bytes(), nil
1174 }
1175 func (m *L2FibClearTableReply) Unmarshal(b []byte) error {
1176         buf := codec.NewBuffer(b)
1177         m.Retval = buf.DecodeInt32()
1178         return nil
1179 }
1180
1181 // L2FibTableDetails defines message 'l2_fib_table_details'.
1182 type L2FibTableDetails struct {
1183         BdID      uint32                         `binapi:"u32,name=bd_id" json:"bd_id,omitempty"`
1184         Mac       ethernet_types.MacAddress      `binapi:"mac_address,name=mac" json:"mac,omitempty"`
1185         SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
1186         StaticMac bool                           `binapi:"bool,name=static_mac" json:"static_mac,omitempty"`
1187         FilterMac bool                           `binapi:"bool,name=filter_mac" json:"filter_mac,omitempty"`
1188         BviMac    bool                           `binapi:"bool,name=bvi_mac" json:"bvi_mac,omitempty"`
1189 }
1190
1191 func (m *L2FibTableDetails) Reset()               { *m = L2FibTableDetails{} }
1192 func (*L2FibTableDetails) GetMessageName() string { return "l2_fib_table_details" }
1193 func (*L2FibTableDetails) GetCrcString() string   { return "a44ef6b8" }
1194 func (*L2FibTableDetails) GetMessageType() api.MessageType {
1195         return api.ReplyMessage
1196 }
1197
1198 func (m *L2FibTableDetails) Size() (size int) {
1199         if m == nil {
1200                 return 0
1201         }
1202         size += 4     // m.BdID
1203         size += 1 * 6 // m.Mac
1204         size += 4     // m.SwIfIndex
1205         size += 1     // m.StaticMac
1206         size += 1     // m.FilterMac
1207         size += 1     // m.BviMac
1208         return size
1209 }
1210 func (m *L2FibTableDetails) Marshal(b []byte) ([]byte, error) {
1211         if b == nil {
1212                 b = make([]byte, m.Size())
1213         }
1214         buf := codec.NewBuffer(b)
1215         buf.EncodeUint32(m.BdID)
1216         buf.EncodeBytes(m.Mac[:], 6)
1217         buf.EncodeUint32(uint32(m.SwIfIndex))
1218         buf.EncodeBool(m.StaticMac)
1219         buf.EncodeBool(m.FilterMac)
1220         buf.EncodeBool(m.BviMac)
1221         return buf.Bytes(), nil
1222 }
1223 func (m *L2FibTableDetails) Unmarshal(b []byte) error {
1224         buf := codec.NewBuffer(b)
1225         m.BdID = buf.DecodeUint32()
1226         copy(m.Mac[:], buf.DecodeBytes(6))
1227         m.SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
1228         m.StaticMac = buf.DecodeBool()
1229         m.FilterMac = buf.DecodeBool()
1230         m.BviMac = buf.DecodeBool()
1231         return nil
1232 }
1233
1234 // L2FibTableDump defines message 'l2_fib_table_dump'.
1235 type L2FibTableDump struct {
1236         BdID uint32 `binapi:"u32,name=bd_id" json:"bd_id,omitempty"`
1237 }
1238
1239 func (m *L2FibTableDump) Reset()               { *m = L2FibTableDump{} }
1240 func (*L2FibTableDump) GetMessageName() string { return "l2_fib_table_dump" }
1241 func (*L2FibTableDump) GetCrcString() string   { return "c25fdce6" }
1242 func (*L2FibTableDump) GetMessageType() api.MessageType {
1243         return api.RequestMessage
1244 }
1245
1246 func (m *L2FibTableDump) Size() (size int) {
1247         if m == nil {
1248                 return 0
1249         }
1250         size += 4 // m.BdID
1251         return size
1252 }
1253 func (m *L2FibTableDump) Marshal(b []byte) ([]byte, error) {
1254         if b == nil {
1255                 b = make([]byte, m.Size())
1256         }
1257         buf := codec.NewBuffer(b)
1258         buf.EncodeUint32(m.BdID)
1259         return buf.Bytes(), nil
1260 }
1261 func (m *L2FibTableDump) Unmarshal(b []byte) error {
1262         buf := codec.NewBuffer(b)
1263         m.BdID = buf.DecodeUint32()
1264         return nil
1265 }
1266
1267 // L2Flags defines message 'l2_flags'.
1268 type L2Flags struct {
1269         SwIfIndex     interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
1270         IsSet         bool                           `binapi:"bool,name=is_set" json:"is_set,omitempty"`
1271         FeatureBitmap uint32                         `binapi:"u32,name=feature_bitmap" json:"feature_bitmap,omitempty"`
1272 }
1273
1274 func (m *L2Flags) Reset()               { *m = L2Flags{} }
1275 func (*L2Flags) GetMessageName() string { return "l2_flags" }
1276 func (*L2Flags) GetCrcString() string   { return "fc41cfe8" }
1277 func (*L2Flags) GetMessageType() api.MessageType {
1278         return api.RequestMessage
1279 }
1280
1281 func (m *L2Flags) Size() (size int) {
1282         if m == nil {
1283                 return 0
1284         }
1285         size += 4 // m.SwIfIndex
1286         size += 1 // m.IsSet
1287         size += 4 // m.FeatureBitmap
1288         return size
1289 }
1290 func (m *L2Flags) Marshal(b []byte) ([]byte, error) {
1291         if b == nil {
1292                 b = make([]byte, m.Size())
1293         }
1294         buf := codec.NewBuffer(b)
1295         buf.EncodeUint32(uint32(m.SwIfIndex))
1296         buf.EncodeBool(m.IsSet)
1297         buf.EncodeUint32(m.FeatureBitmap)
1298         return buf.Bytes(), nil
1299 }
1300 func (m *L2Flags) Unmarshal(b []byte) error {
1301         buf := codec.NewBuffer(b)
1302         m.SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
1303         m.IsSet = buf.DecodeBool()
1304         m.FeatureBitmap = buf.DecodeUint32()
1305         return nil
1306 }
1307
1308 // L2FlagsReply defines message 'l2_flags_reply'.
1309 type L2FlagsReply struct {
1310         Retval                 int32  `binapi:"i32,name=retval" json:"retval,omitempty"`
1311         ResultingFeatureBitmap uint32 `binapi:"u32,name=resulting_feature_bitmap" json:"resulting_feature_bitmap,omitempty"`
1312 }
1313
1314 func (m *L2FlagsReply) Reset()               { *m = L2FlagsReply{} }
1315 func (*L2FlagsReply) GetMessageName() string { return "l2_flags_reply" }
1316 func (*L2FlagsReply) GetCrcString() string   { return "29b2a2b3" }
1317 func (*L2FlagsReply) GetMessageType() api.MessageType {
1318         return api.ReplyMessage
1319 }
1320
1321 func (m *L2FlagsReply) Size() (size int) {
1322         if m == nil {
1323                 return 0
1324         }
1325         size += 4 // m.Retval
1326         size += 4 // m.ResultingFeatureBitmap
1327         return size
1328 }
1329 func (m *L2FlagsReply) Marshal(b []byte) ([]byte, error) {
1330         if b == nil {
1331                 b = make([]byte, m.Size())
1332         }
1333         buf := codec.NewBuffer(b)
1334         buf.EncodeInt32(m.Retval)
1335         buf.EncodeUint32(m.ResultingFeatureBitmap)
1336         return buf.Bytes(), nil
1337 }
1338 func (m *L2FlagsReply) Unmarshal(b []byte) error {
1339         buf := codec.NewBuffer(b)
1340         m.Retval = buf.DecodeInt32()
1341         m.ResultingFeatureBitmap = buf.DecodeUint32()
1342         return nil
1343 }
1344
1345 // L2InterfaceEfpFilter defines message 'l2_interface_efp_filter'.
1346 type L2InterfaceEfpFilter struct {
1347         SwIfIndex     interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
1348         EnableDisable bool                           `binapi:"bool,name=enable_disable,default=true" json:"enable_disable,omitempty"`
1349 }
1350
1351 func (m *L2InterfaceEfpFilter) Reset()               { *m = L2InterfaceEfpFilter{} }
1352 func (*L2InterfaceEfpFilter) GetMessageName() string { return "l2_interface_efp_filter" }
1353 func (*L2InterfaceEfpFilter) GetCrcString() string   { return "5501adee" }
1354 func (*L2InterfaceEfpFilter) GetMessageType() api.MessageType {
1355         return api.RequestMessage
1356 }
1357
1358 func (m *L2InterfaceEfpFilter) Size() (size int) {
1359         if m == nil {
1360                 return 0
1361         }
1362         size += 4 // m.SwIfIndex
1363         size += 1 // m.EnableDisable
1364         return size
1365 }
1366 func (m *L2InterfaceEfpFilter) Marshal(b []byte) ([]byte, error) {
1367         if b == nil {
1368                 b = make([]byte, m.Size())
1369         }
1370         buf := codec.NewBuffer(b)
1371         buf.EncodeUint32(uint32(m.SwIfIndex))
1372         buf.EncodeBool(m.EnableDisable)
1373         return buf.Bytes(), nil
1374 }
1375 func (m *L2InterfaceEfpFilter) Unmarshal(b []byte) error {
1376         buf := codec.NewBuffer(b)
1377         m.SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
1378         m.EnableDisable = buf.DecodeBool()
1379         return nil
1380 }
1381
1382 // L2InterfaceEfpFilterReply defines message 'l2_interface_efp_filter_reply'.
1383 type L2InterfaceEfpFilterReply struct {
1384         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
1385 }
1386
1387 func (m *L2InterfaceEfpFilterReply) Reset()               { *m = L2InterfaceEfpFilterReply{} }
1388 func (*L2InterfaceEfpFilterReply) GetMessageName() string { return "l2_interface_efp_filter_reply" }
1389 func (*L2InterfaceEfpFilterReply) GetCrcString() string   { return "e8d4e804" }
1390 func (*L2InterfaceEfpFilterReply) GetMessageType() api.MessageType {
1391         return api.ReplyMessage
1392 }
1393
1394 func (m *L2InterfaceEfpFilterReply) Size() (size int) {
1395         if m == nil {
1396                 return 0
1397         }
1398         size += 4 // m.Retval
1399         return size
1400 }
1401 func (m *L2InterfaceEfpFilterReply) Marshal(b []byte) ([]byte, error) {
1402         if b == nil {
1403                 b = make([]byte, m.Size())
1404         }
1405         buf := codec.NewBuffer(b)
1406         buf.EncodeInt32(m.Retval)
1407         return buf.Bytes(), nil
1408 }
1409 func (m *L2InterfaceEfpFilterReply) Unmarshal(b []byte) error {
1410         buf := codec.NewBuffer(b)
1411         m.Retval = buf.DecodeInt32()
1412         return nil
1413 }
1414
1415 // L2InterfacePbbTagRewrite defines message 'l2_interface_pbb_tag_rewrite'.
1416 type L2InterfacePbbTagRewrite struct {
1417         SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
1418         VtrOp     uint32                         `binapi:"u32,name=vtr_op" json:"vtr_op,omitempty"`
1419         OuterTag  uint16                         `binapi:"u16,name=outer_tag" json:"outer_tag,omitempty"`
1420         BDmac     ethernet_types.MacAddress      `binapi:"mac_address,name=b_dmac" json:"b_dmac,omitempty"`
1421         BSmac     ethernet_types.MacAddress      `binapi:"mac_address,name=b_smac" json:"b_smac,omitempty"`
1422         BVlanid   uint16                         `binapi:"u16,name=b_vlanid" json:"b_vlanid,omitempty"`
1423         ISid      uint32                         `binapi:"u32,name=i_sid" json:"i_sid,omitempty"`
1424 }
1425
1426 func (m *L2InterfacePbbTagRewrite) Reset()               { *m = L2InterfacePbbTagRewrite{} }
1427 func (*L2InterfacePbbTagRewrite) GetMessageName() string { return "l2_interface_pbb_tag_rewrite" }
1428 func (*L2InterfacePbbTagRewrite) GetCrcString() string   { return "38e802a8" }
1429 func (*L2InterfacePbbTagRewrite) GetMessageType() api.MessageType {
1430         return api.RequestMessage
1431 }
1432
1433 func (m *L2InterfacePbbTagRewrite) Size() (size int) {
1434         if m == nil {
1435                 return 0
1436         }
1437         size += 4     // m.SwIfIndex
1438         size += 4     // m.VtrOp
1439         size += 2     // m.OuterTag
1440         size += 1 * 6 // m.BDmac
1441         size += 1 * 6 // m.BSmac
1442         size += 2     // m.BVlanid
1443         size += 4     // m.ISid
1444         return size
1445 }
1446 func (m *L2InterfacePbbTagRewrite) Marshal(b []byte) ([]byte, error) {
1447         if b == nil {
1448                 b = make([]byte, m.Size())
1449         }
1450         buf := codec.NewBuffer(b)
1451         buf.EncodeUint32(uint32(m.SwIfIndex))
1452         buf.EncodeUint32(m.VtrOp)
1453         buf.EncodeUint16(m.OuterTag)
1454         buf.EncodeBytes(m.BDmac[:], 6)
1455         buf.EncodeBytes(m.BSmac[:], 6)
1456         buf.EncodeUint16(m.BVlanid)
1457         buf.EncodeUint32(m.ISid)
1458         return buf.Bytes(), nil
1459 }
1460 func (m *L2InterfacePbbTagRewrite) Unmarshal(b []byte) error {
1461         buf := codec.NewBuffer(b)
1462         m.SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
1463         m.VtrOp = buf.DecodeUint32()
1464         m.OuterTag = buf.DecodeUint16()
1465         copy(m.BDmac[:], buf.DecodeBytes(6))
1466         copy(m.BSmac[:], buf.DecodeBytes(6))
1467         m.BVlanid = buf.DecodeUint16()
1468         m.ISid = buf.DecodeUint32()
1469         return nil
1470 }
1471
1472 // L2InterfacePbbTagRewriteReply defines message 'l2_interface_pbb_tag_rewrite_reply'.
1473 type L2InterfacePbbTagRewriteReply struct {
1474         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
1475 }
1476
1477 func (m *L2InterfacePbbTagRewriteReply) Reset() { *m = L2InterfacePbbTagRewriteReply{} }
1478 func (*L2InterfacePbbTagRewriteReply) GetMessageName() string {
1479         return "l2_interface_pbb_tag_rewrite_reply"
1480 }
1481 func (*L2InterfacePbbTagRewriteReply) GetCrcString() string { return "e8d4e804" }
1482 func (*L2InterfacePbbTagRewriteReply) GetMessageType() api.MessageType {
1483         return api.ReplyMessage
1484 }
1485
1486 func (m *L2InterfacePbbTagRewriteReply) Size() (size int) {
1487         if m == nil {
1488                 return 0
1489         }
1490         size += 4 // m.Retval
1491         return size
1492 }
1493 func (m *L2InterfacePbbTagRewriteReply) Marshal(b []byte) ([]byte, error) {
1494         if b == nil {
1495                 b = make([]byte, m.Size())
1496         }
1497         buf := codec.NewBuffer(b)
1498         buf.EncodeInt32(m.Retval)
1499         return buf.Bytes(), nil
1500 }
1501 func (m *L2InterfacePbbTagRewriteReply) Unmarshal(b []byte) error {
1502         buf := codec.NewBuffer(b)
1503         m.Retval = buf.DecodeInt32()
1504         return nil
1505 }
1506
1507 // L2InterfaceVlanTagRewrite defines message 'l2_interface_vlan_tag_rewrite'.
1508 type L2InterfaceVlanTagRewrite struct {
1509         SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
1510         VtrOp     uint32                         `binapi:"u32,name=vtr_op" json:"vtr_op,omitempty"`
1511         PushDot1q uint32                         `binapi:"u32,name=push_dot1q" json:"push_dot1q,omitempty"`
1512         Tag1      uint32                         `binapi:"u32,name=tag1" json:"tag1,omitempty"`
1513         Tag2      uint32                         `binapi:"u32,name=tag2" json:"tag2,omitempty"`
1514 }
1515
1516 func (m *L2InterfaceVlanTagRewrite) Reset()               { *m = L2InterfaceVlanTagRewrite{} }
1517 func (*L2InterfaceVlanTagRewrite) GetMessageName() string { return "l2_interface_vlan_tag_rewrite" }
1518 func (*L2InterfaceVlanTagRewrite) GetCrcString() string   { return "62cc0bbc" }
1519 func (*L2InterfaceVlanTagRewrite) GetMessageType() api.MessageType {
1520         return api.RequestMessage
1521 }
1522
1523 func (m *L2InterfaceVlanTagRewrite) Size() (size int) {
1524         if m == nil {
1525                 return 0
1526         }
1527         size += 4 // m.SwIfIndex
1528         size += 4 // m.VtrOp
1529         size += 4 // m.PushDot1q
1530         size += 4 // m.Tag1
1531         size += 4 // m.Tag2
1532         return size
1533 }
1534 func (m *L2InterfaceVlanTagRewrite) Marshal(b []byte) ([]byte, error) {
1535         if b == nil {
1536                 b = make([]byte, m.Size())
1537         }
1538         buf := codec.NewBuffer(b)
1539         buf.EncodeUint32(uint32(m.SwIfIndex))
1540         buf.EncodeUint32(m.VtrOp)
1541         buf.EncodeUint32(m.PushDot1q)
1542         buf.EncodeUint32(m.Tag1)
1543         buf.EncodeUint32(m.Tag2)
1544         return buf.Bytes(), nil
1545 }
1546 func (m *L2InterfaceVlanTagRewrite) Unmarshal(b []byte) error {
1547         buf := codec.NewBuffer(b)
1548         m.SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
1549         m.VtrOp = buf.DecodeUint32()
1550         m.PushDot1q = buf.DecodeUint32()
1551         m.Tag1 = buf.DecodeUint32()
1552         m.Tag2 = buf.DecodeUint32()
1553         return nil
1554 }
1555
1556 // L2InterfaceVlanTagRewriteReply defines message 'l2_interface_vlan_tag_rewrite_reply'.
1557 type L2InterfaceVlanTagRewriteReply struct {
1558         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
1559 }
1560
1561 func (m *L2InterfaceVlanTagRewriteReply) Reset() { *m = L2InterfaceVlanTagRewriteReply{} }
1562 func (*L2InterfaceVlanTagRewriteReply) GetMessageName() string {
1563         return "l2_interface_vlan_tag_rewrite_reply"
1564 }
1565 func (*L2InterfaceVlanTagRewriteReply) GetCrcString() string { return "e8d4e804" }
1566 func (*L2InterfaceVlanTagRewriteReply) GetMessageType() api.MessageType {
1567         return api.ReplyMessage
1568 }
1569
1570 func (m *L2InterfaceVlanTagRewriteReply) Size() (size int) {
1571         if m == nil {
1572                 return 0
1573         }
1574         size += 4 // m.Retval
1575         return size
1576 }
1577 func (m *L2InterfaceVlanTagRewriteReply) Marshal(b []byte) ([]byte, error) {
1578         if b == nil {
1579                 b = make([]byte, m.Size())
1580         }
1581         buf := codec.NewBuffer(b)
1582         buf.EncodeInt32(m.Retval)
1583         return buf.Bytes(), nil
1584 }
1585 func (m *L2InterfaceVlanTagRewriteReply) Unmarshal(b []byte) error {
1586         buf := codec.NewBuffer(b)
1587         m.Retval = buf.DecodeInt32()
1588         return nil
1589 }
1590
1591 // L2MacsEvent defines message 'l2_macs_event'.
1592 type L2MacsEvent struct {
1593         PID   uint32     `binapi:"u32,name=pid" json:"pid,omitempty"`
1594         NMacs uint32     `binapi:"u32,name=n_macs" json:"-"`
1595         Mac   []MacEntry `binapi:"mac_entry[n_macs],name=mac" json:"mac,omitempty"`
1596 }
1597
1598 func (m *L2MacsEvent) Reset()               { *m = L2MacsEvent{} }
1599 func (*L2MacsEvent) GetMessageName() string { return "l2_macs_event" }
1600 func (*L2MacsEvent) GetCrcString() string   { return "44b8fd64" }
1601 func (*L2MacsEvent) GetMessageType() api.MessageType {
1602         return api.EventMessage
1603 }
1604
1605 func (m *L2MacsEvent) Size() (size int) {
1606         if m == nil {
1607                 return 0
1608         }
1609         size += 4 // m.PID
1610         size += 4 // m.NMacs
1611         for j1 := 0; j1 < len(m.Mac); j1++ {
1612                 var s1 MacEntry
1613                 _ = s1
1614                 if j1 < len(m.Mac) {
1615                         s1 = m.Mac[j1]
1616                 }
1617                 size += 4     // s1.SwIfIndex
1618                 size += 1 * 6 // s1.MacAddr
1619                 size += 4     // s1.Action
1620                 size += 1     // s1.Flags
1621         }
1622         return size
1623 }
1624 func (m *L2MacsEvent) Marshal(b []byte) ([]byte, error) {
1625         if b == nil {
1626                 b = make([]byte, m.Size())
1627         }
1628         buf := codec.NewBuffer(b)
1629         buf.EncodeUint32(m.PID)
1630         buf.EncodeUint32(uint32(len(m.Mac)))
1631         for j0 := 0; j0 < len(m.Mac); j0++ {
1632                 var v0 MacEntry // Mac
1633                 if j0 < len(m.Mac) {
1634                         v0 = m.Mac[j0]
1635                 }
1636                 buf.EncodeUint32(uint32(v0.SwIfIndex))
1637                 buf.EncodeBytes(v0.MacAddr[:], 6)
1638                 buf.EncodeUint32(uint32(v0.Action))
1639                 buf.EncodeUint8(v0.Flags)
1640         }
1641         return buf.Bytes(), nil
1642 }
1643 func (m *L2MacsEvent) Unmarshal(b []byte) error {
1644         buf := codec.NewBuffer(b)
1645         m.PID = buf.DecodeUint32()
1646         m.NMacs = buf.DecodeUint32()
1647         m.Mac = make([]MacEntry, m.NMacs)
1648         for j0 := 0; j0 < len(m.Mac); j0++ {
1649                 m.Mac[j0].SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
1650                 copy(m.Mac[j0].MacAddr[:], buf.DecodeBytes(6))
1651                 m.Mac[j0].Action = MacEventAction(buf.DecodeUint32())
1652                 m.Mac[j0].Flags = buf.DecodeUint8()
1653         }
1654         return nil
1655 }
1656
1657 // L2PatchAddDel defines message 'l2_patch_add_del'.
1658 type L2PatchAddDel struct {
1659         RxSwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=rx_sw_if_index" json:"rx_sw_if_index,omitempty"`
1660         TxSwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=tx_sw_if_index" json:"tx_sw_if_index,omitempty"`
1661         IsAdd       bool                           `binapi:"bool,name=is_add,default=true" json:"is_add,omitempty"`
1662 }
1663
1664 func (m *L2PatchAddDel) Reset()               { *m = L2PatchAddDel{} }
1665 func (*L2PatchAddDel) GetMessageName() string { return "l2_patch_add_del" }
1666 func (*L2PatchAddDel) GetCrcString() string   { return "a1f6a6f3" }
1667 func (*L2PatchAddDel) GetMessageType() api.MessageType {
1668         return api.RequestMessage
1669 }
1670
1671 func (m *L2PatchAddDel) Size() (size int) {
1672         if m == nil {
1673                 return 0
1674         }
1675         size += 4 // m.RxSwIfIndex
1676         size += 4 // m.TxSwIfIndex
1677         size += 1 // m.IsAdd
1678         return size
1679 }
1680 func (m *L2PatchAddDel) Marshal(b []byte) ([]byte, error) {
1681         if b == nil {
1682                 b = make([]byte, m.Size())
1683         }
1684         buf := codec.NewBuffer(b)
1685         buf.EncodeUint32(uint32(m.RxSwIfIndex))
1686         buf.EncodeUint32(uint32(m.TxSwIfIndex))
1687         buf.EncodeBool(m.IsAdd)
1688         return buf.Bytes(), nil
1689 }
1690 func (m *L2PatchAddDel) Unmarshal(b []byte) error {
1691         buf := codec.NewBuffer(b)
1692         m.RxSwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
1693         m.TxSwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
1694         m.IsAdd = buf.DecodeBool()
1695         return nil
1696 }
1697
1698 // L2PatchAddDelReply defines message 'l2_patch_add_del_reply'.
1699 type L2PatchAddDelReply struct {
1700         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
1701 }
1702
1703 func (m *L2PatchAddDelReply) Reset()               { *m = L2PatchAddDelReply{} }
1704 func (*L2PatchAddDelReply) GetMessageName() string { return "l2_patch_add_del_reply" }
1705 func (*L2PatchAddDelReply) GetCrcString() string   { return "e8d4e804" }
1706 func (*L2PatchAddDelReply) GetMessageType() api.MessageType {
1707         return api.ReplyMessage
1708 }
1709
1710 func (m *L2PatchAddDelReply) Size() (size int) {
1711         if m == nil {
1712                 return 0
1713         }
1714         size += 4 // m.Retval
1715         return size
1716 }
1717 func (m *L2PatchAddDelReply) Marshal(b []byte) ([]byte, error) {
1718         if b == nil {
1719                 b = make([]byte, m.Size())
1720         }
1721         buf := codec.NewBuffer(b)
1722         buf.EncodeInt32(m.Retval)
1723         return buf.Bytes(), nil
1724 }
1725 func (m *L2PatchAddDelReply) Unmarshal(b []byte) error {
1726         buf := codec.NewBuffer(b)
1727         m.Retval = buf.DecodeInt32()
1728         return nil
1729 }
1730
1731 // L2XconnectDetails defines message 'l2_xconnect_details'.
1732 type L2XconnectDetails struct {
1733         RxSwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=rx_sw_if_index" json:"rx_sw_if_index,omitempty"`
1734         TxSwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=tx_sw_if_index" json:"tx_sw_if_index,omitempty"`
1735 }
1736
1737 func (m *L2XconnectDetails) Reset()               { *m = L2XconnectDetails{} }
1738 func (*L2XconnectDetails) GetMessageName() string { return "l2_xconnect_details" }
1739 func (*L2XconnectDetails) GetCrcString() string   { return "472b6b67" }
1740 func (*L2XconnectDetails) GetMessageType() api.MessageType {
1741         return api.ReplyMessage
1742 }
1743
1744 func (m *L2XconnectDetails) Size() (size int) {
1745         if m == nil {
1746                 return 0
1747         }
1748         size += 4 // m.RxSwIfIndex
1749         size += 4 // m.TxSwIfIndex
1750         return size
1751 }
1752 func (m *L2XconnectDetails) Marshal(b []byte) ([]byte, error) {
1753         if b == nil {
1754                 b = make([]byte, m.Size())
1755         }
1756         buf := codec.NewBuffer(b)
1757         buf.EncodeUint32(uint32(m.RxSwIfIndex))
1758         buf.EncodeUint32(uint32(m.TxSwIfIndex))
1759         return buf.Bytes(), nil
1760 }
1761 func (m *L2XconnectDetails) Unmarshal(b []byte) error {
1762         buf := codec.NewBuffer(b)
1763         m.RxSwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
1764         m.TxSwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
1765         return nil
1766 }
1767
1768 // L2XconnectDump defines message 'l2_xconnect_dump'.
1769 type L2XconnectDump struct{}
1770
1771 func (m *L2XconnectDump) Reset()               { *m = L2XconnectDump{} }
1772 func (*L2XconnectDump) GetMessageName() string { return "l2_xconnect_dump" }
1773 func (*L2XconnectDump) GetCrcString() string   { return "51077d14" }
1774 func (*L2XconnectDump) GetMessageType() api.MessageType {
1775         return api.RequestMessage
1776 }
1777
1778 func (m *L2XconnectDump) Size() (size int) {
1779         if m == nil {
1780                 return 0
1781         }
1782         return size
1783 }
1784 func (m *L2XconnectDump) Marshal(b []byte) ([]byte, error) {
1785         if b == nil {
1786                 b = make([]byte, m.Size())
1787         }
1788         buf := codec.NewBuffer(b)
1789         return buf.Bytes(), nil
1790 }
1791 func (m *L2XconnectDump) Unmarshal(b []byte) error {
1792         return nil
1793 }
1794
1795 // L2fibAddDel defines message 'l2fib_add_del'.
1796 type L2fibAddDel struct {
1797         Mac       ethernet_types.MacAddress      `binapi:"mac_address,name=mac" json:"mac,omitempty"`
1798         BdID      uint32                         `binapi:"u32,name=bd_id" json:"bd_id,omitempty"`
1799         SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
1800         IsAdd     bool                           `binapi:"bool,name=is_add,default=true" json:"is_add,omitempty"`
1801         StaticMac bool                           `binapi:"bool,name=static_mac" json:"static_mac,omitempty"`
1802         FilterMac bool                           `binapi:"bool,name=filter_mac" json:"filter_mac,omitempty"`
1803         BviMac    bool                           `binapi:"bool,name=bvi_mac" json:"bvi_mac,omitempty"`
1804 }
1805
1806 func (m *L2fibAddDel) Reset()               { *m = L2fibAddDel{} }
1807 func (*L2fibAddDel) GetMessageName() string { return "l2fib_add_del" }
1808 func (*L2fibAddDel) GetCrcString() string   { return "eddda487" }
1809 func (*L2fibAddDel) GetMessageType() api.MessageType {
1810         return api.RequestMessage
1811 }
1812
1813 func (m *L2fibAddDel) Size() (size int) {
1814         if m == nil {
1815                 return 0
1816         }
1817         size += 1 * 6 // m.Mac
1818         size += 4     // m.BdID
1819         size += 4     // m.SwIfIndex
1820         size += 1     // m.IsAdd
1821         size += 1     // m.StaticMac
1822         size += 1     // m.FilterMac
1823         size += 1     // m.BviMac
1824         return size
1825 }
1826 func (m *L2fibAddDel) Marshal(b []byte) ([]byte, error) {
1827         if b == nil {
1828                 b = make([]byte, m.Size())
1829         }
1830         buf := codec.NewBuffer(b)
1831         buf.EncodeBytes(m.Mac[:], 6)
1832         buf.EncodeUint32(m.BdID)
1833         buf.EncodeUint32(uint32(m.SwIfIndex))
1834         buf.EncodeBool(m.IsAdd)
1835         buf.EncodeBool(m.StaticMac)
1836         buf.EncodeBool(m.FilterMac)
1837         buf.EncodeBool(m.BviMac)
1838         return buf.Bytes(), nil
1839 }
1840 func (m *L2fibAddDel) Unmarshal(b []byte) error {
1841         buf := codec.NewBuffer(b)
1842         copy(m.Mac[:], buf.DecodeBytes(6))
1843         m.BdID = buf.DecodeUint32()
1844         m.SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
1845         m.IsAdd = buf.DecodeBool()
1846         m.StaticMac = buf.DecodeBool()
1847         m.FilterMac = buf.DecodeBool()
1848         m.BviMac = buf.DecodeBool()
1849         return nil
1850 }
1851
1852 // L2fibAddDelReply defines message 'l2fib_add_del_reply'.
1853 type L2fibAddDelReply struct {
1854         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
1855 }
1856
1857 func (m *L2fibAddDelReply) Reset()               { *m = L2fibAddDelReply{} }
1858 func (*L2fibAddDelReply) GetMessageName() string { return "l2fib_add_del_reply" }
1859 func (*L2fibAddDelReply) GetCrcString() string   { return "e8d4e804" }
1860 func (*L2fibAddDelReply) GetMessageType() api.MessageType {
1861         return api.ReplyMessage
1862 }
1863
1864 func (m *L2fibAddDelReply) Size() (size int) {
1865         if m == nil {
1866                 return 0
1867         }
1868         size += 4 // m.Retval
1869         return size
1870 }
1871 func (m *L2fibAddDelReply) Marshal(b []byte) ([]byte, error) {
1872         if b == nil {
1873                 b = make([]byte, m.Size())
1874         }
1875         buf := codec.NewBuffer(b)
1876         buf.EncodeInt32(m.Retval)
1877         return buf.Bytes(), nil
1878 }
1879 func (m *L2fibAddDelReply) Unmarshal(b []byte) error {
1880         buf := codec.NewBuffer(b)
1881         m.Retval = buf.DecodeInt32()
1882         return nil
1883 }
1884
1885 // L2fibFlushAll defines message 'l2fib_flush_all'.
1886 type L2fibFlushAll struct{}
1887
1888 func (m *L2fibFlushAll) Reset()               { *m = L2fibFlushAll{} }
1889 func (*L2fibFlushAll) GetMessageName() string { return "l2fib_flush_all" }
1890 func (*L2fibFlushAll) GetCrcString() string   { return "51077d14" }
1891 func (*L2fibFlushAll) GetMessageType() api.MessageType {
1892         return api.RequestMessage
1893 }
1894
1895 func (m *L2fibFlushAll) Size() (size int) {
1896         if m == nil {
1897                 return 0
1898         }
1899         return size
1900 }
1901 func (m *L2fibFlushAll) Marshal(b []byte) ([]byte, error) {
1902         if b == nil {
1903                 b = make([]byte, m.Size())
1904         }
1905         buf := codec.NewBuffer(b)
1906         return buf.Bytes(), nil
1907 }
1908 func (m *L2fibFlushAll) Unmarshal(b []byte) error {
1909         return nil
1910 }
1911
1912 // L2fibFlushAllReply defines message 'l2fib_flush_all_reply'.
1913 type L2fibFlushAllReply struct {
1914         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
1915 }
1916
1917 func (m *L2fibFlushAllReply) Reset()               { *m = L2fibFlushAllReply{} }
1918 func (*L2fibFlushAllReply) GetMessageName() string { return "l2fib_flush_all_reply" }
1919 func (*L2fibFlushAllReply) GetCrcString() string   { return "e8d4e804" }
1920 func (*L2fibFlushAllReply) GetMessageType() api.MessageType {
1921         return api.ReplyMessage
1922 }
1923
1924 func (m *L2fibFlushAllReply) Size() (size int) {
1925         if m == nil {
1926                 return 0
1927         }
1928         size += 4 // m.Retval
1929         return size
1930 }
1931 func (m *L2fibFlushAllReply) Marshal(b []byte) ([]byte, error) {
1932         if b == nil {
1933                 b = make([]byte, m.Size())
1934         }
1935         buf := codec.NewBuffer(b)
1936         buf.EncodeInt32(m.Retval)
1937         return buf.Bytes(), nil
1938 }
1939 func (m *L2fibFlushAllReply) Unmarshal(b []byte) error {
1940         buf := codec.NewBuffer(b)
1941         m.Retval = buf.DecodeInt32()
1942         return nil
1943 }
1944
1945 // L2fibFlushBd defines message 'l2fib_flush_bd'.
1946 type L2fibFlushBd struct {
1947         BdID uint32 `binapi:"u32,name=bd_id" json:"bd_id,omitempty"`
1948 }
1949
1950 func (m *L2fibFlushBd) Reset()               { *m = L2fibFlushBd{} }
1951 func (*L2fibFlushBd) GetMessageName() string { return "l2fib_flush_bd" }
1952 func (*L2fibFlushBd) GetCrcString() string   { return "c25fdce6" }
1953 func (*L2fibFlushBd) GetMessageType() api.MessageType {
1954         return api.RequestMessage
1955 }
1956
1957 func (m *L2fibFlushBd) Size() (size int) {
1958         if m == nil {
1959                 return 0
1960         }
1961         size += 4 // m.BdID
1962         return size
1963 }
1964 func (m *L2fibFlushBd) Marshal(b []byte) ([]byte, error) {
1965         if b == nil {
1966                 b = make([]byte, m.Size())
1967         }
1968         buf := codec.NewBuffer(b)
1969         buf.EncodeUint32(m.BdID)
1970         return buf.Bytes(), nil
1971 }
1972 func (m *L2fibFlushBd) Unmarshal(b []byte) error {
1973         buf := codec.NewBuffer(b)
1974         m.BdID = buf.DecodeUint32()
1975         return nil
1976 }
1977
1978 // L2fibFlushBdReply defines message 'l2fib_flush_bd_reply'.
1979 type L2fibFlushBdReply struct {
1980         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
1981 }
1982
1983 func (m *L2fibFlushBdReply) Reset()               { *m = L2fibFlushBdReply{} }
1984 func (*L2fibFlushBdReply) GetMessageName() string { return "l2fib_flush_bd_reply" }
1985 func (*L2fibFlushBdReply) GetCrcString() string   { return "e8d4e804" }
1986 func (*L2fibFlushBdReply) GetMessageType() api.MessageType {
1987         return api.ReplyMessage
1988 }
1989
1990 func (m *L2fibFlushBdReply) Size() (size int) {
1991         if m == nil {
1992                 return 0
1993         }
1994         size += 4 // m.Retval
1995         return size
1996 }
1997 func (m *L2fibFlushBdReply) Marshal(b []byte) ([]byte, error) {
1998         if b == nil {
1999                 b = make([]byte, m.Size())
2000         }
2001         buf := codec.NewBuffer(b)
2002         buf.EncodeInt32(m.Retval)
2003         return buf.Bytes(), nil
2004 }
2005 func (m *L2fibFlushBdReply) Unmarshal(b []byte) error {
2006         buf := codec.NewBuffer(b)
2007         m.Retval = buf.DecodeInt32()
2008         return nil
2009 }
2010
2011 // L2fibFlushInt defines message 'l2fib_flush_int'.
2012 type L2fibFlushInt struct {
2013         SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
2014 }
2015
2016 func (m *L2fibFlushInt) Reset()               { *m = L2fibFlushInt{} }
2017 func (*L2fibFlushInt) GetMessageName() string { return "l2fib_flush_int" }
2018 func (*L2fibFlushInt) GetCrcString() string   { return "f9e6675e" }
2019 func (*L2fibFlushInt) GetMessageType() api.MessageType {
2020         return api.RequestMessage
2021 }
2022
2023 func (m *L2fibFlushInt) Size() (size int) {
2024         if m == nil {
2025                 return 0
2026         }
2027         size += 4 // m.SwIfIndex
2028         return size
2029 }
2030 func (m *L2fibFlushInt) Marshal(b []byte) ([]byte, error) {
2031         if b == nil {
2032                 b = make([]byte, m.Size())
2033         }
2034         buf := codec.NewBuffer(b)
2035         buf.EncodeUint32(uint32(m.SwIfIndex))
2036         return buf.Bytes(), nil
2037 }
2038 func (m *L2fibFlushInt) Unmarshal(b []byte) error {
2039         buf := codec.NewBuffer(b)
2040         m.SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
2041         return nil
2042 }
2043
2044 // L2fibFlushIntReply defines message 'l2fib_flush_int_reply'.
2045 type L2fibFlushIntReply struct {
2046         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
2047 }
2048
2049 func (m *L2fibFlushIntReply) Reset()               { *m = L2fibFlushIntReply{} }
2050 func (*L2fibFlushIntReply) GetMessageName() string { return "l2fib_flush_int_reply" }
2051 func (*L2fibFlushIntReply) GetCrcString() string   { return "e8d4e804" }
2052 func (*L2fibFlushIntReply) GetMessageType() api.MessageType {
2053         return api.ReplyMessage
2054 }
2055
2056 func (m *L2fibFlushIntReply) Size() (size int) {
2057         if m == nil {
2058                 return 0
2059         }
2060         size += 4 // m.Retval
2061         return size
2062 }
2063 func (m *L2fibFlushIntReply) Marshal(b []byte) ([]byte, error) {
2064         if b == nil {
2065                 b = make([]byte, m.Size())
2066         }
2067         buf := codec.NewBuffer(b)
2068         buf.EncodeInt32(m.Retval)
2069         return buf.Bytes(), nil
2070 }
2071 func (m *L2fibFlushIntReply) Unmarshal(b []byte) error {
2072         buf := codec.NewBuffer(b)
2073         m.Retval = buf.DecodeInt32()
2074         return nil
2075 }
2076
2077 // L2fibSetScanDelay defines message 'l2fib_set_scan_delay'.
2078 type L2fibSetScanDelay struct {
2079         ScanDelay uint16 `binapi:"u16,name=scan_delay,default=10" json:"scan_delay,omitempty"`
2080 }
2081
2082 func (m *L2fibSetScanDelay) Reset()               { *m = L2fibSetScanDelay{} }
2083 func (*L2fibSetScanDelay) GetMessageName() string { return "l2fib_set_scan_delay" }
2084 func (*L2fibSetScanDelay) GetCrcString() string   { return "a3b968a4" }
2085 func (*L2fibSetScanDelay) GetMessageType() api.MessageType {
2086         return api.RequestMessage
2087 }
2088
2089 func (m *L2fibSetScanDelay) Size() (size int) {
2090         if m == nil {
2091                 return 0
2092         }
2093         size += 2 // m.ScanDelay
2094         return size
2095 }
2096 func (m *L2fibSetScanDelay) Marshal(b []byte) ([]byte, error) {
2097         if b == nil {
2098                 b = make([]byte, m.Size())
2099         }
2100         buf := codec.NewBuffer(b)
2101         buf.EncodeUint16(m.ScanDelay)
2102         return buf.Bytes(), nil
2103 }
2104 func (m *L2fibSetScanDelay) Unmarshal(b []byte) error {
2105         buf := codec.NewBuffer(b)
2106         m.ScanDelay = buf.DecodeUint16()
2107         return nil
2108 }
2109
2110 // L2fibSetScanDelayReply defines message 'l2fib_set_scan_delay_reply'.
2111 type L2fibSetScanDelayReply struct {
2112         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
2113 }
2114
2115 func (m *L2fibSetScanDelayReply) Reset()               { *m = L2fibSetScanDelayReply{} }
2116 func (*L2fibSetScanDelayReply) GetMessageName() string { return "l2fib_set_scan_delay_reply" }
2117 func (*L2fibSetScanDelayReply) GetCrcString() string   { return "e8d4e804" }
2118 func (*L2fibSetScanDelayReply) GetMessageType() api.MessageType {
2119         return api.ReplyMessage
2120 }
2121
2122 func (m *L2fibSetScanDelayReply) Size() (size int) {
2123         if m == nil {
2124                 return 0
2125         }
2126         size += 4 // m.Retval
2127         return size
2128 }
2129 func (m *L2fibSetScanDelayReply) Marshal(b []byte) ([]byte, error) {
2130         if b == nil {
2131                 b = make([]byte, m.Size())
2132         }
2133         buf := codec.NewBuffer(b)
2134         buf.EncodeInt32(m.Retval)
2135         return buf.Bytes(), nil
2136 }
2137 func (m *L2fibSetScanDelayReply) Unmarshal(b []byte) error {
2138         buf := codec.NewBuffer(b)
2139         m.Retval = buf.DecodeInt32()
2140         return nil
2141 }
2142
2143 // SwInterfaceSetL2Bridge defines message 'sw_interface_set_l2_bridge'.
2144 type SwInterfaceSetL2Bridge struct {
2145         RxSwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=rx_sw_if_index" json:"rx_sw_if_index,omitempty"`
2146         BdID        uint32                         `binapi:"u32,name=bd_id" json:"bd_id,omitempty"`
2147         PortType    L2PortType                     `binapi:"l2_port_type,name=port_type" json:"port_type,omitempty"`
2148         Shg         uint8                          `binapi:"u8,name=shg" json:"shg,omitempty"`
2149         Enable      bool                           `binapi:"bool,name=enable,default=true" json:"enable,omitempty"`
2150 }
2151
2152 func (m *SwInterfaceSetL2Bridge) Reset()               { *m = SwInterfaceSetL2Bridge{} }
2153 func (*SwInterfaceSetL2Bridge) GetMessageName() string { return "sw_interface_set_l2_bridge" }
2154 func (*SwInterfaceSetL2Bridge) GetCrcString() string   { return "d0678b13" }
2155 func (*SwInterfaceSetL2Bridge) GetMessageType() api.MessageType {
2156         return api.RequestMessage
2157 }
2158
2159 func (m *SwInterfaceSetL2Bridge) Size() (size int) {
2160         if m == nil {
2161                 return 0
2162         }
2163         size += 4 // m.RxSwIfIndex
2164         size += 4 // m.BdID
2165         size += 4 // m.PortType
2166         size += 1 // m.Shg
2167         size += 1 // m.Enable
2168         return size
2169 }
2170 func (m *SwInterfaceSetL2Bridge) Marshal(b []byte) ([]byte, error) {
2171         if b == nil {
2172                 b = make([]byte, m.Size())
2173         }
2174         buf := codec.NewBuffer(b)
2175         buf.EncodeUint32(uint32(m.RxSwIfIndex))
2176         buf.EncodeUint32(m.BdID)
2177         buf.EncodeUint32(uint32(m.PortType))
2178         buf.EncodeUint8(m.Shg)
2179         buf.EncodeBool(m.Enable)
2180         return buf.Bytes(), nil
2181 }
2182 func (m *SwInterfaceSetL2Bridge) Unmarshal(b []byte) error {
2183         buf := codec.NewBuffer(b)
2184         m.RxSwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
2185         m.BdID = buf.DecodeUint32()
2186         m.PortType = L2PortType(buf.DecodeUint32())
2187         m.Shg = buf.DecodeUint8()
2188         m.Enable = buf.DecodeBool()
2189         return nil
2190 }
2191
2192 // SwInterfaceSetL2BridgeReply defines message 'sw_interface_set_l2_bridge_reply'.
2193 type SwInterfaceSetL2BridgeReply struct {
2194         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
2195 }
2196
2197 func (m *SwInterfaceSetL2BridgeReply) Reset() { *m = SwInterfaceSetL2BridgeReply{} }
2198 func (*SwInterfaceSetL2BridgeReply) GetMessageName() string {
2199         return "sw_interface_set_l2_bridge_reply"
2200 }
2201 func (*SwInterfaceSetL2BridgeReply) GetCrcString() string { return "e8d4e804" }
2202 func (*SwInterfaceSetL2BridgeReply) GetMessageType() api.MessageType {
2203         return api.ReplyMessage
2204 }
2205
2206 func (m *SwInterfaceSetL2BridgeReply) Size() (size int) {
2207         if m == nil {
2208                 return 0
2209         }
2210         size += 4 // m.Retval
2211         return size
2212 }
2213 func (m *SwInterfaceSetL2BridgeReply) Marshal(b []byte) ([]byte, error) {
2214         if b == nil {
2215                 b = make([]byte, m.Size())
2216         }
2217         buf := codec.NewBuffer(b)
2218         buf.EncodeInt32(m.Retval)
2219         return buf.Bytes(), nil
2220 }
2221 func (m *SwInterfaceSetL2BridgeReply) Unmarshal(b []byte) error {
2222         buf := codec.NewBuffer(b)
2223         m.Retval = buf.DecodeInt32()
2224         return nil
2225 }
2226
2227 // SwInterfaceSetL2Xconnect defines message 'sw_interface_set_l2_xconnect'.
2228 type SwInterfaceSetL2Xconnect struct {
2229         RxSwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=rx_sw_if_index" json:"rx_sw_if_index,omitempty"`
2230         TxSwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=tx_sw_if_index" json:"tx_sw_if_index,omitempty"`
2231         Enable      bool                           `binapi:"bool,name=enable,default=true" json:"enable,omitempty"`
2232 }
2233
2234 func (m *SwInterfaceSetL2Xconnect) Reset()               { *m = SwInterfaceSetL2Xconnect{} }
2235 func (*SwInterfaceSetL2Xconnect) GetMessageName() string { return "sw_interface_set_l2_xconnect" }
2236 func (*SwInterfaceSetL2Xconnect) GetCrcString() string   { return "4fa28a85" }
2237 func (*SwInterfaceSetL2Xconnect) GetMessageType() api.MessageType {
2238         return api.RequestMessage
2239 }
2240
2241 func (m *SwInterfaceSetL2Xconnect) Size() (size int) {
2242         if m == nil {
2243                 return 0
2244         }
2245         size += 4 // m.RxSwIfIndex
2246         size += 4 // m.TxSwIfIndex
2247         size += 1 // m.Enable
2248         return size
2249 }
2250 func (m *SwInterfaceSetL2Xconnect) Marshal(b []byte) ([]byte, error) {
2251         if b == nil {
2252                 b = make([]byte, m.Size())
2253         }
2254         buf := codec.NewBuffer(b)
2255         buf.EncodeUint32(uint32(m.RxSwIfIndex))
2256         buf.EncodeUint32(uint32(m.TxSwIfIndex))
2257         buf.EncodeBool(m.Enable)
2258         return buf.Bytes(), nil
2259 }
2260 func (m *SwInterfaceSetL2Xconnect) Unmarshal(b []byte) error {
2261         buf := codec.NewBuffer(b)
2262         m.RxSwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
2263         m.TxSwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
2264         m.Enable = buf.DecodeBool()
2265         return nil
2266 }
2267
2268 // SwInterfaceSetL2XconnectReply defines message 'sw_interface_set_l2_xconnect_reply'.
2269 type SwInterfaceSetL2XconnectReply struct {
2270         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
2271 }
2272
2273 func (m *SwInterfaceSetL2XconnectReply) Reset() { *m = SwInterfaceSetL2XconnectReply{} }
2274 func (*SwInterfaceSetL2XconnectReply) GetMessageName() string {
2275         return "sw_interface_set_l2_xconnect_reply"
2276 }
2277 func (*SwInterfaceSetL2XconnectReply) GetCrcString() string { return "e8d4e804" }
2278 func (*SwInterfaceSetL2XconnectReply) GetMessageType() api.MessageType {
2279         return api.ReplyMessage
2280 }
2281
2282 func (m *SwInterfaceSetL2XconnectReply) Size() (size int) {
2283         if m == nil {
2284                 return 0
2285         }
2286         size += 4 // m.Retval
2287         return size
2288 }
2289 func (m *SwInterfaceSetL2XconnectReply) Marshal(b []byte) ([]byte, error) {
2290         if b == nil {
2291                 b = make([]byte, m.Size())
2292         }
2293         buf := codec.NewBuffer(b)
2294         buf.EncodeInt32(m.Retval)
2295         return buf.Bytes(), nil
2296 }
2297 func (m *SwInterfaceSetL2XconnectReply) Unmarshal(b []byte) error {
2298         buf := codec.NewBuffer(b)
2299         m.Retval = buf.DecodeInt32()
2300         return nil
2301 }
2302
2303 // SwInterfaceSetVpath defines message 'sw_interface_set_vpath'.
2304 type SwInterfaceSetVpath struct {
2305         SwIfIndex interface_types.InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
2306         Enable    bool                           `binapi:"bool,name=enable,default=4.294967295e+09" json:"enable,omitempty"`
2307 }
2308
2309 func (m *SwInterfaceSetVpath) Reset()               { *m = SwInterfaceSetVpath{} }
2310 func (*SwInterfaceSetVpath) GetMessageName() string { return "sw_interface_set_vpath" }
2311 func (*SwInterfaceSetVpath) GetCrcString() string   { return "ae6cfcfb" }
2312 func (*SwInterfaceSetVpath) GetMessageType() api.MessageType {
2313         return api.RequestMessage
2314 }
2315
2316 func (m *SwInterfaceSetVpath) Size() (size int) {
2317         if m == nil {
2318                 return 0
2319         }
2320         size += 4 // m.SwIfIndex
2321         size += 1 // m.Enable
2322         return size
2323 }
2324 func (m *SwInterfaceSetVpath) Marshal(b []byte) ([]byte, error) {
2325         if b == nil {
2326                 b = make([]byte, m.Size())
2327         }
2328         buf := codec.NewBuffer(b)
2329         buf.EncodeUint32(uint32(m.SwIfIndex))
2330         buf.EncodeBool(m.Enable)
2331         return buf.Bytes(), nil
2332 }
2333 func (m *SwInterfaceSetVpath) Unmarshal(b []byte) error {
2334         buf := codec.NewBuffer(b)
2335         m.SwIfIndex = interface_types.InterfaceIndex(buf.DecodeUint32())
2336         m.Enable = buf.DecodeBool()
2337         return nil
2338 }
2339
2340 // SwInterfaceSetVpathReply defines message 'sw_interface_set_vpath_reply'.
2341 type SwInterfaceSetVpathReply struct {
2342         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
2343 }
2344
2345 func (m *SwInterfaceSetVpathReply) Reset()               { *m = SwInterfaceSetVpathReply{} }
2346 func (*SwInterfaceSetVpathReply) GetMessageName() string { return "sw_interface_set_vpath_reply" }
2347 func (*SwInterfaceSetVpathReply) GetCrcString() string   { return "e8d4e804" }
2348 func (*SwInterfaceSetVpathReply) GetMessageType() api.MessageType {
2349         return api.ReplyMessage
2350 }
2351
2352 func (m *SwInterfaceSetVpathReply) Size() (size int) {
2353         if m == nil {
2354                 return 0
2355         }
2356         size += 4 // m.Retval
2357         return size
2358 }
2359 func (m *SwInterfaceSetVpathReply) Marshal(b []byte) ([]byte, error) {
2360         if b == nil {
2361                 b = make([]byte, m.Size())
2362         }
2363         buf := codec.NewBuffer(b)
2364         buf.EncodeInt32(m.Retval)
2365         return buf.Bytes(), nil
2366 }
2367 func (m *SwInterfaceSetVpathReply) Unmarshal(b []byte) error {
2368         buf := codec.NewBuffer(b)
2369         m.Retval = buf.DecodeInt32()
2370         return nil
2371 }
2372
2373 // WantL2ArpTermEvents defines message 'want_l2_arp_term_events'.
2374 type WantL2ArpTermEvents struct {
2375         Enable bool   `binapi:"bool,name=enable" json:"enable,omitempty"`
2376         PID    uint32 `binapi:"u32,name=pid" json:"pid,omitempty"`
2377 }
2378
2379 func (m *WantL2ArpTermEvents) Reset()               { *m = WantL2ArpTermEvents{} }
2380 func (*WantL2ArpTermEvents) GetMessageName() string { return "want_l2_arp_term_events" }
2381 func (*WantL2ArpTermEvents) GetCrcString() string   { return "3ec6d6c2" }
2382 func (*WantL2ArpTermEvents) GetMessageType() api.MessageType {
2383         return api.RequestMessage
2384 }
2385
2386 func (m *WantL2ArpTermEvents) Size() (size int) {
2387         if m == nil {
2388                 return 0
2389         }
2390         size += 1 // m.Enable
2391         size += 4 // m.PID
2392         return size
2393 }
2394 func (m *WantL2ArpTermEvents) Marshal(b []byte) ([]byte, error) {
2395         if b == nil {
2396                 b = make([]byte, m.Size())
2397         }
2398         buf := codec.NewBuffer(b)
2399         buf.EncodeBool(m.Enable)
2400         buf.EncodeUint32(m.PID)
2401         return buf.Bytes(), nil
2402 }
2403 func (m *WantL2ArpTermEvents) Unmarshal(b []byte) error {
2404         buf := codec.NewBuffer(b)
2405         m.Enable = buf.DecodeBool()
2406         m.PID = buf.DecodeUint32()
2407         return nil
2408 }
2409
2410 // WantL2ArpTermEventsReply defines message 'want_l2_arp_term_events_reply'.
2411 type WantL2ArpTermEventsReply struct {
2412         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
2413 }
2414
2415 func (m *WantL2ArpTermEventsReply) Reset()               { *m = WantL2ArpTermEventsReply{} }
2416 func (*WantL2ArpTermEventsReply) GetMessageName() string { return "want_l2_arp_term_events_reply" }
2417 func (*WantL2ArpTermEventsReply) GetCrcString() string   { return "e8d4e804" }
2418 func (*WantL2ArpTermEventsReply) GetMessageType() api.MessageType {
2419         return api.ReplyMessage
2420 }
2421
2422 func (m *WantL2ArpTermEventsReply) Size() (size int) {
2423         if m == nil {
2424                 return 0
2425         }
2426         size += 4 // m.Retval
2427         return size
2428 }
2429 func (m *WantL2ArpTermEventsReply) Marshal(b []byte) ([]byte, error) {
2430         if b == nil {
2431                 b = make([]byte, m.Size())
2432         }
2433         buf := codec.NewBuffer(b)
2434         buf.EncodeInt32(m.Retval)
2435         return buf.Bytes(), nil
2436 }
2437 func (m *WantL2ArpTermEventsReply) Unmarshal(b []byte) error {
2438         buf := codec.NewBuffer(b)
2439         m.Retval = buf.DecodeInt32()
2440         return nil
2441 }
2442
2443 // WantL2MacsEvents defines message 'want_l2_macs_events'.
2444 // Deprecated: the message will be removed in the future versions
2445 type WantL2MacsEvents struct {
2446         LearnLimit     uint32 `binapi:"u32,name=learn_limit,default=1000" json:"learn_limit,omitempty"`
2447         ScanDelay      uint8  `binapi:"u8,name=scan_delay,default=10" json:"scan_delay,omitempty"`
2448         MaxMacsInEvent uint8  `binapi:"u8,name=max_macs_in_event,default=10" json:"max_macs_in_event,omitempty"`
2449         EnableDisable  bool   `binapi:"bool,name=enable_disable,default=true" json:"enable_disable,omitempty"`
2450         PID            uint32 `binapi:"u32,name=pid" json:"pid,omitempty"`
2451 }
2452
2453 func (m *WantL2MacsEvents) Reset()               { *m = WantL2MacsEvents{} }
2454 func (*WantL2MacsEvents) GetMessageName() string { return "want_l2_macs_events" }
2455 func (*WantL2MacsEvents) GetCrcString() string   { return "9aabdfde" }
2456 func (*WantL2MacsEvents) GetMessageType() api.MessageType {
2457         return api.RequestMessage
2458 }
2459
2460 func (m *WantL2MacsEvents) Size() (size int) {
2461         if m == nil {
2462                 return 0
2463         }
2464         size += 4 // m.LearnLimit
2465         size += 1 // m.ScanDelay
2466         size += 1 // m.MaxMacsInEvent
2467         size += 1 // m.EnableDisable
2468         size += 4 // m.PID
2469         return size
2470 }
2471 func (m *WantL2MacsEvents) Marshal(b []byte) ([]byte, error) {
2472         if b == nil {
2473                 b = make([]byte, m.Size())
2474         }
2475         buf := codec.NewBuffer(b)
2476         buf.EncodeUint32(m.LearnLimit)
2477         buf.EncodeUint8(m.ScanDelay)
2478         buf.EncodeUint8(m.MaxMacsInEvent)
2479         buf.EncodeBool(m.EnableDisable)
2480         buf.EncodeUint32(m.PID)
2481         return buf.Bytes(), nil
2482 }
2483 func (m *WantL2MacsEvents) Unmarshal(b []byte) error {
2484         buf := codec.NewBuffer(b)
2485         m.LearnLimit = buf.DecodeUint32()
2486         m.ScanDelay = buf.DecodeUint8()
2487         m.MaxMacsInEvent = buf.DecodeUint8()
2488         m.EnableDisable = buf.DecodeBool()
2489         m.PID = buf.DecodeUint32()
2490         return nil
2491 }
2492
2493 // WantL2MacsEvents2 defines message 'want_l2_macs_events2'.
2494 type WantL2MacsEvents2 struct {
2495         MaxMacsInEvent uint8  `binapi:"u8,name=max_macs_in_event,default=10" json:"max_macs_in_event,omitempty"`
2496         EnableDisable  bool   `binapi:"bool,name=enable_disable,default=true" json:"enable_disable,omitempty"`
2497         PID            uint32 `binapi:"u32,name=pid" json:"pid,omitempty"`
2498 }
2499
2500 func (m *WantL2MacsEvents2) Reset()               { *m = WantL2MacsEvents2{} }
2501 func (*WantL2MacsEvents2) GetMessageName() string { return "want_l2_macs_events2" }
2502 func (*WantL2MacsEvents2) GetCrcString() string   { return "cc1377b0" }
2503 func (*WantL2MacsEvents2) GetMessageType() api.MessageType {
2504         return api.RequestMessage
2505 }
2506
2507 func (m *WantL2MacsEvents2) Size() (size int) {
2508         if m == nil {
2509                 return 0
2510         }
2511         size += 1 // m.MaxMacsInEvent
2512         size += 1 // m.EnableDisable
2513         size += 4 // m.PID
2514         return size
2515 }
2516 func (m *WantL2MacsEvents2) Marshal(b []byte) ([]byte, error) {
2517         if b == nil {
2518                 b = make([]byte, m.Size())
2519         }
2520         buf := codec.NewBuffer(b)
2521         buf.EncodeUint8(m.MaxMacsInEvent)
2522         buf.EncodeBool(m.EnableDisable)
2523         buf.EncodeUint32(m.PID)
2524         return buf.Bytes(), nil
2525 }
2526 func (m *WantL2MacsEvents2) Unmarshal(b []byte) error {
2527         buf := codec.NewBuffer(b)
2528         m.MaxMacsInEvent = buf.DecodeUint8()
2529         m.EnableDisable = buf.DecodeBool()
2530         m.PID = buf.DecodeUint32()
2531         return nil
2532 }
2533
2534 // WantL2MacsEvents2Reply defines message 'want_l2_macs_events2_reply'.
2535 type WantL2MacsEvents2Reply struct {
2536         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
2537 }
2538
2539 func (m *WantL2MacsEvents2Reply) Reset()               { *m = WantL2MacsEvents2Reply{} }
2540 func (*WantL2MacsEvents2Reply) GetMessageName() string { return "want_l2_macs_events2_reply" }
2541 func (*WantL2MacsEvents2Reply) GetCrcString() string   { return "e8d4e804" }
2542 func (*WantL2MacsEvents2Reply) GetMessageType() api.MessageType {
2543         return api.ReplyMessage
2544 }
2545
2546 func (m *WantL2MacsEvents2Reply) Size() (size int) {
2547         if m == nil {
2548                 return 0
2549         }
2550         size += 4 // m.Retval
2551         return size
2552 }
2553 func (m *WantL2MacsEvents2Reply) Marshal(b []byte) ([]byte, error) {
2554         if b == nil {
2555                 b = make([]byte, m.Size())
2556         }
2557         buf := codec.NewBuffer(b)
2558         buf.EncodeInt32(m.Retval)
2559         return buf.Bytes(), nil
2560 }
2561 func (m *WantL2MacsEvents2Reply) Unmarshal(b []byte) error {
2562         buf := codec.NewBuffer(b)
2563         m.Retval = buf.DecodeInt32()
2564         return nil
2565 }
2566
2567 // WantL2MacsEventsReply defines message 'want_l2_macs_events_reply'.
2568 // Deprecated: the message will be removed in the future versions
2569 type WantL2MacsEventsReply struct {
2570         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
2571 }
2572
2573 func (m *WantL2MacsEventsReply) Reset()               { *m = WantL2MacsEventsReply{} }
2574 func (*WantL2MacsEventsReply) GetMessageName() string { return "want_l2_macs_events_reply" }
2575 func (*WantL2MacsEventsReply) GetCrcString() string   { return "e8d4e804" }
2576 func (*WantL2MacsEventsReply) GetMessageType() api.MessageType {
2577         return api.ReplyMessage
2578 }
2579
2580 func (m *WantL2MacsEventsReply) Size() (size int) {
2581         if m == nil {
2582                 return 0
2583         }
2584         size += 4 // m.Retval
2585         return size
2586 }
2587 func (m *WantL2MacsEventsReply) Marshal(b []byte) ([]byte, error) {
2588         if b == nil {
2589                 b = make([]byte, m.Size())
2590         }
2591         buf := codec.NewBuffer(b)
2592         buf.EncodeInt32(m.Retval)
2593         return buf.Bytes(), nil
2594 }
2595 func (m *WantL2MacsEventsReply) Unmarshal(b []byte) error {
2596         buf := codec.NewBuffer(b)
2597         m.Retval = buf.DecodeInt32()
2598         return nil
2599 }
2600
2601 func init() { file_l2_binapi_init() }
2602 func file_l2_binapi_init() {
2603         api.RegisterMessage((*BdIPMacAddDel)(nil), "bd_ip_mac_add_del_0257c869")
2604         api.RegisterMessage((*BdIPMacAddDelReply)(nil), "bd_ip_mac_add_del_reply_e8d4e804")
2605         api.RegisterMessage((*BdIPMacDetails)(nil), "bd_ip_mac_details_545af86a")
2606         api.RegisterMessage((*BdIPMacDump)(nil), "bd_ip_mac_dump_c25fdce6")
2607         api.RegisterMessage((*BdIPMacFlush)(nil), "bd_ip_mac_flush_c25fdce6")
2608         api.RegisterMessage((*BdIPMacFlushReply)(nil), "bd_ip_mac_flush_reply_e8d4e804")
2609         api.RegisterMessage((*BridgeDomainAddDel)(nil), "bridge_domain_add_del_600b7170")
2610         api.RegisterMessage((*BridgeDomainAddDelReply)(nil), "bridge_domain_add_del_reply_e8d4e804")
2611         api.RegisterMessage((*BridgeDomainDetails)(nil), "bridge_domain_details_0fa506fd")
2612         api.RegisterMessage((*BridgeDomainDump)(nil), "bridge_domain_dump_74396a43")
2613         api.RegisterMessage((*BridgeDomainSetDefaultLearnLimit)(nil), "bridge_domain_set_default_learn_limit_f097ffce")
2614         api.RegisterMessage((*BridgeDomainSetDefaultLearnLimitReply)(nil), "bridge_domain_set_default_learn_limit_reply_e8d4e804")
2615         api.RegisterMessage((*BridgeDomainSetLearnLimit)(nil), "bridge_domain_set_learn_limit_89c52b5f")
2616         api.RegisterMessage((*BridgeDomainSetLearnLimitReply)(nil), "bridge_domain_set_learn_limit_reply_e8d4e804")
2617         api.RegisterMessage((*BridgeDomainSetMacAge)(nil), "bridge_domain_set_mac_age_b537ad7b")
2618         api.RegisterMessage((*BridgeDomainSetMacAgeReply)(nil), "bridge_domain_set_mac_age_reply_e8d4e804")
2619         api.RegisterMessage((*BridgeFlags)(nil), "bridge_flags_1b0c5fbd")
2620         api.RegisterMessage((*BridgeFlagsReply)(nil), "bridge_flags_reply_29b2a2b3")
2621         api.RegisterMessage((*BviCreate)(nil), "bvi_create_f5398559")
2622         api.RegisterMessage((*BviCreateReply)(nil), "bvi_create_reply_5383d31f")
2623         api.RegisterMessage((*BviDelete)(nil), "bvi_delete_f9e6675e")
2624         api.RegisterMessage((*BviDeleteReply)(nil), "bvi_delete_reply_e8d4e804")
2625         api.RegisterMessage((*L2ArpTermEvent)(nil), "l2_arp_term_event_6963e07a")
2626         api.RegisterMessage((*L2FibClearTable)(nil), "l2_fib_clear_table_51077d14")
2627         api.RegisterMessage((*L2FibClearTableReply)(nil), "l2_fib_clear_table_reply_e8d4e804")
2628         api.RegisterMessage((*L2FibTableDetails)(nil), "l2_fib_table_details_a44ef6b8")
2629         api.RegisterMessage((*L2FibTableDump)(nil), "l2_fib_table_dump_c25fdce6")
2630         api.RegisterMessage((*L2Flags)(nil), "l2_flags_fc41cfe8")
2631         api.RegisterMessage((*L2FlagsReply)(nil), "l2_flags_reply_29b2a2b3")
2632         api.RegisterMessage((*L2InterfaceEfpFilter)(nil), "l2_interface_efp_filter_5501adee")
2633         api.RegisterMessage((*L2InterfaceEfpFilterReply)(nil), "l2_interface_efp_filter_reply_e8d4e804")
2634         api.RegisterMessage((*L2InterfacePbbTagRewrite)(nil), "l2_interface_pbb_tag_rewrite_38e802a8")
2635         api.RegisterMessage((*L2InterfacePbbTagRewriteReply)(nil), "l2_interface_pbb_tag_rewrite_reply_e8d4e804")
2636         api.RegisterMessage((*L2InterfaceVlanTagRewrite)(nil), "l2_interface_vlan_tag_rewrite_62cc0bbc")
2637         api.RegisterMessage((*L2InterfaceVlanTagRewriteReply)(nil), "l2_interface_vlan_tag_rewrite_reply_e8d4e804")
2638         api.RegisterMessage((*L2MacsEvent)(nil), "l2_macs_event_44b8fd64")
2639         api.RegisterMessage((*L2PatchAddDel)(nil), "l2_patch_add_del_a1f6a6f3")
2640         api.RegisterMessage((*L2PatchAddDelReply)(nil), "l2_patch_add_del_reply_e8d4e804")
2641         api.RegisterMessage((*L2XconnectDetails)(nil), "l2_xconnect_details_472b6b67")
2642         api.RegisterMessage((*L2XconnectDump)(nil), "l2_xconnect_dump_51077d14")
2643         api.RegisterMessage((*L2fibAddDel)(nil), "l2fib_add_del_eddda487")
2644         api.RegisterMessage((*L2fibAddDelReply)(nil), "l2fib_add_del_reply_e8d4e804")
2645         api.RegisterMessage((*L2fibFlushAll)(nil), "l2fib_flush_all_51077d14")
2646         api.RegisterMessage((*L2fibFlushAllReply)(nil), "l2fib_flush_all_reply_e8d4e804")
2647         api.RegisterMessage((*L2fibFlushBd)(nil), "l2fib_flush_bd_c25fdce6")
2648         api.RegisterMessage((*L2fibFlushBdReply)(nil), "l2fib_flush_bd_reply_e8d4e804")
2649         api.RegisterMessage((*L2fibFlushInt)(nil), "l2fib_flush_int_f9e6675e")
2650         api.RegisterMessage((*L2fibFlushIntReply)(nil), "l2fib_flush_int_reply_e8d4e804")
2651         api.RegisterMessage((*L2fibSetScanDelay)(nil), "l2fib_set_scan_delay_a3b968a4")
2652         api.RegisterMessage((*L2fibSetScanDelayReply)(nil), "l2fib_set_scan_delay_reply_e8d4e804")
2653         api.RegisterMessage((*SwInterfaceSetL2Bridge)(nil), "sw_interface_set_l2_bridge_d0678b13")
2654         api.RegisterMessage((*SwInterfaceSetL2BridgeReply)(nil), "sw_interface_set_l2_bridge_reply_e8d4e804")
2655         api.RegisterMessage((*SwInterfaceSetL2Xconnect)(nil), "sw_interface_set_l2_xconnect_4fa28a85")
2656         api.RegisterMessage((*SwInterfaceSetL2XconnectReply)(nil), "sw_interface_set_l2_xconnect_reply_e8d4e804")
2657         api.RegisterMessage((*SwInterfaceSetVpath)(nil), "sw_interface_set_vpath_ae6cfcfb")
2658         api.RegisterMessage((*SwInterfaceSetVpathReply)(nil), "sw_interface_set_vpath_reply_e8d4e804")
2659         api.RegisterMessage((*WantL2ArpTermEvents)(nil), "want_l2_arp_term_events_3ec6d6c2")
2660         api.RegisterMessage((*WantL2ArpTermEventsReply)(nil), "want_l2_arp_term_events_reply_e8d4e804")
2661         api.RegisterMessage((*WantL2MacsEvents)(nil), "want_l2_macs_events_9aabdfde")
2662         api.RegisterMessage((*WantL2MacsEvents2)(nil), "want_l2_macs_events2_cc1377b0")
2663         api.RegisterMessage((*WantL2MacsEvents2Reply)(nil), "want_l2_macs_events2_reply_e8d4e804")
2664         api.RegisterMessage((*WantL2MacsEventsReply)(nil), "want_l2_macs_events_reply_e8d4e804")
2665 }
2666
2667 // Messages returns list of all messages in this module.
2668 func AllMessages() []api.Message {
2669         return []api.Message{
2670                 (*BdIPMacAddDel)(nil),
2671                 (*BdIPMacAddDelReply)(nil),
2672                 (*BdIPMacDetails)(nil),
2673                 (*BdIPMacDump)(nil),
2674                 (*BdIPMacFlush)(nil),
2675                 (*BdIPMacFlushReply)(nil),
2676                 (*BridgeDomainAddDel)(nil),
2677                 (*BridgeDomainAddDelReply)(nil),
2678                 (*BridgeDomainDetails)(nil),
2679                 (*BridgeDomainDump)(nil),
2680                 (*BridgeDomainSetDefaultLearnLimit)(nil),
2681                 (*BridgeDomainSetDefaultLearnLimitReply)(nil),
2682                 (*BridgeDomainSetLearnLimit)(nil),
2683                 (*BridgeDomainSetLearnLimitReply)(nil),
2684                 (*BridgeDomainSetMacAge)(nil),
2685                 (*BridgeDomainSetMacAgeReply)(nil),
2686                 (*BridgeFlags)(nil),
2687                 (*BridgeFlagsReply)(nil),
2688                 (*BviCreate)(nil),
2689                 (*BviCreateReply)(nil),
2690                 (*BviDelete)(nil),
2691                 (*BviDeleteReply)(nil),
2692                 (*L2ArpTermEvent)(nil),
2693                 (*L2FibClearTable)(nil),
2694                 (*L2FibClearTableReply)(nil),
2695                 (*L2FibTableDetails)(nil),
2696                 (*L2FibTableDump)(nil),
2697                 (*L2Flags)(nil),
2698                 (*L2FlagsReply)(nil),
2699                 (*L2InterfaceEfpFilter)(nil),
2700                 (*L2InterfaceEfpFilterReply)(nil),
2701                 (*L2InterfacePbbTagRewrite)(nil),
2702                 (*L2InterfacePbbTagRewriteReply)(nil),
2703                 (*L2InterfaceVlanTagRewrite)(nil),
2704                 (*L2InterfaceVlanTagRewriteReply)(nil),
2705                 (*L2MacsEvent)(nil),
2706                 (*L2PatchAddDel)(nil),
2707                 (*L2PatchAddDelReply)(nil),
2708                 (*L2XconnectDetails)(nil),
2709                 (*L2XconnectDump)(nil),
2710                 (*L2fibAddDel)(nil),
2711                 (*L2fibAddDelReply)(nil),
2712                 (*L2fibFlushAll)(nil),
2713                 (*L2fibFlushAllReply)(nil),
2714                 (*L2fibFlushBd)(nil),
2715                 (*L2fibFlushBdReply)(nil),
2716                 (*L2fibFlushInt)(nil),
2717                 (*L2fibFlushIntReply)(nil),
2718                 (*L2fibSetScanDelay)(nil),
2719                 (*L2fibSetScanDelayReply)(nil),
2720                 (*SwInterfaceSetL2Bridge)(nil),
2721                 (*SwInterfaceSetL2BridgeReply)(nil),
2722                 (*SwInterfaceSetL2Xconnect)(nil),
2723                 (*SwInterfaceSetL2XconnectReply)(nil),
2724                 (*SwInterfaceSetVpath)(nil),
2725                 (*SwInterfaceSetVpathReply)(nil),
2726                 (*WantL2ArpTermEvents)(nil),
2727                 (*WantL2ArpTermEventsReply)(nil),
2728                 (*WantL2MacsEvents)(nil),
2729                 (*WantL2MacsEvents2)(nil),
2730                 (*WantL2MacsEvents2Reply)(nil),
2731                 (*WantL2MacsEventsReply)(nil),
2732         }
2733 }