blob: 23aea5b6e3aa629e789d3211bab7f49a6241d3db (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
/* Copyright (c) 2015, Linaro Limited
* All rights reserved.
*
* SPDX-License-Identifier: BSD-3-Clause
*/
#ifndef ODP_PACKET_NETMAP_H
#define ODP_PACKET_NETMAP_H
#include <odp/pool.h>
#include <linux/if_ether.h>
/** Packet socket using netmap mmaped rings for both Rx and Tx */
typedef struct {
odp_pool_t pool; /**< pool to alloc packets from */
size_t max_frame_len; /**< buf_size - sizeof(pkt_hdr) */
struct nm_desc *desc; /**< netmap meta-data for the device */
uint32_t if_flags; /**< interface flags */
int sockfd; /**< control socket */
unsigned char if_mac[ETH_ALEN]; /**< eth mac address */
} pkt_netmap_t;
#endif
|