Documentation ¶
Overview ¶
Package cne is a collection of binding APIs for CNDP. The goal of the Go binding layer is to hide the details for calling CNDP APIs from the developer, plus create higher level APIs.
Index ¶
- Constants
- Variables
- func DisablePromiscuous(name string) error
- func EnablePromiscuous(name string) error
- func GetChannels(name string) (int, error)
- func GetHash(pkt *Packet) uint32
- func GetPromiscuous(name string) (bool, error)
- func GetRingParams(name string) (rxDesc int, txDesc int, err error)
- func IPv4Checksum(ip4Hdr *IPv4Hdr) uint16
- func IPv6Checksum(ip6Hdr *IPv6Hdr) uint16
- func InitCNE() error
- func MakeByteSlice(start uintptr, length int) (data []byte)
- func MakeUint16Slice(start uintptr, length int) (data []uint16)
- func PktBufferAlloc(lportId int, packets []*Packet) int
- func PktBufferFree(packets []*Packet)
- func PktData(pkt *Packet) []byte
- func PktType(pkt *Packet) uint32
- func PktTypes(pkts []*Packet) []uint32
- func RxBurst(lportId int, packets []*Packet) int
- func SetChannels(name string, count uint) error
- func SetLinkDown(name string) error
- func SetLinkUp(name string) error
- func SwapMacAddr(pkt *Packet)
- func SwapMacAddrs(pkt []*Packet)
- func SwapUint16(x uint16) uint16
- func TxBurst(lportId int, packets []*Packet, sendAll bool) int
- func WritePktData(pkt *Packet, offset int, data []byte) int
- func WritePktDataList(pkts []*Packet, offset int, data []byte) error
- type ApplicationInfo
- type Config
- func (jcfg *Config) LPortByName(lportName string) *LPortInfo
- func (jcfg *Config) LPortNames() []string
- func (jcfg *Config) String() string
- func (jcfg *Config) ThreadByName(threadName string) *ThreadInfo
- func (jcfg *Config) ThreadNames() []string
- func (jcfg *Config) UmemByName(umemName string) *UmemInfo
- func (jcfg *Config) UmemNames() []string
- type DefaultInfo
- type EthernetHeader
- type IPv4Address
- type IPv4Hdr
- type IPv6Address
- type IPv6Hdr
- type LCoreInfo
- type LPort
- type LPortInfo
- type LPortStats
- type LocklessRing
- func (lr *LocklessRing) Count() uint
- func (lr *LocklessRing) DequeueN(values []uintptr, cnt int) int
- func (lr *LocklessRing) Destroy()
- func (lr *LocklessRing) Dump()
- func (lr *LocklessRing) ElemSize() uint
- func (lr *LocklessRing) Empty() bool
- func (lr *LocklessRing) EnqueueN(values []uintptr, cnt int) int
- func (lr *LocklessRing) Flags() []string
- func (lr *LocklessRing) FreeCount() uint
- func (lr *LocklessRing) Full() bool
- func (lr *LocklessRing) Name() string
- func (lr *LocklessRing) Pointer() unsafe.Pointer
- func (lr *LocklessRing) RawFlags() uint
- func (lr *LocklessRing) Size() uint
- type MACAddress
- type MsgChannel
- func (mc *MsgChannel) Close() error
- func (mc *MsgChannel) Info() *MsgChannelInfo
- func (mc *MsgChannel) Lookup(name string) *MsgChannel
- func (mc *MsgChannel) Name() string
- func (mc *MsgChannel) Pointers() (recv unsafe.Pointer, send unsafe.Pointer)
- func (mc *MsgChannel) Recv(objs []uintptr, timo uint64) int
- func (mc *MsgChannel) RecvFree() int
- func (mc *MsgChannel) Send(objs []uintptr) int
- func (mc *MsgChannel) SendFree() int
- func (mc *MsgChannel) Size() int
- type MsgChannelInfo
- type OptionInfo
- type Packet
- type System
- func (sys *System) Close() error
- func (sys *System) JsonCfg() *Config
- func (sys *System) LPortByName(name string) *LPort
- func (sys *System) LPortList() []*LPort
- func (sys *System) LPortMap() map[string]*LPort
- func (sys *System) LPortsByName(names []string) []*LPort
- func (sys *System) RegisterThread(name string) error
- func (sys *System) UmemData(umemName string) *UmemData
- func (sys *System) UmemMap() map[string]*UmemData
- func (sys *System) UnregisterThread(name string) error
- type TCPFlags
- type TCPHdr
- type ThreadInfo
- type UDPHdr
- type UmemData
- type UmemInfo
Constants ¶
const ( EtherAddrLen = 6 // Length of a MAC address IPv4AddrLen = 4 // Length of a IPv4 address IPv6AddrLen = 16 // Length of a IPv6 address )
Length of protocol addresses.
const ( EtherHdrLen = 14 // Length of a ethernet header IPv4HdrLen = 20 // Length of a IPv4 header without options IPv6HdrLen = 40 // Length of a IPv6 header without options )
These constants keep length of supported headers in bytes.
IPv6Len - minimum length of IPv6 header in bytes. It can be higher and it is not determined inside packet. Only default minimum size is used.
const ( IPProtoNumber = 0x04 // IPv4 protocol number TCPProtoNumber = 0x06 // TCP protocol number UDPProtoNumber = 0x11 // UDP protocol number )
Supported L4 types
const ( EtherTypeIPV4 = 0x0800 // IPv4 Protocol EtherTypeIPV6 = 0x86DD // IPv6 Protocol EtherTypeARP = 0x0806 // Arp Protocol EtherTypeRARP = 0x8035 // Reverse Arp Protocol EtherTypeVLAN = 0x8100 // IEEE 802.1Q VLAN tagging EtherTypeQINQ = 0x88A8 // IEEE 802.1ad QinQ tagging EtherTypePPPOEDiscovery = 0x8863 // PPPoE Discovery Stage EtherTypePPPOESession = 0x8864 // PPPoE Session Stage EtherTypeETAG = 0x893F // IEEE 802.1BR E-Tag EtherType1588 = 0x88F7 // RFC-1588 Timestamp Format EtherTypeSLOW = 0x8809 // Slow protocols (LACP and Marker) EtherTypeTEB = 0x6558 // Transparent Ethernet Bridging EtherTypeLLDP = 0x88CC // LLDP Protocol EtherTypeMPLS = 0x8847 // MPLS ethertype EtherTypeMPLSM = 0x8848 // MPLS multicast ethertype )
Supported EtherType for L2
const ( TCPFlagFin = 0x01 // TCP FIN flag TCPFlagSyn = 0x02 // TCP SYN flag TCPFlagRst = 0x04 // TCP RST flag TCPFlagPsh = 0x08 // TCP Push flag TCPFlagAck = 0x10 // TCP ACK flag TCPFlagUrg = 0x20 // TCP URG (Urgent) flag TCPFlagEcn = 0x40 // TCP ECN (ECN-Echo) flag TCPFlagCwr = 0x80 // TCP CWR (Congestion Window Reduced) flag )
Constants for values of TCP flags.
const ( LPortInhibitProgLoad = (1 << 0) // Inhibit Loading the BPF program & config of busy poll LPortForceWakeup = (1 << 1) // Force a wakeup, for CVL NICs LPortSkbMode = (1 << 2) // Force the SKB_MODE or copy mode LPortBusyPolling = (1 << 3) // Enable busy polling LPortUserManagedBuffers = (1 << 5) // Enable Buffer Manager outside of CNDP LPortUmemUnalignedBuffers = (1 << 6) // Enable unaligned frame UMEM support )
const ( UmemMaxRegions = 16 // Maximum number of regions allowed UnitMultiplier = 1024 // Multiplier number for each unit or count value )
const ( DefaultLCoreGroup = "default" // the lcore group used if a thread if not assigned to a group MainThreadName = "main" // the thread name used to register the main CNDP thread )
Variables ¶
var ( RingFlagSingleProducer = "SP_ENQ" // Single producer string RingFlagSingleConsumer = "SC_DEQ" // Single consumer string RingFlagExactSize = "EXACT_SIZE" // Exact size string RingFlagSingleProducerValue uint = C.RING_F_SP_ENQ // Single producer value RingFlagSingleConsumerValue uint = C.RING_F_SC_DEQ // Single consumer value RingFlagExactSizeValue uint = C.RING_F_EXACT_SZ // Exact Size value )
Functions ¶
func DisablePromiscuous ¶
DisablePromiscuous disables promiscuous for the given netdev device name
func EnablePromiscuous ¶
EnablePromiscuous enables promiscuous for the given netdev device name
func GetChannels ¶
GetChannels returns the number of channels enabled for the given netdev device name
func GetPromiscuous ¶
GetPromiscuous returns promiscuous status for the given netdev device name
func GetRingParams ¶
GetRingParams returns the rx and tx ring count for the given netdev device name
func IPv4Checksum ¶
IPv4Checksum will return the IPv4 checksum calculation The returned value could be zero in the case when verifying the checksum.
func IPv6Checksum ¶
IPv6Checksum will return the IPv6 checksum calculation The returned value could be zero in the case when verifying the checksum.
func InitCNE ¶
func InitCNE() error
InitCNE initializes the CNE system and returns error on failure.
The cne_init() is also called from OpenWithConfig(), which means this routine does not need to be called if OpenWith*() routines are used. It is OK to call this routine multiple times as it is protected to only initialize once.
func MakeByteSlice ¶
MakeByteSlice creates a byte slice of the given size using the array starting address
func MakeUint16Slice ¶
MakeUint16Slice creates a uint16 slice of the given size using the array starting address
func PktBufferAlloc ¶
PktBufferAlloc will allocate a set of pktmbuf structures or buffers Returns the number of packets allocated or -1 on error
func PktBufferFree ¶
func PktBufferFree(packets []*Packet)
PktBufferFree will free a set of pktmbuf structures or buffers
func PktType ¶
PktType will process the packet and return the pType value a bitwise value describing the packet type
func RxBurst ¶
RxBurst will attempt to receive packets from the given lportID value Returns -1 on error or number of packets received
func SetChannels ¶
SetChannels sets the number of channels for the given netdev device name
func SetLinkDown ¶
SetLinkDown sets the link down for the given netdev device name
func SwapMacAddr ¶
func SwapMacAddr(pkt *Packet)
SwapMacAddr will swap the MAC addresses of the packet The packet must have a valid EthernetHeader at the start or the packet data
func SwapMacAddrs ¶
func SwapMacAddrs(pkt []*Packet)
SwapMacAddrs will swap the MAC address of the set of packet buffers.
func SwapUint16 ¶
SwapUint16 swaps a uint16 in place for Big/Little Endian
func TxBurst ¶
TxBurst transmits packets to the given lportId value
If sendAll is true the routine will attempt to send all of the packets as the TX ring could get full. If sendAll flag is false the routine will not attempt to send all of the packet. Returns the number of packets sent or -1 on error
func WritePktData ¶
WritePktData writes a byte slice of the packet data into the packet buffer.
Types ¶
type ApplicationInfo ¶
type ApplicationInfo struct { Name string `json:"name"` // Name of the application Description string `json:"description"` // Description of the application }
ApplicationInfo is the JSON Application data structure
type Config ¶
type Config struct { ApplicationData *ApplicationInfo `json:"application"` // Application data DefaultData *DefaultInfo `json:"defaults"` // Default data UmemInfoMap map[string]*UmemInfo `json:"umems"` // UMEM data LPortInfoMap map[string]*LPortInfo `json:"lports"` // LPort data LCoreGroupData map[string]LCoreInfo `json:"lcore-groups"` // LCoreGroup data OptionData *OptionInfo `json:"options"` // Option data ThreadInfoMap map[string]*ThreadInfo `json:"threads"` // Thread data }
Config is the top level JSON configuration structure
func (*Config) LPortByName ¶
LPortByName returns the LPortInfo pointer for the given LPort name
func (*Config) LPortNames ¶
LPortName returns a array of strings giving the list of LPorts
func (*Config) ThreadByName ¶
func (jcfg *Config) ThreadByName(threadName string) *ThreadInfo
ThreadByName returns the ThreadInfo structure for the given thread name
func (*Config) ThreadNames ¶
ThreadNames returns the array of thread names
func (*Config) UmemByName ¶
UmemByName returns the UmemInfo structure for the UMEM name
type DefaultInfo ¶
type DefaultInfo struct { BufCnt uint `json:"bufcnt"` // Default number of buffers BufSize uint `json:"bufsz"` // Default size of the buffer RxDesc uint `json:"rxdesc"` // Default size of RX ring TxDesc uint `json:"txdesc"` // Default size of TX ring Cache uint `json:"cache"` // Default size of cache entries, can be 0 MemType string `json:"mtype"` // Default memory allocation type }
DefaultInfo is the JSON Default data structure
type EthernetHeader ¶
type EthernetHeader struct { DAddr MACAddress // Destination address SAddr MACAddress // Source address EtherType uint16 // Frame type }
EthernetHeader represents a Ethernet header
func GetEtherHdr ¶
func GetEtherHdr(pkt *Packet) *EthernetHeader
GetEtherHdr will return a pointer to the ether header or nil on error
func (*EthernetHeader) String ¶
func (ethHdr *EthernetHeader) String() string
type IPv4Address ¶
type IPv4Address uint32
IPv4Address represents a IPv4 address octets
func (*IPv4Address) String ¶
func (addr *IPv4Address) String() string
type IPv4Hdr ¶
type IPv4Hdr struct { VersionIhl uint8 // version and header length TypeOfService uint8 // type of service TotalLength uint16 // length of packet PacketID uint16 // packet ID FragmentOffset uint16 // fragmentation offset TimeToLive uint8 // time to live NextProtoID uint8 // protocol ID HdrChecksum uint16 // header checksum SrcAddr IPv4Address // source address DstAddr IPv4Address // destination address }
IPv4Hdr represents a IPv4 header
type IPv6Address ¶
type IPv6Address [IPv6AddrLen]uint8
IPv6Address represents a IPv6 address octets
func (IPv6Address) String ¶
func (addr IPv6Address) String() string
type IPv6Hdr ¶
type IPv6Hdr struct { VtcFlow uint32 // IP version, traffic class & flow label PayloadLen uint16 // IP packet length - includes sizeof(ip_header) Proto uint8 // Protocol, next header HopLimits uint8 // Hop limits SrcAddr IPv6Address // IP address of source host DstAddr IPv6Address // IP address of destination host(s) }
IPv6Hdr represents a IPv6 header
type LCoreInfo ¶
type LCoreInfo []int
LCoreInfo is the list of lcores for a JSON LCoreGroup
func (LCoreInfo) MarshalJSON ¶
MarshalJSON implements the json.Marshaler interface. The output is sorted by core number with duplicates removed. Contiguous ranges will be unmashalled as a string of the form "x-y".
func (*LCoreInfo) UnmarshalJSON ¶
UnmarshalJSON implements the json.Unmarshaler interface. The marshalled LCoreInfo is sorted by core number with duplicates removed.
type LPort ¶
type LPort struct {
// contains filtered or unexported fields
}
LPort is the logical port data structure to hold information for accessing the logical port or netdev/queue ID.
func (*LPort) GetLPortChannels ¶
GetLPortChannels using an LPort structure return the number of channels of a netdev device.
func (*LPort) LPortStats ¶
func (p *LPort) LPortStats() (*LPortStats, error)
LPortStats returns the lport statistics structure for the given LPort
func (*LPort) NetdevName ¶
NetdevName returns the name of the given LPort
func (*LPort) ResetLPortStats ¶
ResetLPortStats resets the LPort statistics
type LPortInfo ¶
type LPortInfo struct { Pmd string `json:"pmd"` // PMD name Qid uint16 `json:"qid"` // QID number Umem string `json:"umem"` // UMEM name string for this LPort to use Region int `json:"region"` // The UMEM region index value Description string `json:"description"` // Description of the LPort BusyPolling bool `json:"busy_polling"` // "busy_poll" enable busy polling if true BusyTimeout uint16 `json:"busy_timeout"` // Busy timeout value in seconds BusyBudget uint16 `json:"busy_budget"` // Busy budget value InhibitProgLoad bool `json:"inhibit_prog_load"` // Inhibit eBPD program load flag ForceWakeup bool `json:"force_wakeup"` // Force wakeup calls for AF_XDP SkbMode bool `json:"skb_mode"` // Force SKB_MODE or copy mode flag // contains filtered or unexported fields }
LPortInfo is the JSON LPort information data structure(s)
func (*LPortInfo) LPortFlags ¶
LPortFlags returns the LPort configuration flags
type LPortStats ¶
type LPortStats struct { InPackets uint64 // Number of input packets InBytes uint64 // Number of input bytes InErrors uint64 // Number of input errors InMissed uint64 // Number of missed input packets RxInvalid uint64 // Number of invalid Rx packets OutPackets uint64 // Number of output packets OutBytes uint64 // Number of output bytes OutErrors uint64 // Number of output errors OutDropped uint64 // Number of dropped output packets TxInvalid uint64 // Number of invalid Tx packets InPacketRate uint64 // Packet rate for input OutPacketRate uint64 // Packet rate for output }
LPortStats is the Go structure for LPort statistics
type LocklessRing ¶
type LocklessRing struct {
// contains filtered or unexported fields
}
LocklessRing structure contains internal information for a lockless ring.
func LRingCreateElem ¶
func LRingCreateElem(name string, elementSz, count uint, strFlags []string) (*LocklessRing, error)
LRingCreateElem creates the lockless ring given the specified arguments and element size.
The name is used to give the ring a name. The elementSz is the element size of each element in the ring. The count is used to set the max number of elements in the ring. strFlags are used in creating the lockless ring.
Returns the internal lockless ring object or error value is set
func NewLRing ¶
func NewLRing(name string, count uint, strFlags []string) (*LocklessRing, error)
NewLRing create a lockless ring using default element size of 8 bytes.
The name is used to give the ring a name. The count is used to set the max number of elements in the ring. strFlags are used in creating the lockless ring.
Returns the internal lockless ring object or error value is set
func (*LocklessRing) Count ¶
func (lr *LocklessRing) Count() uint
Count returns the number of elements currently in the ring
func (*LocklessRing) DequeueN ¶
func (lr *LocklessRing) DequeueN(values []uintptr, cnt int) int
DequeueN dequeue a number of elements from the ring defined by the specified count
func (*LocklessRing) Destroy ¶
func (lr *LocklessRing) Destroy()
Destroy a lockless ring object given the valid LocklessRing structure pointer.
func (*LocklessRing) Dump ¶
func (lr *LocklessRing) Dump()
Dump the lockless ring information to the console.
func (*LocklessRing) ElemSize ¶
func (lr *LocklessRing) ElemSize() uint
ElemSize returns the size of each element in the ring.
func (*LocklessRing) Empty ¶
func (lr *LocklessRing) Empty() bool
Empty returns true if the ring is empty.
func (*LocklessRing) EnqueueN ¶
func (lr *LocklessRing) EnqueueN(values []uintptr, cnt int) int
EnqueueN enqueues N number of elements into a lockless ring.
func (*LocklessRing) Flags ¶
func (lr *LocklessRing) Flags() []string
Flags returns the flags of the lockless ring.
func (*LocklessRing) FreeCount ¶
func (lr *LocklessRing) FreeCount() uint
FreeCount returns the number of elements currently free in the ring
func (*LocklessRing) Full ¶
func (lr *LocklessRing) Full() bool
Full returns true if the ring is full.
func (*LocklessRing) Name ¶
func (lr *LocklessRing) Name() string
Name returns the name of the lockless ring.
func (*LocklessRing) Pointer ¶
func (lr *LocklessRing) Pointer() unsafe.Pointer
Pointer returns the pointer to the C ring struct.
func (*LocklessRing) RawFlags ¶
func (lr *LocklessRing) RawFlags() uint
RawFlags returns the flags of the lockless ring.
func (*LocklessRing) Size ¶
func (lr *LocklessRing) Size() uint
Size returns the size of the lockless ring.
type MACAddress ¶
type MACAddress [EtherAddrLen]uint8
MACAddress represents a MAC address octets
func (*MACAddress) String ¶
func (mac *MACAddress) String() string
type MsgChannel ¶
type MsgChannel struct {
// contains filtered or unexported fields
}
MsgChannel is the structure to hold information about the MsgChan
func NewMsgChannel ¶
func NewMsgChannel(name string, sz uint) (*MsgChannel, error)
NewMsgChannel creates a new MsgChannel object with the given name and size
func (*MsgChannel) Close ¶
func (mc *MsgChannel) Close() error
Close the MsgChannel and release the resources
func (*MsgChannel) Info ¶
func (mc *MsgChannel) Info() *MsgChannelInfo
Info returns the msgchan information structure
func (*MsgChannel) Lookup ¶
func (mc *MsgChannel) Lookup(name string) *MsgChannel
Lookup a msgchan by name and return MsgChannel pointer
func (*MsgChannel) Name ¶
func (mc *MsgChannel) Name() string
Name for the message channel Returns the message channel string or empty if error
func (*MsgChannel) Pointers ¶
func (mc *MsgChannel) Pointers() (recv unsafe.Pointer, send unsafe.Pointer)
Pointers returns the recv and send ring pointers or nil on error
func (*MsgChannel) Recv ¶
func (mc *MsgChannel) Recv(objs []uintptr, timo uint64) int
Recv objs from the msgChan
func (*MsgChannel) RecvFree ¶
func (mc *MsgChannel) RecvFree() int
RecvFree is the number of free entries in the receive ring Return number of free entries or -1 on error
func (*MsgChannel) Send ¶
func (mc *MsgChannel) Send(objs []uintptr) int
Send object values on the msgChan Returns the number of objects sent
func (*MsgChannel) SendFree ¶
func (mc *MsgChannel) SendFree() int
SendFree is the number of free entries in the send ring Return number of free entries or -1 on error
func (*MsgChannel) Size ¶
func (mc *MsgChannel) Size() int
Size of the message channel structure and rings
type MsgChannelInfo ¶
type MsgChannelInfo struct { RecvRing unsafe.Pointer // RecvRing pointer SendRing unsafe.Pointer // SendRing pointer ChildCount int // Number of children attached to this msgChan SendCalls uint64 // Number of calls to send routine SendCnt uint64 // Number of items sent in send routine RecvCalls uint64 // Number of calls to recv routine RecvCnt uint64 // Number of items received in recv routine RecvTimeouts uint64 // Number of timeouts the receive routine had }
MsgChannelInfo is the structure to hold information about a MsgChannel
type OptionInfo ¶
type OptionInfo struct { PktApi string `json:"pkt_api"` // Define the packet device API pktdev or xskdev NoMetrics bool `json:"no-metrics"` // Disable Metrics collecting NoRestapi bool `json:"no-restapi"` // Disable RestAPI support Cli bool `json:"cli"` // Enable CLI mode or command line mode Mode string `json:"mode"` // Type of mode to use rx-only, tx-only, loopback, ... UdsPath string `json:"uds_path"` // UDS path string }
OptionInfo is the JSON Option information structure
type System ¶
type System struct {
// contains filtered or unexported fields
}
System structure to hold internal information for binding layer to CNDP
func OpenWithConfig ¶
OpenWithConfig by passing in a initialized cne.Config structure
func OpenWithFile ¶
OpenWithFile by passing in a filename or path to a JSON-C or JSON configuration
func OpenWithString ¶
OpenWithString by passing in a string containing JSON-C or JSON text
func (*System) LPortByName ¶
LPortByName returns the LPort for the given name
func (*System) LPortsByName ¶
LPortsByName return a list of LPort structure pointers
func (*System) RegisterThread ¶
RegisterThread locks a thread and registers it to CNDP to get the CNE UID value
func (*System) UnregisterThread ¶
UnregisterThread unregister the thread from CNDP
type TCPHdr ¶
type TCPHdr struct { SrcPort uint16 // TCP source port DstPort uint16 // TCP destination port SentSeq uint32 // TX data sequence number RecvAck uint32 // RX data acknowledgement sequence number DataOff uint8 // Data offset TCPFlags TCPFlags // TCP flags RxWin uint16 // RX flow control window Cksum uint16 // TCP checksum TCPUrp uint16 // TCP urgent pointer, if any }
TCPHdr represents the TCP header
type ThreadInfo ¶
type ThreadInfo struct { Group string `json:"group"` // LCoreGroup string name LPorts []string `json:"lports"` // List of LPorts for this thread to manage Description string `json:"description"` // Description of the thread }
ThreadInfo is the JSON Thread structure(s)
type UDPHdr ¶
type UDPHdr struct { SrcPort uint16 // UDP source port DstPort uint16 // UDP destination port DgramLen uint16 // UDP datagram length DgramCksum uint16 // UDP datagram checksum }
UDPHdr represents the UDP header
type UmemData ¶
type UmemData struct {
// contains filtered or unexported fields
}
UmemData is the primary structure for UMEM information and data
type UmemInfo ¶
type UmemInfo struct { BufCnt uint `json:"bufcnt"` // Number of buffers in 1024 increments BufSize uint `json:"bufsz"` // Size of each buffer in 1024 increments MemType string `json:"mtype"` // Memory type for buffer allocation Regions []uint `json:"regions"` // Region array for size of each region in 1024 increments RxDesc uint `json:"rxdesc"` // Rx Descriptor ring size in 1024 increments TxDesc uint `json:"txdesc"` // Tx Descriptor ring size in 1024 increments Description string `json:"description"` // UMEM description }
UmemInfo is the JSON UMEM data structure(s)