18 #ifndef __ARP_PACKET_H__ 19 #define __ARP_PACKET_H__ 39 u8 *rewrite0, rewrite0_len;
49 rewrite0_len =
vec_len (rewrite0);
62 arp0->
opcode = clib_host_to_net_u16 (ETHERNET_ARP_OPCODE_reply);
static vnet_hw_interface_t * vnet_get_sup_hw_interface(vnet_main_t *vnm, u32 sw_if_index)
#define clib_memcpy_fast(a, b, c)
#define static_always_inline
static_always_inline void mac_address_from_bytes(mac_address_t *mac, const u8 *bytes)
static void * vlib_buffer_get_current(vlib_buffer_t *b)
Get pointer to current data to process.
static_always_inline u32 arp_mk_reply(vnet_main_t *vnm, vlib_buffer_t *p0, u32 sw_if_index0, const ip4_address_t *if_addr0, ethernet_arp_header_t *arp0, ethernet_header_t *eth_rx)
#define vec_free(V)
Free vector's memory (no header).
static void vlib_buffer_advance(vlib_buffer_t *b, word l)
Advance current data pointer by the supplied (signed!) amount.
#define clib_mem_unaligned(pointer, type)
#define vec_len(v)
Number of elements in vector (rvalue-only, NULL tolerant)
VLIB buffer representation.
u8 * ethernet_build_rewrite(vnet_main_t *vnm, u32 sw_if_index, vnet_link_t link_type, const void *dst_address)
build a rewrite string to use for sending packets of type 'link_type' to 'dst_address' ...