aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/devices/af_packet/af_packet.h
diff options
context:
space:
mode:
authorMohsin Kazmi <sykazmi@cisco.com>2021-10-08 15:10:49 +0000
committerBeno�t Ganne <bganne@cisco.com>2021-10-22 12:37:36 +0000
commitcae84fa96856406c93c37e0a38f67d4c6ee7f48a (patch)
tree617e05be28146aff824d47ed71a28ab72bcf8cde /src/vnet/devices/af_packet/af_packet.h
parent0ad060851b4989a1cd300ad711e8498435f65f9a (diff)
devices: add support for l3 af_packet interface
Type: improvement Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com> Change-Id: Ia6b9d4ac55be2216887bfdb99be4021f6a96f166
Diffstat (limited to 'src/vnet/devices/af_packet/af_packet.h')
-rw-r--r--src/vnet/devices/af_packet/af_packet.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/vnet/devices/af_packet/af_packet.h b/src/vnet/devices/af_packet/af_packet.h
index 3163aa0323e..652e173fd2a 100644
--- a/src/vnet/devices/af_packet/af_packet.h
+++ b/src/vnet/devices/af_packet/af_packet.h
@@ -18,9 +18,14 @@
*/
#include <vppinfra/lock.h>
-
#include <vlib/log.h>
+typedef enum
+{
+ AF_PACKET_IF_MODE_ETHERNET = 1,
+ AF_PACKET_IF_MODE_IP = 2
+} af_packet_if_mode_t;
+
typedef struct
{
u32 sw_if_index;
@@ -49,6 +54,7 @@ typedef struct
u8 is_admin_up;
u32 queue_index;
u32 host_mtu;
+ af_packet_if_mode_t mode;
} af_packet_if_t;
typedef struct
@@ -77,6 +83,7 @@ typedef struct
u32 tx_frame_size;
u32 rx_frames_per_block;
u32 tx_frames_per_block;
+ af_packet_if_mode_t mode;
/* return */
u32 sw_if_index;