ff82ee77310cfe7ab27112382aed13c1524f2692
[govpp.git] / internal / testbinapi / binapi2001 / af_packet / af_packet.ba.go
1 // Code generated by GoVPP's binapi-generator. DO NOT EDIT.
2 // versions:
3 //  binapi-generator: v0.4.0-dev
4 //  VPP:              20.01
5 // source: .vppapi/core/af_packet.api.json
6
7 // Package af_packet contains generated bindings for API file af_packet.api.
8 //
9 // Contents:
10 //   2 aliases
11 //   6 enums
12 //   8 messages
13 //
14 package af_packet
15
16 import (
17         api "git.fd.io/govpp.git/api"
18         codec "git.fd.io/govpp.git/codec"
19         "net"
20         "strconv"
21 )
22
23 // This is a compile-time assertion to ensure that this generated file
24 // is compatible with the GoVPP api package it is being compiled against.
25 // A compilation error at this line likely means your copy of the
26 // GoVPP api package needs to be updated.
27 const _ = api.GoVppAPIPackageIsVersion2
28
29 const (
30         APIFile    = "af_packet"
31         APIVersion = "2.0.0"
32         VersionCrc = 0xba745e20
33 )
34
35 // IfStatusFlags defines enum 'if_status_flags'.
36 type IfStatusFlags uint32
37
38 const (
39         IF_STATUS_API_FLAG_ADMIN_UP IfStatusFlags = 1
40         IF_STATUS_API_FLAG_LINK_UP  IfStatusFlags = 2
41 )
42
43 var (
44         IfStatusFlags_name = map[uint32]string{
45                 1: "IF_STATUS_API_FLAG_ADMIN_UP",
46                 2: "IF_STATUS_API_FLAG_LINK_UP",
47         }
48         IfStatusFlags_value = map[string]uint32{
49                 "IF_STATUS_API_FLAG_ADMIN_UP": 1,
50                 "IF_STATUS_API_FLAG_LINK_UP":  2,
51         }
52 )
53
54 func (x IfStatusFlags) String() string {
55         s, ok := IfStatusFlags_name[uint32(x)]
56         if ok {
57                 return s
58         }
59         str := func(n uint32) string {
60                 s, ok := IfStatusFlags_name[uint32(n)]
61                 if ok {
62                         return s
63                 }
64                 return "IfStatusFlags(" + strconv.Itoa(int(n)) + ")"
65         }
66         for i := uint32(0); i <= 32; i++ {
67                 val := uint32(x)
68                 if val&(1<<i) != 0 {
69                         if s != "" {
70                                 s += "|"
71                         }
72                         s += str(1 << i)
73                 }
74         }
75         if s == "" {
76                 return str(uint32(x))
77         }
78         return s
79 }
80
81 // IfType defines enum 'if_type'.
82 type IfType uint32
83
84 const (
85         IF_API_TYPE_HARDWARE IfType = 1
86         IF_API_TYPE_SUB      IfType = 2
87         IF_API_TYPE_P2P      IfType = 3
88         IF_API_TYPE_PIPE     IfType = 4
89 )
90
91 var (
92         IfType_name = map[uint32]string{
93                 1: "IF_API_TYPE_HARDWARE",
94                 2: "IF_API_TYPE_SUB",
95                 3: "IF_API_TYPE_P2P",
96                 4: "IF_API_TYPE_PIPE",
97         }
98         IfType_value = map[string]uint32{
99                 "IF_API_TYPE_HARDWARE": 1,
100                 "IF_API_TYPE_SUB":      2,
101                 "IF_API_TYPE_P2P":      3,
102                 "IF_API_TYPE_PIPE":     4,
103         }
104 )
105
106 func (x IfType) String() string {
107         s, ok := IfType_name[uint32(x)]
108         if ok {
109                 return s
110         }
111         return "IfType(" + strconv.Itoa(int(x)) + ")"
112 }
113
114 // LinkDuplex defines enum 'link_duplex'.
115 type LinkDuplex uint32
116
117 const (
118         LINK_DUPLEX_API_UNKNOWN LinkDuplex = 0
119         LINK_DUPLEX_API_HALF    LinkDuplex = 1
120         LINK_DUPLEX_API_FULL    LinkDuplex = 2
121 )
122
123 var (
124         LinkDuplex_name = map[uint32]string{
125                 0: "LINK_DUPLEX_API_UNKNOWN",
126                 1: "LINK_DUPLEX_API_HALF",
127                 2: "LINK_DUPLEX_API_FULL",
128         }
129         LinkDuplex_value = map[string]uint32{
130                 "LINK_DUPLEX_API_UNKNOWN": 0,
131                 "LINK_DUPLEX_API_HALF":    1,
132                 "LINK_DUPLEX_API_FULL":    2,
133         }
134 )
135
136 func (x LinkDuplex) String() string {
137         s, ok := LinkDuplex_name[uint32(x)]
138         if ok {
139                 return s
140         }
141         return "LinkDuplex(" + strconv.Itoa(int(x)) + ")"
142 }
143
144 // MtuProto defines enum 'mtu_proto'.
145 type MtuProto uint32
146
147 const (
148         MTU_PROTO_API_L3   MtuProto = 1
149         MTU_PROTO_API_IP4  MtuProto = 2
150         MTU_PROTO_API_IP6  MtuProto = 3
151         MTU_PROTO_API_MPLS MtuProto = 4
152         MTU_PROTO_API_N    MtuProto = 5
153 )
154
155 var (
156         MtuProto_name = map[uint32]string{
157                 1: "MTU_PROTO_API_L3",
158                 2: "MTU_PROTO_API_IP4",
159                 3: "MTU_PROTO_API_IP6",
160                 4: "MTU_PROTO_API_MPLS",
161                 5: "MTU_PROTO_API_N",
162         }
163         MtuProto_value = map[string]uint32{
164                 "MTU_PROTO_API_L3":   1,
165                 "MTU_PROTO_API_IP4":  2,
166                 "MTU_PROTO_API_IP6":  3,
167                 "MTU_PROTO_API_MPLS": 4,
168                 "MTU_PROTO_API_N":    5,
169         }
170 )
171
172 func (x MtuProto) String() string {
173         s, ok := MtuProto_name[uint32(x)]
174         if ok {
175                 return s
176         }
177         return "MtuProto(" + strconv.Itoa(int(x)) + ")"
178 }
179
180 // RxMode defines enum 'rx_mode'.
181 type RxMode uint32
182
183 const (
184         RX_MODE_API_UNKNOWN   RxMode = 0
185         RX_MODE_API_POLLING   RxMode = 1
186         RX_MODE_API_INTERRUPT RxMode = 2
187         RX_MODE_API_ADAPTIVE  RxMode = 3
188         RX_MODE_API_DEFAULT   RxMode = 4
189 )
190
191 var (
192         RxMode_name = map[uint32]string{
193                 0: "RX_MODE_API_UNKNOWN",
194                 1: "RX_MODE_API_POLLING",
195                 2: "RX_MODE_API_INTERRUPT",
196                 3: "RX_MODE_API_ADAPTIVE",
197                 4: "RX_MODE_API_DEFAULT",
198         }
199         RxMode_value = map[string]uint32{
200                 "RX_MODE_API_UNKNOWN":   0,
201                 "RX_MODE_API_POLLING":   1,
202                 "RX_MODE_API_INTERRUPT": 2,
203                 "RX_MODE_API_ADAPTIVE":  3,
204                 "RX_MODE_API_DEFAULT":   4,
205         }
206 )
207
208 func (x RxMode) String() string {
209         s, ok := RxMode_name[uint32(x)]
210         if ok {
211                 return s
212         }
213         return "RxMode(" + strconv.Itoa(int(x)) + ")"
214 }
215
216 // SubIfFlags defines enum 'sub_if_flags'.
217 type SubIfFlags uint32
218
219 const (
220         SUB_IF_API_FLAG_NO_TAGS           SubIfFlags = 1
221         SUB_IF_API_FLAG_ONE_TAG           SubIfFlags = 2
222         SUB_IF_API_FLAG_TWO_TAGS          SubIfFlags = 4
223         SUB_IF_API_FLAG_DOT1AD            SubIfFlags = 8
224         SUB_IF_API_FLAG_EXACT_MATCH       SubIfFlags = 16
225         SUB_IF_API_FLAG_DEFAULT           SubIfFlags = 32
226         SUB_IF_API_FLAG_OUTER_VLAN_ID_ANY SubIfFlags = 64
227         SUB_IF_API_FLAG_INNER_VLAN_ID_ANY SubIfFlags = 128
228         SUB_IF_API_FLAG_MASK_VNET         SubIfFlags = 254
229         SUB_IF_API_FLAG_DOT1AH            SubIfFlags = 256
230 )
231
232 var (
233         SubIfFlags_name = map[uint32]string{
234                 1:   "SUB_IF_API_FLAG_NO_TAGS",
235                 2:   "SUB_IF_API_FLAG_ONE_TAG",
236                 4:   "SUB_IF_API_FLAG_TWO_TAGS",
237                 8:   "SUB_IF_API_FLAG_DOT1AD",
238                 16:  "SUB_IF_API_FLAG_EXACT_MATCH",
239                 32:  "SUB_IF_API_FLAG_DEFAULT",
240                 64:  "SUB_IF_API_FLAG_OUTER_VLAN_ID_ANY",
241                 128: "SUB_IF_API_FLAG_INNER_VLAN_ID_ANY",
242                 254: "SUB_IF_API_FLAG_MASK_VNET",
243                 256: "SUB_IF_API_FLAG_DOT1AH",
244         }
245         SubIfFlags_value = map[string]uint32{
246                 "SUB_IF_API_FLAG_NO_TAGS":           1,
247                 "SUB_IF_API_FLAG_ONE_TAG":           2,
248                 "SUB_IF_API_FLAG_TWO_TAGS":          4,
249                 "SUB_IF_API_FLAG_DOT1AD":            8,
250                 "SUB_IF_API_FLAG_EXACT_MATCH":       16,
251                 "SUB_IF_API_FLAG_DEFAULT":           32,
252                 "SUB_IF_API_FLAG_OUTER_VLAN_ID_ANY": 64,
253                 "SUB_IF_API_FLAG_INNER_VLAN_ID_ANY": 128,
254                 "SUB_IF_API_FLAG_MASK_VNET":         254,
255                 "SUB_IF_API_FLAG_DOT1AH":            256,
256         }
257 )
258
259 func (x SubIfFlags) String() string {
260         s, ok := SubIfFlags_name[uint32(x)]
261         if ok {
262                 return s
263         }
264         str := func(n uint32) string {
265                 s, ok := SubIfFlags_name[uint32(n)]
266                 if ok {
267                         return s
268                 }
269                 return "SubIfFlags(" + strconv.Itoa(int(n)) + ")"
270         }
271         for i := uint32(0); i <= 32; i++ {
272                 val := uint32(x)
273                 if val&(1<<i) != 0 {
274                         if s != "" {
275                                 s += "|"
276                         }
277                         s += str(1 << i)
278                 }
279         }
280         if s == "" {
281                 return str(uint32(x))
282         }
283         return s
284 }
285
286 // InterfaceIndex defines alias 'interface_index'.
287 type InterfaceIndex uint32
288
289 // MacAddress defines alias 'mac_address'.
290 type MacAddress [6]uint8
291
292 func ParseMacAddress(s string) (MacAddress, error) {
293         var macaddr MacAddress
294         mac, err := net.ParseMAC(s)
295         if err != nil {
296                 return macaddr, err
297         }
298         copy(macaddr[:], mac[:])
299         return macaddr, nil
300 }
301 func (x MacAddress) ToMAC() net.HardwareAddr {
302         return net.HardwareAddr(x[:])
303 }
304 func (x MacAddress) String() string {
305         return x.ToMAC().String()
306 }
307 func (x *MacAddress) MarshalText() ([]byte, error) {
308         return []byte(x.String()), nil
309 }
310 func (x *MacAddress) UnmarshalText(text []byte) error {
311         mac, err := ParseMacAddress(string(text))
312         if err != nil {
313                 return err
314         }
315         *x = mac
316         return nil
317 }
318
319 // AfPacketCreate defines message 'af_packet_create'.
320 type AfPacketCreate struct {
321         HwAddr          MacAddress `binapi:"mac_address,name=hw_addr" json:"hw_addr,omitempty"`
322         UseRandomHwAddr bool       `binapi:"bool,name=use_random_hw_addr" json:"use_random_hw_addr,omitempty"`
323         HostIfName      string     `binapi:"string[64],name=host_if_name" json:"host_if_name,omitempty"`
324 }
325
326 func (m *AfPacketCreate) Reset()               { *m = AfPacketCreate{} }
327 func (*AfPacketCreate) GetMessageName() string { return "af_packet_create" }
328 func (*AfPacketCreate) GetCrcString() string   { return "a190415f" }
329 func (*AfPacketCreate) GetMessageType() api.MessageType {
330         return api.RequestMessage
331 }
332
333 func (m *AfPacketCreate) Size() (size int) {
334         if m == nil {
335                 return 0
336         }
337         size += 1 * 6 // m.HwAddr
338         size += 1     // m.UseRandomHwAddr
339         size += 64    // m.HostIfName
340         return size
341 }
342 func (m *AfPacketCreate) Marshal(b []byte) ([]byte, error) {
343         if b == nil {
344                 b = make([]byte, m.Size())
345         }
346         buf := codec.NewBuffer(b)
347         buf.EncodeBytes(m.HwAddr[:], 6)
348         buf.EncodeBool(m.UseRandomHwAddr)
349         buf.EncodeString(m.HostIfName, 64)
350         return buf.Bytes(), nil
351 }
352 func (m *AfPacketCreate) Unmarshal(b []byte) error {
353         buf := codec.NewBuffer(b)
354         copy(m.HwAddr[:], buf.DecodeBytes(6))
355         m.UseRandomHwAddr = buf.DecodeBool()
356         m.HostIfName = buf.DecodeString(64)
357         return nil
358 }
359
360 // AfPacketCreateReply defines message 'af_packet_create_reply'.
361 type AfPacketCreateReply struct {
362         Retval    int32          `binapi:"i32,name=retval" json:"retval,omitempty"`
363         SwIfIndex InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
364 }
365
366 func (m *AfPacketCreateReply) Reset()               { *m = AfPacketCreateReply{} }
367 func (*AfPacketCreateReply) GetMessageName() string { return "af_packet_create_reply" }
368 func (*AfPacketCreateReply) GetCrcString() string   { return "5383d31f" }
369 func (*AfPacketCreateReply) GetMessageType() api.MessageType {
370         return api.ReplyMessage
371 }
372
373 func (m *AfPacketCreateReply) Size() (size int) {
374         if m == nil {
375                 return 0
376         }
377         size += 4 // m.Retval
378         size += 4 // m.SwIfIndex
379         return size
380 }
381 func (m *AfPacketCreateReply) Marshal(b []byte) ([]byte, error) {
382         if b == nil {
383                 b = make([]byte, m.Size())
384         }
385         buf := codec.NewBuffer(b)
386         buf.EncodeInt32(m.Retval)
387         buf.EncodeUint32(uint32(m.SwIfIndex))
388         return buf.Bytes(), nil
389 }
390 func (m *AfPacketCreateReply) Unmarshal(b []byte) error {
391         buf := codec.NewBuffer(b)
392         m.Retval = buf.DecodeInt32()
393         m.SwIfIndex = InterfaceIndex(buf.DecodeUint32())
394         return nil
395 }
396
397 // AfPacketDelete defines message 'af_packet_delete'.
398 type AfPacketDelete struct {
399         HostIfName string `binapi:"string[64],name=host_if_name" json:"host_if_name,omitempty"`
400 }
401
402 func (m *AfPacketDelete) Reset()               { *m = AfPacketDelete{} }
403 func (*AfPacketDelete) GetMessageName() string { return "af_packet_delete" }
404 func (*AfPacketDelete) GetCrcString() string   { return "863fa648" }
405 func (*AfPacketDelete) GetMessageType() api.MessageType {
406         return api.RequestMessage
407 }
408
409 func (m *AfPacketDelete) Size() (size int) {
410         if m == nil {
411                 return 0
412         }
413         size += 64 // m.HostIfName
414         return size
415 }
416 func (m *AfPacketDelete) Marshal(b []byte) ([]byte, error) {
417         if b == nil {
418                 b = make([]byte, m.Size())
419         }
420         buf := codec.NewBuffer(b)
421         buf.EncodeString(m.HostIfName, 64)
422         return buf.Bytes(), nil
423 }
424 func (m *AfPacketDelete) Unmarshal(b []byte) error {
425         buf := codec.NewBuffer(b)
426         m.HostIfName = buf.DecodeString(64)
427         return nil
428 }
429
430 // AfPacketDeleteReply defines message 'af_packet_delete_reply'.
431 type AfPacketDeleteReply struct {
432         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
433 }
434
435 func (m *AfPacketDeleteReply) Reset()               { *m = AfPacketDeleteReply{} }
436 func (*AfPacketDeleteReply) GetMessageName() string { return "af_packet_delete_reply" }
437 func (*AfPacketDeleteReply) GetCrcString() string   { return "e8d4e804" }
438 func (*AfPacketDeleteReply) GetMessageType() api.MessageType {
439         return api.ReplyMessage
440 }
441
442 func (m *AfPacketDeleteReply) Size() (size int) {
443         if m == nil {
444                 return 0
445         }
446         size += 4 // m.Retval
447         return size
448 }
449 func (m *AfPacketDeleteReply) Marshal(b []byte) ([]byte, error) {
450         if b == nil {
451                 b = make([]byte, m.Size())
452         }
453         buf := codec.NewBuffer(b)
454         buf.EncodeInt32(m.Retval)
455         return buf.Bytes(), nil
456 }
457 func (m *AfPacketDeleteReply) Unmarshal(b []byte) error {
458         buf := codec.NewBuffer(b)
459         m.Retval = buf.DecodeInt32()
460         return nil
461 }
462
463 // AfPacketDetails defines message 'af_packet_details'.
464 type AfPacketDetails struct {
465         SwIfIndex  InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
466         HostIfName string         `binapi:"string[64],name=host_if_name" json:"host_if_name,omitempty"`
467 }
468
469 func (m *AfPacketDetails) Reset()               { *m = AfPacketDetails{} }
470 func (*AfPacketDetails) GetMessageName() string { return "af_packet_details" }
471 func (*AfPacketDetails) GetCrcString() string   { return "58c7c042" }
472 func (*AfPacketDetails) GetMessageType() api.MessageType {
473         return api.ReplyMessage
474 }
475
476 func (m *AfPacketDetails) Size() (size int) {
477         if m == nil {
478                 return 0
479         }
480         size += 4  // m.SwIfIndex
481         size += 64 // m.HostIfName
482         return size
483 }
484 func (m *AfPacketDetails) Marshal(b []byte) ([]byte, error) {
485         if b == nil {
486                 b = make([]byte, m.Size())
487         }
488         buf := codec.NewBuffer(b)
489         buf.EncodeUint32(uint32(m.SwIfIndex))
490         buf.EncodeString(m.HostIfName, 64)
491         return buf.Bytes(), nil
492 }
493 func (m *AfPacketDetails) Unmarshal(b []byte) error {
494         buf := codec.NewBuffer(b)
495         m.SwIfIndex = InterfaceIndex(buf.DecodeUint32())
496         m.HostIfName = buf.DecodeString(64)
497         return nil
498 }
499
500 // AfPacketDump defines message 'af_packet_dump'.
501 type AfPacketDump struct{}
502
503 func (m *AfPacketDump) Reset()               { *m = AfPacketDump{} }
504 func (*AfPacketDump) GetMessageName() string { return "af_packet_dump" }
505 func (*AfPacketDump) GetCrcString() string   { return "51077d14" }
506 func (*AfPacketDump) GetMessageType() api.MessageType {
507         return api.RequestMessage
508 }
509
510 func (m *AfPacketDump) Size() (size int) {
511         if m == nil {
512                 return 0
513         }
514         return size
515 }
516 func (m *AfPacketDump) Marshal(b []byte) ([]byte, error) {
517         if b == nil {
518                 b = make([]byte, m.Size())
519         }
520         buf := codec.NewBuffer(b)
521         return buf.Bytes(), nil
522 }
523 func (m *AfPacketDump) Unmarshal(b []byte) error {
524         return nil
525 }
526
527 // AfPacketSetL4CksumOffload defines message 'af_packet_set_l4_cksum_offload'.
528 type AfPacketSetL4CksumOffload struct {
529         SwIfIndex InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
530         Set       bool           `binapi:"bool,name=set" json:"set,omitempty"`
531 }
532
533 func (m *AfPacketSetL4CksumOffload) Reset()               { *m = AfPacketSetL4CksumOffload{} }
534 func (*AfPacketSetL4CksumOffload) GetMessageName() string { return "af_packet_set_l4_cksum_offload" }
535 func (*AfPacketSetL4CksumOffload) GetCrcString() string   { return "319cd5c8" }
536 func (*AfPacketSetL4CksumOffload) GetMessageType() api.MessageType {
537         return api.RequestMessage
538 }
539
540 func (m *AfPacketSetL4CksumOffload) Size() (size int) {
541         if m == nil {
542                 return 0
543         }
544         size += 4 // m.SwIfIndex
545         size += 1 // m.Set
546         return size
547 }
548 func (m *AfPacketSetL4CksumOffload) Marshal(b []byte) ([]byte, error) {
549         if b == nil {
550                 b = make([]byte, m.Size())
551         }
552         buf := codec.NewBuffer(b)
553         buf.EncodeUint32(uint32(m.SwIfIndex))
554         buf.EncodeBool(m.Set)
555         return buf.Bytes(), nil
556 }
557 func (m *AfPacketSetL4CksumOffload) Unmarshal(b []byte) error {
558         buf := codec.NewBuffer(b)
559         m.SwIfIndex = InterfaceIndex(buf.DecodeUint32())
560         m.Set = buf.DecodeBool()
561         return nil
562 }
563
564 // AfPacketSetL4CksumOffloadReply defines message 'af_packet_set_l4_cksum_offload_reply'.
565 type AfPacketSetL4CksumOffloadReply struct {
566         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
567 }
568
569 func (m *AfPacketSetL4CksumOffloadReply) Reset() { *m = AfPacketSetL4CksumOffloadReply{} }
570 func (*AfPacketSetL4CksumOffloadReply) GetMessageName() string {
571         return "af_packet_set_l4_cksum_offload_reply"
572 }
573 func (*AfPacketSetL4CksumOffloadReply) GetCrcString() string { return "e8d4e804" }
574 func (*AfPacketSetL4CksumOffloadReply) GetMessageType() api.MessageType {
575         return api.ReplyMessage
576 }
577
578 func (m *AfPacketSetL4CksumOffloadReply) Size() (size int) {
579         if m == nil {
580                 return 0
581         }
582         size += 4 // m.Retval
583         return size
584 }
585 func (m *AfPacketSetL4CksumOffloadReply) Marshal(b []byte) ([]byte, error) {
586         if b == nil {
587                 b = make([]byte, m.Size())
588         }
589         buf := codec.NewBuffer(b)
590         buf.EncodeInt32(m.Retval)
591         return buf.Bytes(), nil
592 }
593 func (m *AfPacketSetL4CksumOffloadReply) Unmarshal(b []byte) error {
594         buf := codec.NewBuffer(b)
595         m.Retval = buf.DecodeInt32()
596         return nil
597 }
598
599 func init() { file_af_packet_binapi_init() }
600 func file_af_packet_binapi_init() {
601         api.RegisterMessage((*AfPacketCreate)(nil), "af_packet_create_a190415f")
602         api.RegisterMessage((*AfPacketCreateReply)(nil), "af_packet_create_reply_5383d31f")
603         api.RegisterMessage((*AfPacketDelete)(nil), "af_packet_delete_863fa648")
604         api.RegisterMessage((*AfPacketDeleteReply)(nil), "af_packet_delete_reply_e8d4e804")
605         api.RegisterMessage((*AfPacketDetails)(nil), "af_packet_details_58c7c042")
606         api.RegisterMessage((*AfPacketDump)(nil), "af_packet_dump_51077d14")
607         api.RegisterMessage((*AfPacketSetL4CksumOffload)(nil), "af_packet_set_l4_cksum_offload_319cd5c8")
608         api.RegisterMessage((*AfPacketSetL4CksumOffloadReply)(nil), "af_packet_set_l4_cksum_offload_reply_e8d4e804")
609 }
610
611 // Messages returns list of all messages in this module.
612 func AllMessages() []api.Message {
613         return []api.Message{
614                 (*AfPacketCreate)(nil),
615                 (*AfPacketCreateReply)(nil),
616                 (*AfPacketDelete)(nil),
617                 (*AfPacketDeleteReply)(nil),
618                 (*AfPacketDetails)(nil),
619                 (*AfPacketDump)(nil),
620                 (*AfPacketSetL4CksumOffload)(nil),
621                 (*AfPacketSetL4CksumOffloadReply)(nil),
622         }
623 }