| NVIDIA DOCA SDK | Data Center on a Chip Framework Documentation |
#include <rte_ethdev.h>#include <rte_ether.h>#include <rte_arp.h>#include <rte_icmp.h>#include <netinet/icmp6.h>#include <doca_log.h>#include <psp_gw_config.h>#include <psp_gw_flows.h>#include <psp_gw_pkt_rss.h>#include <psp_gw_svc_impl.h>
Go to the source code of this file.
Macros | |
| #define | MAX_RX_BURST_SIZE 256 |
Functions | |
| DOCA_LOG_REGISTER (PSP_RSS) | |
| static bool | is_ns_request (struct rte_ether_hdr *eth_hdr, uint16_t ether_type) |
| determine whether a given packet or request corresponds to a "Neighbor Solicitation" More... | |
| static void | handle_packet (struct lcore_params *params, uint16_t port_id, uint16_t queue_id, rte_ether_addr *port_src_mac, struct rte_mbuf *packet) |
| High-level Rx Queue packet handler routine Optionally logs the packet to the console. Passes the packet to the PSP Service so it can decide whether to negotiate a new tunnel. More... | |
| int | lcore_pkt_proc_func (void *lcore_args) |
| The entry point for each L-Core's main processing loop. Each L-Core polls a different Rx queue on the Host PF(s). If the packet indicates the need for a new tunnel to be established, it will be passed to the psp_svc object. Note multiple such packets may be received during the creation of the tunnel; in any case, they will be resubmitted to the encryption pipeline once the new flow has been created. More... | |
| bool | reinject_packet (struct rte_mbuf *packet, uint16_t port_id) |
| Used by the psp_svc to re-inject a packet via the Host PF Tx queue after a new tunnel has been established. More... | |
| uint16_t | handle_arp (struct rte_mempool *mpool, uint16_t port_id, uint16_t queue_id, rte_ether_addr *port_src_mac, const struct rte_mbuf *request_pkt, uint32_t arp_response_meta_flag) |
| Used to reply to an ARP request. More... | |
| uint16_t | handle_neighbor_solicitation (struct rte_mempool *mpool, uint16_t port_id, uint16_t queue_id, rte_ether_addr *port_src_mac, const struct rte_mbuf *request_pkt, uint32_t na_response_meta_flag) |
| Used to reply to a Neighbor Solicitation packet. More... | |
Variables | |
| static uint16_t | max_tx_retries = 10 |
| #define MAX_RX_BURST_SIZE 256 |
Definition at line 41 of file psp_gw_pkt_rss.cpp.
| DOCA_LOG_REGISTER | ( | PSP_RSS | ) |
| uint16_t handle_arp | ( | struct rte_mempool * | mpool, |
| uint16_t | port_id, | ||
| uint16_t | queue_id, | ||
| rte_ether_addr * | port_src_mac, | ||
| const struct rte_mbuf * | request_pkt, | ||
| uint32_t | arp_response_meta_flag | ||
| ) |
Used to reply to an ARP request.
@mpool [in]: the mempool to allocate the response packet from @port_id [in]: the port on which to send the ARP response @queue_id [in]: the queue on which to send the ARP response @port_src_mac [in]: the source mac address of the port @request_pkt [in]: the ARP request packet @arp_response_meta_flag [in]: the metadata flag to set on the ARP response
Definition at line 199 of file psp_gw_pkt_rss.cpp.
| uint16_t handle_neighbor_solicitation | ( | struct rte_mempool * | mpool, |
| uint16_t | port_id, | ||
| uint16_t | queue_id, | ||
| rte_ether_addr * | port_src_mac, | ||
| const struct rte_mbuf * | request_pkt, | ||
| uint32_t | na_response_meta_flag | ||
| ) |
Used to reply to a Neighbor Solicitation packet.
@mpool [in]: the mempool to allocate the response packet from @port_id [in]: the port on which to send the Neighbor Solicitation response @queue_id [in]: the queue on which to send the Neighbor Solicitation response @port_src_mac [in]: the source mac address of the port @request_pkt [in]: the Neighbor Solicitation packet @na_response_meta_flag [in]: the metadata flag to set on the Neighbor Solicitation response
Definition at line 261 of file psp_gw_pkt_rss.cpp.
|
static |
High-level Rx Queue packet handler routine Optionally logs the packet to the console. Passes the packet to the PSP Service so it can decide whether to negotiate a new tunnel.
@params [in]: the parameters to the lcore routines @port_id [in]: the port_id from which the packet was received @queue_id [in]: the queue index from which the packet was received @port_src_mac [in]: the source mac address of the port @packet [in]: the received packet buffer
Definition at line 84 of file psp_gw_pkt_rss.cpp.
|
static |
determine whether a given packet or request corresponds to a "Neighbor Solicitation"
@params [in]: the parameters to the lcore routines @eth_hdr [in]: a pointer to the ethernet header of the pakcet @ether_type [in]: the packet ethernet type
Definition at line 52 of file psp_gw_pkt_rss.cpp.
| int lcore_pkt_proc_func | ( | void * | lcore_args | ) |
The entry point for each L-Core's main processing loop. Each L-Core polls a different Rx queue on the Host PF(s). If the packet indicates the need for a new tunnel to be established, it will be passed to the psp_svc object. Note multiple such packets may be received during the creation of the tunnel; in any case, they will be resubmitted to the encryption pipeline once the new flow has been created.
@lcore_args [in]: a pointer to an lcore_params struct
Definition at line 134 of file psp_gw_pkt_rss.cpp.
| bool reinject_packet | ( | struct rte_mbuf * | packet, |
| uint16_t | port_id | ||
| ) |
Used by the psp_svc to re-inject a packet via the Host PF Tx queue after a new tunnel has been established.
@packet [in]: the packet to submit into the egress pipeline @port_id [in]: the port on which to send the packet, usually the host PF
Definition at line 182 of file psp_gw_pkt_rss.cpp.
|
static |
Definition at line 43 of file psp_gw_pkt_rss.cpp.