DPDK:upgrade to 18.11.2 (LTS)

dev
jfb8856606 2019-06-26 18:17:41 +08:00
parent d03b194015
commit 1646932aaf
557 changed files with 8130 additions and 83025 deletions

2
.gitignore vendored
View File

@ -23,3 +23,5 @@ lib/vnode_if_newproto.h
lib/vnode_if_typedef.h
app/nginx-1.11.10/objs/
app/nginx-1.11.10/Makefile
dpdk/.ci/
dpdk/.travis.yml

View File

@ -20,7 +20,7 @@ vlan_strip=1
# sleep when no pkts incomming
# unit: microseconds
idle_sleep=0
idle_sleep=100
# enabled port list
#
@ -36,49 +36,30 @@ idle_sleep=0
# 1-3,4,7 ports 1,2,3,4,7 are enabled
port_list=0
# Number of vdev.
nb_vdev=0
# Port config section
# Correspond to dpdk.port_list's index: port0, port1...
[port0]
addr=192.168.1.2
netmask=255.255.225.0
broadcast=192.168.1.255
gateway=192.168.1.1
addr=172.16.0.12
netmask=255.255.240.0
broadcast=172.16.15.255
gateway=172.16.0.1
# lcore list used to handle this port
# the format is same as port_list
# lcore_list= 0
# Packet capture path, this will hurt performance
#pcap=./a.pcap
# Vdev config section
# orrespond to dpdk.nb_vdev's index: vdev0, vdev1...
# iface : Shouldn't set always.
# path : The vuser device path in container. Required.
# queues : The max queues of vuser. Optional, default 1, greater or equal to the number of processes.
# queue_size : Queue size.Optional, default 256.
# mac : The mac address of vuser. Optional, default random, if vhost use phy NIC, it should be set to the phy NIC's mac.
# cq : Optional, if queues = 1, default 0; if queues > 1 default 1.
#[vdev0]
##iface=/usr/local/var/run/openvswitch/vhost-user0
#path=/var/run/openvswitch/vhost-user0
#queues=1
#queue_size=256
#mac=00:00:00:00:00:01
#cq=0
pcap=./a.pcap
# Kni config: if enabled and method=reject,
# all packets that do not belong to the following tcp_port and udp_port
# will transmit to kernel; if method=accept, all packets that belong to
# the following tcp_port and udp_port will transmit to kernel.
#[kni]
#enable=1
#method=reject
[kni]
enable=1
method=reject
# The format is same as port_list
#tcp_port=80,443
tcp_port=80,443
#udp_port=53
# FreeBSD network performance tuning configurations.

1
dpdk/.gitignore vendored
View File

@ -3,6 +3,7 @@ doc/guides/cryptodevs/overview_feature_table.txt
doc/guides/cryptodevs/overview_cipher_table.txt
doc/guides/cryptodevs/overview_auth_table.txt
doc/guides/cryptodevs/overview_aead_table.txt
doc/guides/cryptodevs/overview_asym_table.txt
doc/guides/compressdevs/overview_feature_table.txt
cscope.out.po
cscope.out.in

View File

@ -120,6 +120,12 @@ F: config/rte_config.h
F: buildtools/gen-pmdinfo-cfile.sh
F: buildtools/symlink-drivers-solibs.sh
Public CI
M: Aaron Conole <aconole@redhat.com>
M: Michael Santana <msantana@redhat.com>
F: .travis.yml
F: .ci/
ABI versioning
M: Neil Horman <nhorman@tuxdriver.com>
F: lib/librte_compat/
@ -234,7 +240,7 @@ F: drivers/net/i40e/i40e_rxtx_vec_neon.c
F: drivers/net/virtio/virtio_rxtx_simple_neon.c
IBM POWER (alpha)
M: Chao Zhu <chaozhu@linux.vnet.ibm.com>
M: David Christensen <drc@linux.vnet.ibm.com>
F: lib/librte_eal/common/arch/ppc_64/
F: lib/librte_eal/common/include/arch/ppc_64/
F: drivers/net/i40e/i40e_rxtx_vec_altivec.c

View File

@ -494,6 +494,7 @@ cleanup_pdump_resources(void)
{
int i;
struct pdump_tuples *pt;
char name[RTE_ETH_NAME_MAX_LEN];
/* disable pdump and free the pdump_tuple resources */
for (i = 0; i < num_tuples; i++) {
@ -510,6 +511,21 @@ cleanup_pdump_resources(void)
free_ring_data(pt->rx_ring, pt->rx_vdev_id, &pt->stats);
if (pt->dir & RTE_PDUMP_FLAG_TX)
free_ring_data(pt->tx_ring, pt->tx_vdev_id, &pt->stats);
/* Remove the vdev(s) created */
if (pt->dir & RTE_PDUMP_FLAG_RX) {
rte_eth_dev_get_name_by_port(pt->rx_vdev_id, name);
rte_eal_hotplug_remove("vdev", name);
}
if (pt->single_pdump_dev)
continue;
if (pt->dir & RTE_PDUMP_FLAG_TX) {
rte_eth_dev_get_name_by_port(pt->tx_vdev_id, name);
rte_eal_hotplug_remove("vdev", name);
}
}
cleanup_rings();
}

0
dpdk/app/test-bbdev/test-bbdev.py Normal file → Executable file
View File

View File

@ -14,6 +14,8 @@
#include <rte_bbdev.h>
#include <rte_bbdev_op.h>
#include <rte_bbdev_pmd.h>
#include<string.h>
#include <rte_string_fns.h>
#include "main.h"
@ -788,14 +790,14 @@ test_bbdev_driver_init(void)
/* Initialize the maximum amount of devices */
do {
sprintf(name_tmp, "%s%i", "name_", num_devs);
snprintf(name_tmp, sizeof(name_tmp), "%s%i", "name_", num_devs);
dev2 = rte_bbdev_allocate(name_tmp);
TEST_ASSERT(dev2 != NULL,
"Failed to initialize bbdev driver");
++num_devs;
} while (num_devs < (RTE_BBDEV_MAX_DEVS - 1));
sprintf(name_tmp, "%s%i", "name_", num_devs);
snprintf(name_tmp, sizeof(name_tmp), "%s%i", "name_", num_devs);
dev2 = rte_bbdev_allocate(name_tmp);
TEST_ASSERT(dev2 == NULL, "Failed to initialize bbdev driver number %d "
"more drivers than RTE_BBDEV_MAX_DEVS: %d ", num_devs,
@ -804,7 +806,7 @@ test_bbdev_driver_init(void)
num_devs--;
while (num_devs >= num_devs_tmp) {
sprintf(name_tmp, "%s%i", "name_", num_devs);
snprintf(name_tmp, sizeof(name_tmp), "%s%i", "name_", num_devs);
dev2 = rte_bbdev_get_named_dev(name_tmp);
TEST_ASSERT_SUCCESS(rte_bbdev_release(dev2),
"Failed to uninitialize bbdev driver %s ",
@ -825,7 +827,7 @@ test_bbdev_driver_init(void)
TEST_ASSERT_FAIL(rte_bbdev_release(NULL),
"Failed to uninitialize bbdev driver with NULL bbdev");
sprintf(name_tmp, "%s", "invalid_name");
strlcpy(name_tmp, "invalid_name", sizeof(name_tmp));
dev2 = rte_bbdev_get_named_dev(name_tmp);
TEST_ASSERT_FAIL(rte_bbdev_release(dev2),
"Failed to uninitialize bbdev driver with invalid name");

View File

@ -1953,7 +1953,10 @@ offload_latency_test_dec(struct rte_mempool *mempool, struct test_buffers *bufs,
if (unlikely(num_to_process - dequeued < burst_sz))
burst_sz = num_to_process - dequeued;
rte_bbdev_dec_op_alloc_bulk(mempool, ops_enq, burst_sz);
ret = rte_bbdev_dec_op_alloc_bulk(mempool, ops_enq, burst_sz);
TEST_ASSERT_SUCCESS(ret, "Allocation failed for %d ops",
burst_sz);
if (test_vector.op_type != RTE_BBDEV_OP_NONE)
copy_reference_dec_op(ops_enq, burst_sz, dequeued,
bufs->inputs,
@ -2035,7 +2038,10 @@ offload_latency_test_enc(struct rte_mempool *mempool, struct test_buffers *bufs,
if (unlikely(num_to_process - dequeued < burst_sz))
burst_sz = num_to_process - dequeued;
rte_bbdev_enc_op_alloc_bulk(mempool, ops_enq, burst_sz);
ret = rte_bbdev_enc_op_alloc_bulk(mempool, ops_enq, burst_sz);
TEST_ASSERT_SUCCESS(ret, "Allocation failed for %d ops",
burst_sz);
if (test_vector.op_type != RTE_BBDEV_OP_NONE)
copy_reference_enc_op(ops_enq, burst_sz, dequeued,
bufs->inputs,

View File

@ -129,6 +129,11 @@ cperf_initialize_cryptodev(struct cperf_options *opts, uint8_t *enabled_cdevs,
struct rte_cryptodev_info cdev_info;
uint8_t socket_id = rte_cryptodev_socket_id(cdev_id);
/* range check the socket_id - negative values become big
* positive ones due to use of unsigned value
*/
if (socket_id >= RTE_MAX_NUMA_NODES)
socket_id = 0;
rte_cryptodev_info_get(cdev_id, &cdev_info);
if (opts->nb_qps > cdev_info.max_nb_queue_pairs) {

View File

@ -327,7 +327,8 @@ perf_launch_lcores(struct evt_test *test, struct evt_options *opt,
}
if (new_cycles - dead_lock_cycles > dead_lock_sample &&
opt->prod_type == EVT_PROD_TYPE_SYNT) {
(opt->prod_type == EVT_PROD_TYPE_SYNT ||
opt->prod_type == EVT_PROD_TYPE_EVENT_TIMER_ADPTR)) {
remaining = t->outstand_pkts - processed_pkts(t);
if (dead_lock_remaining == remaining) {
rte_event_dev_dump(opt->dev_id, stdout);

View File

@ -94,14 +94,15 @@ static void cmd_help_brief_parsed(__attribute__((unused)) void *parsed_result,
cl,
"\n"
"Help is available for the following sections:\n\n"
" help control : Start and stop forwarding.\n"
" help display : Displaying port, stats and config "
" help control : Start and stop forwarding.\n"
" help display : Displaying port, stats and config "
"information.\n"
" help config : Configuration information.\n"
" help ports : Configuring ports.\n"
" help registers : Reading and setting port registers.\n"
" help filters : Filters configuration help.\n"
" help all : All of the above sections.\n\n"
" help config : Configuration information.\n"
" help ports : Configuring ports.\n"
" help registers : Reading and setting port registers.\n"
" help filters : Filters configuration help.\n"
" help traffic_management : Traffic Management commmands.\n"
" help all : All of the above sections.\n\n"
);
}
@ -210,21 +211,32 @@ static void cmd_help_long_parsed(void *parsed_result,
"show port meter stats (port_id) (meter_id) (clear)\n"
" Get meter stats on a port\n\n"
"show port tm cap (port_id)\n"
" Display the port TM capability.\n\n"
"show port tm level cap (port_id) (level_id)\n"
" Display the port TM hierarchical level capability.\n\n"
"show fwd stats all\n"
" Display statistics for all fwd engines.\n\n"
"show port tm node cap (port_id) (node_id)\n"
" Display the port TM node capability.\n\n"
"clear fwd stats all\n"
" Clear statistics for all fwd engines.\n\n"
"show port tm node type (port_id) (node_id)\n"
" Display the port TM node type.\n\n"
"show port (port_id) rx_offload capabilities\n"
" List all per queue and per port Rx offloading"
" capabilities of a port\n\n"
"show port tm node stats (port_id) (node_id) (clear)\n"
" Display the port TM node stats.\n\n"
"show port (port_id) rx_offload configuration\n"
" List port level and all queue level"
" Rx offloading configuration\n\n"
"show port (port_id) tx_offload capabilities\n"
" List all per queue and per port"
" Tx offloading capabilities of a port\n\n"
"show port (port_id) tx_offload configuration\n"
" List port level and all queue level"
" Tx offloading configuration\n\n"
"show port (port_id) tx_metadata\n"
" Show Tx metadata value set"
" for a specific port\n\n"
);
}
@ -642,11 +654,6 @@ static void cmd_help_long_parsed(void *parsed_result,
"E-tag set filter del e-tag-id (value) port (port_id)\n"
" Delete an E-tag forwarding filter on a port\n\n"
#if defined RTE_LIBRTE_PMD_SOFTNIC && defined RTE_LIBRTE_SCHED
"set port tm hierarchy default (port_id)\n"
" Set default traffic Management hierarchy on a port\n\n"
#endif
"ddp add (port_id) (profile_path[,backup_profile_path])\n"
" Load a profile package on a port\n\n"
@ -727,62 +734,6 @@ static void cmd_help_long_parsed(void *parsed_result,
"show port (port_id) queue-region\n"
" show all queue region related configuration info\n\n"
"add port tm node shaper profile (port_id) (shaper_profile_id)"
" (cmit_tb_rate) (cmit_tb_size) (peak_tb_rate) (peak_tb_size)"
" (packet_length_adjust)\n"
" Add port tm node private shaper profile.\n\n"
"del port tm node shaper profile (port_id) (shaper_profile_id)\n"
" Delete port tm node private shaper profile.\n\n"
"add port tm node shared shaper (port_id) (shared_shaper_id)"
" (shaper_profile_id)\n"
" Add/update port tm node shared shaper.\n\n"
"del port tm node shared shaper (port_id) (shared_shaper_id)\n"
" Delete port tm node shared shaper.\n\n"
"set port tm node shaper profile (port_id) (node_id)"
" (shaper_profile_id)\n"
" Set port tm node shaper profile.\n\n"
"add port tm node wred profile (port_id) (wred_profile_id)"
" (color_g) (min_th_g) (max_th_g) (maxp_inv_g) (wq_log2_g)"
" (color_y) (min_th_y) (max_th_y) (maxp_inv_y) (wq_log2_y)"
" (color_r) (min_th_r) (max_th_r) (maxp_inv_r) (wq_log2_r)\n"
" Add port tm node wred profile.\n\n"
"del port tm node wred profile (port_id) (wred_profile_id)\n"
" Delete port tm node wred profile.\n\n"
"add port tm nonleaf node (port_id) (node_id) (parent_node_id)"
" (priority) (weight) (level_id) (shaper_profile_id)"
" (n_sp_priorities) (stats_mask) (n_shared_shapers)"
" [(shared_shaper_id_0) (shared_shaper_id_1)...]\n"
" Add port tm nonleaf node.\n\n"
"add port tm leaf node (port_id) (node_id) (parent_node_id)"
" (priority) (weight) (level_id) (shaper_profile_id)"
" (cman_mode) (wred_profile_id) (stats_mask) (n_shared_shapers)"
" [(shared_shaper_id_0) (shared_shaper_id_1)...]\n"
" Add port tm leaf node.\n\n"
"del port tm node (port_id) (node_id)\n"
" Delete port tm node.\n\n"
"set port tm node parent (port_id) (node_id) (parent_node_id)"
" (priority) (weight)\n"
" Set port tm node parent.\n\n"
"suspend port tm node (port_id) (node_id)"
" Suspend tm node.\n\n"
"resume port tm node (port_id) (node_id)"
" Resume tm node.\n\n"
"port tm hierarchy commit (port_id) (clean_on_fail)\n"
" Commit tm hierarchy.\n\n"
"vxlan ip-version (ipv4|ipv6) vni (vni) udp-src"
" (udp-src) udp-dst (udp-dst) ip-src (ip-src) ip-dst"
" (ip-dst) eth-src (eth-src) eth-dst (eth-dst)\n"
@ -918,6 +869,52 @@ static void cmd_help_long_parsed(void *parsed_result,
"port config (port_id) udp_tunnel_port add|rm vxlan|geneve (udp_port)\n\n"
" Add/remove UDP tunnel port for tunneling offload\n\n"
"port config <port_id> rx_offload vlan_strip|"
"ipv4_cksum|udp_cksum|tcp_cksum|tcp_lro|qinq_strip|"
"outer_ipv4_cksum|macsec_strip|header_split|"
"vlan_filter|vlan_extend|jumbo_frame|crc_strip|"
"scatter|timestamp|security|keep_crc on|off\n"
" Enable or disable a per port Rx offloading"
" on all Rx queues of a port\n\n"
"port (port_id) rxq (queue_id) rx_offload vlan_strip|"
"ipv4_cksum|udp_cksum|tcp_cksum|tcp_lro|qinq_strip|"
"outer_ipv4_cksum|macsec_strip|header_split|"
"vlan_filter|vlan_extend|jumbo_frame|crc_strip|"
"scatter|timestamp|security|keep_crc on|off\n"
" Enable or disable a per queue Rx offloading"
" only on a specific Rx queue\n\n"
"port config (port_id) tx_offload vlan_insert|"
"ipv4_cksum|udp_cksum|tcp_cksum|sctp_cksum|tcp_tso|"
"udp_tso|outer_ipv4_cksum|qinq_insert|vxlan_tnl_tso|"
"gre_tnl_tso|ipip_tnl_tso|geneve_tnl_tso|"
"macsec_insert|mt_lockfree|multi_segs|mbuf_fast_free|"
"security|match_metadata on|off\n"
" Enable or disable a per port Tx offloading"
" on all Tx queues of a port\n\n"
"port (port_id) txq (queue_id) tx_offload vlan_insert|"
"ipv4_cksum|udp_cksum|tcp_cksum|sctp_cksum|tcp_tso|"
"udp_tso|outer_ipv4_cksum|qinq_insert|vxlan_tnl_tso|"
"gre_tnl_tso|ipip_tnl_tso|geneve_tnl_tso|macsec_insert"
"|mt_lockfree|multi_segs|mbuf_fast_free|security"
" on|off\n"
" Enable or disable a per queue Tx offloading"
" only on a specific Tx queue\n\n"
"bpf-load rx|tx (port) (queue) (J|M|B) (file_name)\n"
" Load an eBPF program as a callback"
" for particular RX/TX queue\n\n"
"bpf-unload rx|tx (port) (queue)\n"
" Unload previously loaded eBPF program"
" for particular RX/TX queue\n\n"
"port config (port_id) tx_metadata (value)\n"
" Set Tx metadata value per port. Testpmd will add this value"
" to any Tx packet sent from this port\n\n"
);
}
@ -1137,6 +1134,107 @@ static void cmd_help_long_parsed(void *parsed_result,
" flow rules\n\n"
);
}
if (show_all || !strcmp(res->section, "traffic_management")) {
cmdline_printf(
cl,
"\n"
"Traffic Management:\n"
"--------------\n"
"show port tm cap (port_id)\n"
" Display the port TM capability.\n\n"
"show port tm level cap (port_id) (level_id)\n"
" Display the port TM hierarchical level capability.\n\n"
"show port tm node cap (port_id) (node_id)\n"
" Display the port TM node capability.\n\n"
"show port tm node type (port_id) (node_id)\n"
" Display the port TM node type.\n\n"
"show port tm node stats (port_id) (node_id) (clear)\n"
" Display the port TM node stats.\n\n"
#if defined RTE_LIBRTE_PMD_SOFTNIC && defined RTE_LIBRTE_SCHED
"set port tm hierarchy default (port_id)\n"
" Set default traffic Management hierarchy on a port\n\n"
#endif
"add port tm node shaper profile (port_id) (shaper_profile_id)"
" (cmit_tb_rate) (cmit_tb_size) (peak_tb_rate) (peak_tb_size)"
" (packet_length_adjust)\n"
" Add port tm node private shaper profile.\n\n"
"del port tm node shaper profile (port_id) (shaper_profile_id)\n"
" Delete port tm node private shaper profile.\n\n"
"add port tm node shared shaper (port_id) (shared_shaper_id)"
" (shaper_profile_id)\n"
" Add/update port tm node shared shaper.\n\n"
"del port tm node shared shaper (port_id) (shared_shaper_id)\n"
" Delete port tm node shared shaper.\n\n"
"set port tm node shaper profile (port_id) (node_id)"
" (shaper_profile_id)\n"
" Set port tm node shaper profile.\n\n"
"add port tm node wred profile (port_id) (wred_profile_id)"
" (color_g) (min_th_g) (max_th_g) (maxp_inv_g) (wq_log2_g)"
" (color_y) (min_th_y) (max_th_y) (maxp_inv_y) (wq_log2_y)"
" (color_r) (min_th_r) (max_th_r) (maxp_inv_r) (wq_log2_r)\n"
" Add port tm node wred profile.\n\n"
"del port tm node wred profile (port_id) (wred_profile_id)\n"
" Delete port tm node wred profile.\n\n"
"add port tm nonleaf node (port_id) (node_id) (parent_node_id)"
" (priority) (weight) (level_id) (shaper_profile_id)"
" (n_sp_priorities) (stats_mask) (n_shared_shapers)"
" [(shared_shaper_id_0) (shared_shaper_id_1)...]\n"
" Add port tm nonleaf node.\n\n"
"add port tm leaf node (port_id) (node_id) (parent_node_id)"
" (priority) (weight) (level_id) (shaper_profile_id)"
" (cman_mode) (wred_profile_id) (stats_mask) (n_shared_shapers)"
" [(shared_shaper_id_0) (shared_shaper_id_1)...]\n"
" Add port tm leaf node.\n\n"
"del port tm node (port_id) (node_id)\n"
" Delete port tm node.\n\n"
"set port tm node parent (port_id) (node_id) (parent_node_id)"
" (priority) (weight)\n"
" Set port tm node parent.\n\n"
"suspend port tm node (port_id) (node_id)"
" Suspend tm node.\n\n"
"resume port tm node (port_id) (node_id)"
" Resume tm node.\n\n"
"port tm hierarchy commit (port_id) (clean_on_fail)\n"
" Commit tm hierarchy.\n\n"
"set port tm mark ip_ecn (port) (green) (yellow)"
" (red)\n"
" Enables/Disables the traffic management marking"
" for IP ECN (Explicit Congestion Notification)"
" packets on a given port\n\n"
"set port tm mark ip_dscp (port) (green) (yellow)"
" (red)\n"
" Enables/Disables the traffic management marking"
" on the port for IP dscp packets\n\n"
"set port tm mark vlan_dei (port) (green) (yellow)"
" (red)\n"
" Enables/Disables the traffic management marking"
" on the port for VLAN packets with DEI enabled\n\n"
);
}
}
cmdline_parse_token_string_t cmd_help_long_help =
@ -1145,12 +1243,13 @@ cmdline_parse_token_string_t cmd_help_long_help =
cmdline_parse_token_string_t cmd_help_long_section =
TOKEN_STRING_INITIALIZER(struct cmd_help_long_result, section,
"all#control#display#config#"
"ports#registers#filters");
"ports#registers#filters#traffic_management");
cmdline_parse_inst_t cmd_help_long = {
.f = cmd_help_long_parsed,
.data = NULL,
.help_str = "help all|control|display|config|ports|register|filters: "
.help_str = "help all|control|display|config|ports|register|"
"filters|traffic_management: "
"Show help",
.tokens = {
(void *)&cmd_help_long_help,
@ -12070,7 +12169,7 @@ cmd_set_hash_global_config_parsed(void *parsed_result,
res->port_id);
else
printf("Global hash configurations have been set "
"succcessfully by port %d\n", res->port_id);
"successfully by port %d\n", res->port_id);
}
cmdline_parse_token_string_t cmd_set_hash_global_config_all =
@ -15567,10 +15666,9 @@ static void cmd_set_mplsogre_encap_parsed(void *parsed_result,
struct cmd_set_mplsogre_encap_result *res = parsed_result;
union {
uint32_t mplsogre_label;
uint8_t label[3];
uint8_t label[4];
} id = {
.mplsogre_label =
rte_cpu_to_be_32(res->label) & RTE_BE32(0x00ffffff),
.mplsogre_label = rte_cpu_to_be_32(res->label<<12),
};
if (strcmp(res->mplsogre, "mplsogre_encap") == 0)
@ -15583,7 +15681,7 @@ static void cmd_set_mplsogre_encap_parsed(void *parsed_result,
mplsogre_encap_conf.select_ipv4 = 0;
else
return;
rte_memcpy(mplsogre_encap_conf.label, &id.label[1], 3);
rte_memcpy(mplsogre_encap_conf.label, &id.label, 3);
if (mplsogre_encap_conf.select_ipv4) {
IPV4_ADDR_TO_UINT(res->ip_src, mplsogre_encap_conf.ipv4_src);
IPV4_ADDR_TO_UINT(res->ip_dst, mplsogre_encap_conf.ipv4_dst);
@ -15804,10 +15902,9 @@ static void cmd_set_mplsoudp_encap_parsed(void *parsed_result,
struct cmd_set_mplsoudp_encap_result *res = parsed_result;
union {
uint32_t mplsoudp_label;
uint8_t label[3];
uint8_t label[4];
} id = {
.mplsoudp_label =
rte_cpu_to_be_32(res->label) & RTE_BE32(0x00ffffff),
.mplsoudp_label = rte_cpu_to_be_32(res->label<<12),
};
if (strcmp(res->mplsoudp, "mplsoudp_encap") == 0)
@ -15820,7 +15917,7 @@ static void cmd_set_mplsoudp_encap_parsed(void *parsed_result,
mplsoudp_encap_conf.select_ipv4 = 0;
else
return;
rte_memcpy(mplsoudp_encap_conf.label, &id.label[1], 3);
rte_memcpy(mplsoudp_encap_conf.label, &id.label, 3);
mplsoudp_encap_conf.udp_src = rte_cpu_to_be_16(res->udp_src);
mplsoudp_encap_conf.udp_dst = rte_cpu_to_be_16(res->udp_dst);
if (mplsoudp_encap_conf.select_ipv4) {
@ -17627,7 +17724,7 @@ print_rx_offloads(uint64_t offloads)
begin = __builtin_ctzll(offloads);
end = sizeof(offloads) * CHAR_BIT - __builtin_clzll(offloads);
single_offload = 1 << begin;
single_offload = 1ULL << begin;
for (bit = begin; bit < end; bit++) {
if (offloads & single_offload)
printf(" %s",
@ -18021,7 +18118,7 @@ print_tx_offloads(uint64_t offloads)
begin = __builtin_ctzll(offloads);
end = sizeof(offloads) * CHAR_BIT - __builtin_clzll(offloads);
single_offload = 1 << begin;
single_offload = 1ULL << begin;
for (bit = begin; bit < end; bit++) {
if (offloads & single_offload)
printf(" %s",
@ -18198,13 +18295,13 @@ search_tx_offload(const char *name)
single_offload = 1;
for (bit = 0; bit < sizeof(single_offload) * CHAR_BIT; bit++) {
single_name = rte_eth_dev_tx_offload_name(single_offload);
if (single_name == NULL)
break;
if (!strcasecmp(single_name, name)) {
found = 1;
break;
} else if (!strcasecmp(single_name, "UNKNOWN"))
break;
else if (single_name == NULL)
break;
single_offload <<= 1;
}
@ -18457,7 +18554,7 @@ cmd_show_tx_metadata_parsed(void *parsed_result,
}
if (!strcmp(res->cmd_keyword, "tx_metadata")) {
printf("Port %u tx_metadata: %u\n", res->cmd_pid,
ports[res->cmd_pid].tx_metadata);
rte_be_to_cpu_32(ports[res->cmd_pid].tx_metadata));
}
}

View File

@ -35,6 +35,7 @@ enum index {
PREFIX,
BOOLEAN,
STRING,
HEX,
MAC_ADDR,
IPV4_ADDR,
IPV6_ADDR,
@ -1122,6 +1123,9 @@ static int parse_boolean(struct context *, const struct token *,
static int parse_string(struct context *, const struct token *,
const char *, unsigned int,
void *, unsigned int);
static int parse_hex(struct context *ctx, const struct token *token,
const char *str, unsigned int len,
void *buf, unsigned int size);
static int parse_mac_addr(struct context *, const struct token *,
const char *, unsigned int,
void *, unsigned int);
@ -1198,6 +1202,13 @@ static const struct token token_list[] = {
.call = parse_string,
.comp = comp_none,
},
[HEX] = {
.name = "{hex}",
.type = "HEX",
.help = "fixed string",
.call = parse_hex,
.comp = comp_none,
},
[MAC_ADDR] = {
.name = "{MAC address}",
.type = "MAC-48",
@ -2306,7 +2317,7 @@ static const struct token token_list[] = {
[ACTION_RSS_KEY] = {
.name = "key",
.help = "RSS hash key",
.next = NEXT(action_rss, NEXT_ENTRY(STRING)),
.next = NEXT(action_rss, NEXT_ENTRY(HEX)),
.args = ARGS(ARGS_ENTRY_ARB(0, 0),
ARGS_ENTRY_ARB
(offsetof(struct action_rss_data, conf) +
@ -3808,6 +3819,7 @@ parse_vc_action_mplsogre_encap(struct context *ctx, const struct token *token,
header += sizeof(gre);
memcpy(mpls.label_tc_s, mplsogre_encap_conf.label,
RTE_DIM(mplsogre_encap_conf.label));
mpls.label_tc_s[2] |= 0x1;
memcpy(header, &mpls, sizeof(mpls));
header += sizeof(mpls);
action_encap_data->conf.size = header -
@ -3998,6 +4010,7 @@ parse_vc_action_mplsoudp_encap(struct context *ctx, const struct token *token,
header += sizeof(udp);
memcpy(mpls.label_tc_s, mplsoudp_encap_conf.label,
RTE_DIM(mplsoudp_encap_conf.label));
mpls.label_tc_s[2] |= 0x1;
memcpy(header, &mpls, sizeof(mpls));
header += sizeof(mpls);
action_encap_data->conf.size = header -
@ -4439,6 +4452,121 @@ error:
return -1;
}
static int
parse_hex_string(const char *src, uint8_t *dst, uint32_t *size)
{
char *c = NULL;
uint32_t i, len;
char tmp[3];
/* Check input parameters */
if ((src == NULL) ||
(dst == NULL) ||
(size == NULL) ||
(*size == 0))
return -1;
/* Convert chars to bytes */
for (i = 0, len = 0; i < *size; i += 2) {
snprintf(tmp, 3, "%s", src + i);
dst[len++] = strtoul(tmp, &c, 16);
if (*c != 0) {
len--;
dst[len] = 0;
*size = len;
return -1;
}
}
dst[len] = 0;
*size = len;
return 0;
}
static int
parse_hex(struct context *ctx, const struct token *token,
const char *str, unsigned int len,
void *buf, unsigned int size)
{
const struct arg *arg_data = pop_args(ctx);
const struct arg *arg_len = pop_args(ctx);
const struct arg *arg_addr = pop_args(ctx);
char tmp[16]; /* Ought to be enough. */
int ret;
unsigned int hexlen = len;
unsigned int length = 256;
uint8_t hex_tmp[length];
/* Arguments are expected. */
if (!arg_data)
return -1;
if (!arg_len) {
push_args(ctx, arg_data);
return -1;
}
if (!arg_addr) {
push_args(ctx, arg_len);
push_args(ctx, arg_data);
return -1;
}
size = arg_data->size;
/* Bit-mask fill is not supported. */
if (arg_data->mask)
goto error;
if (!ctx->object)
return len;
/* translate bytes string to array. */
if (str[0] == '0' && ((str[1] == 'x') ||
(str[1] == 'X'))) {
str += 2;
hexlen -= 2;
}
if (hexlen > length)
return -1;
ret = parse_hex_string(str, hex_tmp, &hexlen);
if (ret < 0)
goto error;
/* Let parse_int() fill length information first. */
ret = snprintf(tmp, sizeof(tmp), "%u", hexlen);
if (ret < 0)
goto error;
push_args(ctx, arg_len);
ret = parse_int(ctx, token, tmp, ret, NULL, 0);
if (ret < 0) {
pop_args(ctx);
goto error;
}
buf = (uint8_t *)ctx->object + arg_data->offset;
/* Output buffer is not necessarily NUL-terminated. */
memcpy(buf, hex_tmp, hexlen);
memset((uint8_t *)buf + hexlen, 0x00, size - hexlen);
if (ctx->objmask)
memset((uint8_t *)ctx->objmask + arg_data->offset,
0xff, hexlen);
/* Save address if requested. */
if (arg_addr->size) {
memcpy((uint8_t *)ctx->object + arg_addr->offset,
(void *[]){
(uint8_t *)ctx->object + arg_data->offset
},
arg_addr->size);
if (ctx->objmask)
memcpy((uint8_t *)ctx->objmask + arg_addr->offset,
(void *[]){
(uint8_t *)ctx->objmask + arg_data->offset
},
arg_addr->size);
}
return len;
error:
push_args(ctx, arg_addr);
push_args(ctx, arg_len);
push_args(ctx, arg_data);
return -1;
}
/**
* Parse a MAC address.
*

View File

@ -1156,18 +1156,18 @@ struct cmd_add_port_tm_node_wred_profile_result {
uint16_t port_id;
uint32_t wred_profile_id;
cmdline_fixed_string_t color_g;
uint16_t min_th_g;
uint16_t max_th_g;
uint64_t min_th_g;
uint64_t max_th_g;
uint16_t maxp_inv_g;
uint16_t wq_log2_g;
cmdline_fixed_string_t color_y;
uint16_t min_th_y;
uint16_t max_th_y;
uint64_t min_th_y;
uint64_t max_th_y;
uint16_t maxp_inv_y;
uint16_t wq_log2_y;
cmdline_fixed_string_t color_r;
uint16_t min_th_r;
uint16_t max_th_r;
uint64_t min_th_r;
uint64_t max_th_r;
uint16_t maxp_inv_r;
uint16_t wq_log2_r;
};
@ -1206,11 +1206,11 @@ cmdline_parse_token_string_t cmd_add_port_tm_node_wred_profile_color_g =
cmdline_parse_token_num_t cmd_add_port_tm_node_wred_profile_min_th_g =
TOKEN_NUM_INITIALIZER(
struct cmd_add_port_tm_node_wred_profile_result,
min_th_g, UINT16);
min_th_g, UINT64);
cmdline_parse_token_num_t cmd_add_port_tm_node_wred_profile_max_th_g =
TOKEN_NUM_INITIALIZER(
struct cmd_add_port_tm_node_wred_profile_result,
max_th_g, UINT16);
max_th_g, UINT64);
cmdline_parse_token_num_t cmd_add_port_tm_node_wred_profile_maxp_inv_g =
TOKEN_NUM_INITIALIZER(
struct cmd_add_port_tm_node_wred_profile_result,
@ -1226,11 +1226,11 @@ cmdline_parse_token_string_t cmd_add_port_tm_node_wred_profile_color_y =
cmdline_parse_token_num_t cmd_add_port_tm_node_wred_profile_min_th_y =
TOKEN_NUM_INITIALIZER(
struct cmd_add_port_tm_node_wred_profile_result,
min_th_y, UINT16);
min_th_y, UINT64);
cmdline_parse_token_num_t cmd_add_port_tm_node_wred_profile_max_th_y =
TOKEN_NUM_INITIALIZER(
struct cmd_add_port_tm_node_wred_profile_result,
max_th_y, UINT16);
max_th_y, UINT64);
cmdline_parse_token_num_t cmd_add_port_tm_node_wred_profile_maxp_inv_y =
TOKEN_NUM_INITIALIZER(
struct cmd_add_port_tm_node_wred_profile_result,
@ -1246,11 +1246,11 @@ cmdline_parse_token_string_t cmd_add_port_tm_node_wred_profile_color_r =
cmdline_parse_token_num_t cmd_add_port_tm_node_wred_profile_min_th_r =
TOKEN_NUM_INITIALIZER(
struct cmd_add_port_tm_node_wred_profile_result,
min_th_r, UINT16);
min_th_r, UINT64);
cmdline_parse_token_num_t cmd_add_port_tm_node_wred_profile_max_th_r =
TOKEN_NUM_INITIALIZER(
struct cmd_add_port_tm_node_wred_profile_result,
max_th_r, UINT16);
max_th_r, UINT64);
cmdline_parse_token_num_t cmd_add_port_tm_node_wred_profile_maxp_inv_r =
TOKEN_NUM_INITIALIZER(
struct cmd_add_port_tm_node_wred_profile_result,

View File

@ -2955,7 +2955,6 @@ vlan_tpid_set(portid_t port_id, enum rte_vlan_type vlan_type, uint16_t tp_id)
void
tx_vlan_set(portid_t port_id, uint16_t vlan_id)
{
int vlan_offload;
struct rte_eth_dev_info dev_info;
if (port_id_is_invalid(port_id, ENABLED_WARN))
@ -2963,8 +2962,8 @@ tx_vlan_set(portid_t port_id, uint16_t vlan_id)
if (vlan_id_is_invalid(vlan_id))
return;
vlan_offload = rte_eth_dev_get_vlan_offload(port_id);
if (vlan_offload & ETH_VLAN_EXTEND_OFFLOAD) {
if (ports[port_id].dev_conf.txmode.offloads &
DEV_TX_OFFLOAD_QINQ_INSERT) {
printf("Error, as QinQ has been enabled.\n");
return;
}
@ -2983,7 +2982,6 @@ tx_vlan_set(portid_t port_id, uint16_t vlan_id)
void
tx_qinq_set(portid_t port_id, uint16_t vlan_id, uint16_t vlan_id_outer)
{
int vlan_offload;
struct rte_eth_dev_info dev_info;
if (port_id_is_invalid(port_id, ENABLED_WARN))
@ -2993,11 +2991,6 @@ tx_qinq_set(portid_t port_id, uint16_t vlan_id, uint16_t vlan_id_outer)
if (vlan_id_is_invalid(vlan_id_outer))
return;
vlan_offload = rte_eth_dev_get_vlan_offload(port_id);
if (!(vlan_offload & ETH_VLAN_EXTEND_OFFLOAD)) {
printf("Error, as QinQ hasn't been enabled.\n");
return;
}
rte_eth_dev_info_get(port_id, &dev_info);
if ((dev_info.tx_offload_capa & DEV_TX_OFFLOAD_QINQ_INSERT) == 0) {
printf("Error: qinq insert not supported by port %d\n",
@ -3006,7 +2999,8 @@ tx_qinq_set(portid_t port_id, uint16_t vlan_id, uint16_t vlan_id_outer)
}
tx_vlan_reset(port_id);
ports[port_id].dev_conf.txmode.offloads |= DEV_TX_OFFLOAD_QINQ_INSERT;
ports[port_id].dev_conf.txmode.offloads |= (DEV_TX_OFFLOAD_VLAN_INSERT |
DEV_TX_OFFLOAD_QINQ_INSERT);
ports[port_id].tx_vlan_id = vlan_id;
ports[port_id].tx_vlan_id_outer = vlan_id_outer;
}

View File

@ -575,7 +575,7 @@ mbuf_copy_split(const struct rte_mbuf *ms, struct rte_mbuf *md[],
/*
* Allocate a new mbuf with up to tx_pkt_nb_segs segments.
* Copy packet contents and offload information into then new segmented mbuf.
* Copy packet contents and offload information into the new segmented mbuf.
*/
static struct rte_mbuf *
pkt_copy_split(const struct rte_mbuf *pkt)

View File

@ -188,6 +188,8 @@ struct fwd_engine * fwd_engines[] = {
NULL,
};
struct rte_mempool *mempools[RTE_MAX_NUMA_NODES];
struct fwd_config cur_fwd_config;
struct fwd_engine *cur_fwd_eng = &io_fwd_engine; /**< IO mode by default. */
uint32_t retry_enabled;
@ -844,7 +846,7 @@ setup_extmem(uint32_t nb_mbufs, uint32_t mbuf_sz, bool huge)
/*
* Configuration initialisation done once at init time.
*/
static void
static struct rte_mempool *
mbuf_pool_create(uint16_t mbuf_seg_size, unsigned nb_mbuf,
unsigned int socket_id)
{
@ -922,6 +924,7 @@ err:
} else if (verbose_level > 0) {
rte_mempool_dump(stdout, rte_mp);
}
return rte_mp;
}
/*
@ -1139,14 +1142,18 @@ init_config(void)
uint8_t i;
for (i = 0; i < num_sockets; i++)
mbuf_pool_create(mbuf_data_size, nb_mbuf_per_pool,
socket_ids[i]);
mempools[i] = mbuf_pool_create(mbuf_data_size,
nb_mbuf_per_pool,
socket_ids[i]);
} else {
if (socket_num == UMA_NO_CONFIG)
mbuf_pool_create(mbuf_data_size, nb_mbuf_per_pool, 0);
mempools[0] = mbuf_pool_create(mbuf_data_size,
nb_mbuf_per_pool, 0);
else
mbuf_pool_create(mbuf_data_size, nb_mbuf_per_pool,
socket_num);
mempools[socket_num] = mbuf_pool_create
(mbuf_data_size,
nb_mbuf_per_pool,
socket_num);
}
init_port_config();
@ -1388,7 +1395,7 @@ fwd_port_stats_display(portid_t port_id, struct rte_eth_stats *stats)
printf(" RX-packets: %-14"PRIu64" RX-dropped: %-14"PRIu64"RX-total: "
"%-"PRIu64"\n",
stats->ipackets, stats->imissed,
(uint64_t) (stats->ipackets + stats->imissed));
stats->ipackets + stats->imissed);
if (cur_fwd_eng == &csum_fwd_engine)
printf(" Bad-ipcsum: %-14"PRIu64" Bad-l4csum: %-14"PRIu64"Bad-outer-l4csum: %-14"PRIu64"\n",
@ -1402,13 +1409,13 @@ fwd_port_stats_display(portid_t port_id, struct rte_eth_stats *stats)
printf(" TX-packets: %-14"PRIu64" TX-dropped: %-14"PRIu64"TX-total: "
"%-"PRIu64"\n",
stats->opackets, port->tx_dropped,
(uint64_t) (stats->opackets + port->tx_dropped));
stats->opackets + port->tx_dropped);
}
else {
printf(" RX-packets: %14"PRIu64" RX-dropped:%14"PRIu64" RX-total:"
"%14"PRIu64"\n",
stats->ipackets, stats->imissed,
(uint64_t) (stats->ipackets + stats->imissed));
stats->ipackets + stats->imissed);
if (cur_fwd_eng == &csum_fwd_engine)
printf(" Bad-ipcsum:%14"PRIu64" Bad-l4csum:%14"PRIu64" Bad-outer-l4csum: %-14"PRIu64"\n",
@ -1423,7 +1430,7 @@ fwd_port_stats_display(portid_t port_id, struct rte_eth_stats *stats)
printf(" TX-packets: %14"PRIu64" TX-dropped:%14"PRIu64" TX-total:"
"%14"PRIu64"\n",
stats->opackets, port->tx_dropped,
(uint64_t) (stats->opackets + port->tx_dropped));
stats->opackets + port->tx_dropped);
}
#ifdef RTE_TEST_PMD_RECORD_BURST_STATS
@ -1471,15 +1478,19 @@ fwd_stream_stats_display(streamid_t stream_id)
"TX Port=%2d/Queue=%2d %s\n",
fwd_top_stats_border, fs->rx_port, fs->rx_queue,
fs->tx_port, fs->tx_queue, fwd_top_stats_border);
printf(" RX-packets: %-14u TX-packets: %-14u TX-dropped: %-14u",
printf(" RX-packets: %-14"PRIu64" TX-packets: %-14"PRIu64
" TX-dropped: %-14"PRIu64,
fs->rx_packets, fs->tx_packets, fs->fwd_dropped);
/* if checksum mode */
if (cur_fwd_eng == &csum_fwd_engine) {
printf(" RX- bad IP checksum: %-14u Rx- bad L4 checksum: "
"%-14u Rx- bad outer L4 checksum: %-14u\n",
printf(" RX- bad IP checksum: %-14"PRIu64
" Rx- bad L4 checksum: %-14"PRIu64
" Rx- bad outer L4 checksum: %-14"PRIu64"\n",
fs->rx_bad_ip_csum, fs->rx_bad_l4_csum,
fs->rx_bad_outer_l4_csum);
} else {
printf("\n");
}
#ifdef RTE_TEST_PMD_RECORD_BURST_STATS
@ -1755,9 +1766,6 @@ stop_packet_forwarding(void)
uint64_t total_rx_dropped;
uint64_t total_tx_dropped;
uint64_t total_rx_nombuf;
uint64_t tx_dropped;
uint64_t rx_bad_ip_csum;
uint64_t rx_bad_l4_csum;
#ifdef RTE_TEST_PMD_RECORD_CORE_CYCLES
uint64_t fwd_cycles;
#endif
@ -1784,38 +1792,22 @@ stop_packet_forwarding(void)
fwd_cycles = 0;
#endif
for (sm_id = 0; sm_id < cur_fwd_config.nb_fwd_streams; sm_id++) {
struct fwd_stream *fs = fwd_streams[sm_id];
if (cur_fwd_config.nb_fwd_streams >
cur_fwd_config.nb_fwd_ports) {
fwd_stream_stats_display(sm_id);
ports[fwd_streams[sm_id]->tx_port].tx_stream = NULL;
ports[fwd_streams[sm_id]->rx_port].rx_stream = NULL;
ports[fs->tx_port].tx_stream = NULL;
ports[fs->rx_port].rx_stream = NULL;
} else {
ports[fwd_streams[sm_id]->tx_port].tx_stream =
fwd_streams[sm_id];
ports[fwd_streams[sm_id]->rx_port].rx_stream =
fwd_streams[sm_id];
ports[fs->tx_port].tx_stream = fs;
ports[fs->rx_port].rx_stream = fs;
}
tx_dropped = ports[fwd_streams[sm_id]->tx_port].tx_dropped;
tx_dropped = (uint64_t) (tx_dropped +
fwd_streams[sm_id]->fwd_dropped);
ports[fwd_streams[sm_id]->tx_port].tx_dropped = tx_dropped;
rx_bad_ip_csum =
ports[fwd_streams[sm_id]->rx_port].rx_bad_ip_csum;
rx_bad_ip_csum = (uint64_t) (rx_bad_ip_csum +
fwd_streams[sm_id]->rx_bad_ip_csum);
ports[fwd_streams[sm_id]->rx_port].rx_bad_ip_csum =
rx_bad_ip_csum;
rx_bad_l4_csum =
ports[fwd_streams[sm_id]->rx_port].rx_bad_l4_csum;
rx_bad_l4_csum = (uint64_t) (rx_bad_l4_csum +
fwd_streams[sm_id]->rx_bad_l4_csum);
ports[fwd_streams[sm_id]->rx_port].rx_bad_l4_csum =
rx_bad_l4_csum;
ports[fwd_streams[sm_id]->rx_port].rx_bad_outer_l4_csum +=
fwd_streams[sm_id]->rx_bad_outer_l4_csum;
ports[fs->tx_port].tx_dropped += fs->fwd_dropped;
ports[fs->rx_port].rx_bad_ip_csum += fs->rx_bad_ip_csum;
ports[fs->rx_port].rx_bad_l4_csum += fs->rx_bad_l4_csum;
ports[fs->rx_port].rx_bad_outer_l4_csum +=
fs->rx_bad_outer_l4_csum;
#ifdef RTE_TEST_PMD_RECORD_CORE_CYCLES
fwd_cycles = (uint64_t) (fwd_cycles +
@ -2399,6 +2391,7 @@ pmd_test_exit(void)
struct rte_device *device;
portid_t pt_id;
int ret;
int i;
if (test_done == 0)
stop_packet_forwarding();
@ -2406,9 +2399,13 @@ pmd_test_exit(void)
if (ports != NULL) {
no_link_check = 1;
RTE_ETH_FOREACH_DEV(pt_id) {
printf("\nShutting down port %d...\n", pt_id);
printf("\nStopping port %d...\n", pt_id);
fflush(stdout);
stop_port(pt_id);
}
RTE_ETH_FOREACH_DEV(pt_id) {
printf("\nShutting down port %d...\n", pt_id);
fflush(stdout);
close_port(pt_id);
/*
@ -2448,6 +2445,10 @@ pmd_test_exit(void)
return;
}
}
for (i = 0 ; i < RTE_MAX_NUMA_NODES ; i++) {
if (mempools[i])
rte_mempool_free(mempools[i]);
}
printf("\nBye...\n");
}
@ -2961,8 +2962,9 @@ init_port_dcb_config(portid_t pid,
port_conf.rxmode.offloads |= DEV_RX_OFFLOAD_VLAN_FILTER;
/* re-configure the device . */
rte_eth_dev_configure(pid, nb_rxq, nb_rxq, &port_conf);
retval = rte_eth_dev_configure(pid, nb_rxq, nb_rxq, &port_conf);
if (retval < 0)
return retval;
rte_eth_dev_info_get(pid, &rte_port->dev_info);
/* If dev_info.vmdq_pool_base is greater than 0,
@ -3054,6 +3056,8 @@ print_stats(void)
printf("\nPort statistics ====================================");
for (i = 0; i < cur_fwd_config.nb_fwd_ports; i++)
nic_stats_display(fwd_ports_ids[i]);
fflush(stdout);
}
static void

View File

@ -119,12 +119,12 @@ struct fwd_stream {
unsigned int retry_enabled;
/* "read-write" results */
unsigned int rx_packets; /**< received packets */
unsigned int tx_packets; /**< received packets transmitted */
unsigned int fwd_dropped; /**< received packets not forwarded */
unsigned int rx_bad_ip_csum ; /**< received packets has bad ip checksum */
unsigned int rx_bad_l4_csum ; /**< received packets has bad l4 checksum */
unsigned int rx_bad_outer_l4_csum;
uint64_t rx_packets; /**< received packets */
uint64_t tx_packets; /**< received packets transmitted */
uint64_t fwd_dropped; /**< received packets not forwarded */
uint64_t rx_bad_ip_csum ; /**< received packets has bad ip checksum */
uint64_t rx_bad_l4_csum ; /**< received packets has bad l4 checksum */
uint64_t rx_bad_outer_l4_csum;
/**< received packets has bad outer l4 checksum */
unsigned int gro_times; /**< GRO operation times */
#ifdef RTE_TEST_PMD_RECORD_CORE_CYCLES
@ -173,7 +173,6 @@ struct rte_port {
uint16_t tunnel_tso_segsz; /**< Segmentation offload MSS for tunneled pkts. */
uint16_t tx_vlan_id;/**< The tag ID */
uint16_t tx_vlan_id_outer;/**< The outer tag ID */
void *fwd_ctx; /**< Forwarding mode context */
uint64_t rx_bad_ip_csum; /**< rx pkts with bad ip checksum */
uint64_t rx_bad_l4_csum; /**< rx pkts with bad l4 checksum */
uint64_t rx_bad_outer_l4_csum;

7
dpdk/buildtools/symlink-drivers-solibs.sh Executable file → Normal file
View File

@ -7,6 +7,7 @@
# others, e.g. PCI device PMDs depending on the PCI bus driver.
# parameters to script are paths relative to install prefix:
# 1. directory containing driver files e.g. lib64/dpdk/drivers
# 2. directory for installed regular libs e.g. lib64
ln -rsf ${DESTDIR}/${MESON_INSTALL_PREFIX}/$1/* ${DESTDIR}/${MESON_INSTALL_PREFIX}/$2
# 1. directory for installed regular libs e.g. lib64
# 2. subdirectory of libdir where the pmds are
cd ${MESON_INSTALL_DESTDIR_PREFIX}/$1 && ln -sfv $2/librte_*.so* .

0
dpdk/config/arm/armv8_machine.py Normal file → Executable file
View File

View File

@ -6,6 +6,7 @@
march_opt = '-march=@0@'.format(machine)
arm_force_native_march = false
arm_force_default_march = (machine == 'default')
machine_args_generic = [
['default', ['-march=armv8-a+crc+crypto']],
@ -47,6 +48,7 @@ flags_common_default = [
flags_generic = [
['RTE_MACHINE', '"armv8a"'],
['RTE_MAX_LCORE', 256],
['RTE_USE_C11_MEM_MODEL', true],
['RTE_CACHE_LINE_SIZE', 128]]
flags_cavium = [
['RTE_MACHINE', '"thunderx"'],
@ -57,11 +59,13 @@ flags_cavium = [
['RTE_USE_C11_MEM_MODEL', false]]
flags_dpaa = [
['RTE_MACHINE', '"dpaa"'],
['RTE_USE_C11_MEM_MODEL', true],
['RTE_CACHE_LINE_SIZE', 64],
['RTE_MAX_NUMA_NODES', 1],
['RTE_MAX_LCORE', 16]]
flags_dpaa2 = [
['RTE_MACHINE', '"dpaa2"'],
['RTE_USE_C11_MEM_MODEL', true],
['RTE_CACHE_LINE_SIZE', 64],
['RTE_MAX_NUMA_NODES', 1],
['RTE_MAX_LCORE', 16],
@ -102,7 +106,10 @@ else
cmd_generic = ['generic', '', '', 'default', '']
cmd_output = cmd_generic # Set generic by default
machine_args = [] # Clear previous machine args
if not meson.is_cross_build()
if arm_force_default_march and not meson.is_cross_build()
machine = impl_generic
impl_pn = 'default'
elif not meson.is_cross_build()
# The script returns ['Implementer', 'Variant', 'Architecture',
# 'Primary Part number', 'Revision']
detect_vendor = find_program(join_paths(
@ -112,8 +119,8 @@ else
cmd_output = cmd.stdout().to_lower().strip().split(' ')
endif
# Set to generic if variable is not found
machine = get_variable('impl_' + cmd_output[0], 'generic')
if machine == 'generic'
machine = get_variable('impl_' + cmd_output[0], ['generic'])
if machine[0] == 'generic'
machine = impl_generic
cmd_output = cmd_generic
endif

View File

@ -1,6 +1,13 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2017 Intel Corporation
# driver .so files often depend upon the bus drivers for their connect bus,
# e.g. ixgbe depends on librte_bus_pci. This means that the bus drivers need
# to be in the library path, so symlink the drivers from the main lib directory.
meson.add_install_script('../buildtools/symlink-drivers-solibs.sh',
get_option('libdir'),
pmd_subdir_opt)
# set the machine type and cflags for it
if meson.is_cross_build()
machine = host_machine.cpu()

View File

@ -1,14 +1,24 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright(c) 2017 Intel Corporation
# for checking defines we need to use the correct compiler flags
march_opt = '-march=@0@'.format(machine)
# get binutils version for the workaround of Bug 97
ldver = run_command('ld', '-v').stdout().strip()
if ldver.contains('2.30')
if cc.has_argument('-mno-avx512f')
machine_args += '-mno-avx512f'
message('Binutils 2.30 detected, disabling AVX512 support as workaround for bug #97')
endif
if ldver.contains('2.31') and cc.has_argument('-mno-avx512f')
machine_args += '-mno-avx512f'
message('Binutils 2.31 detected, disabling AVX512 support as workaround for bug #249')
endif
endif
# we require SSE4.2 for DPDK
sse_errormsg = '''SSE4.2 instruction set is required for DPDK.
Please set the machine type to "nehalem" or "corei7" or higher value'''
if cc.get_define('__SSE4_2__', args: march_opt) == ''
if cc.get_define('__SSE4_2__', args: machine_args) == ''
error(sse_errormsg)
endif
@ -28,23 +38,23 @@ else
dpdk_conf.set('RTE_ARCH', 'i686')
endif
if cc.get_define('__AES__', args: march_opt) != ''
if cc.get_define('__AES__', args: machine_args) != ''
dpdk_conf.set('RTE_MACHINE_CPUFLAG_AES', 1)
compile_time_cpuflags += ['RTE_CPUFLAG_AES']
endif
if cc.get_define('__PCLMUL__', args: march_opt) != ''
if cc.get_define('__PCLMUL__', args: machine_args) != ''
dpdk_conf.set('RTE_MACHINE_CPUFLAG_PCLMULQDQ', 1)
compile_time_cpuflags += ['RTE_CPUFLAG_PCLMULQDQ']
endif
if cc.get_define('__AVX__', args: march_opt) != ''
if cc.get_define('__AVX__', args: machine_args) != ''
dpdk_conf.set('RTE_MACHINE_CPUFLAG_AVX', 1)
compile_time_cpuflags += ['RTE_CPUFLAG_AVX']
endif
if cc.get_define('__AVX2__', args: march_opt) != ''
if cc.get_define('__AVX2__', args: machine_args) != ''
dpdk_conf.set('RTE_MACHINE_CPUFLAG_AVX2', 1)
compile_time_cpuflags += ['RTE_CPUFLAG_AVX2']
endif
if cc.get_define('__AVX512F__', args: march_opt) != ''
if cc.get_define('__AVX512F__', args: machine_args) != ''
dpdk_conf.set('RTE_MACHINE_CPUFLAG_AVX512F', 1)
compile_time_cpuflags += ['RTE_CPUFLAG_AVX512F']
endif

0
dpdk/devtools/check-forbidden-tokens.awk Normal file → Executable file
View File

View File

@ -90,9 +90,10 @@ bad=$(echo "$headlines" | grep -E --color=always \
-e ':.*\<[hsf]w\>' \
-e ':.*\<l[234]\>' \
-e ':.*\<api\>' \
-e ':.*\<arm\>' \
-e ':.*\<armv7\>' \
-e ':.*\<armv8\>' \
-e ':.*\<ARM\>' \
-e ':.*\<(Aarch64|AArch64|AARCH64|Aarch32|AArch32|AARCH32)\>' \
-e ':.*\<(Armv7|ARMv7|ArmV7|armV7|ARMV7)\>' \
-e ':.*\<(Armv8|ARMv8|ArmV8|armV8|ARMV8)\>' \
-e ':.*\<crc\>' \
-e ':.*\<dma\>' \
-e ':.*\<eeprom\>' \

45
dpdk/devtools/check-symbol-change.sh Normal file → Executable file
View File

@ -31,6 +31,7 @@ build_map_changes()
# Triggering this rule sets in_sec to 1, which actives the
# symbol rule below
/^.*{/ {
gsub("+", "");
if (in_map == 1) {
sec=$(NF-1); in_sec=1;
}
@ -96,7 +97,7 @@ check_for_rule_violations()
then
# Just inform the user of this occurrence, but
# don't flag it as an error
echo -n "INFO: symbol $syname is added but "
echo -n "INFO: symbol $symname is added but "
echo -n "patch has insuficient context "
echo -n "to determine the section name "
echo -n "please ensure the version is "
@ -104,26 +105,46 @@ check_for_rule_violations()
continue
fi
if [ "$secname" != "EXPERIMENTAL" ]
oldsecname=$(sed -n \
"s#$mname $symname \(.*\) del#\1#p" "$mapdb")
# A symbol can not enter a non experimental
# section directly
if [ -z "$oldsecname" ]
then
# Symbols that are getting added in a section
# other than the experimental section
# to be moving from an already supported
# section or its a violation
grep -q \
"$mname $symname [^EXPERIMENTAL] del" "$mapdb"
if [ $? -ne 0 ]
if [ "$secname" = 'EXPERIMENTAL' ]
then
echo -n "INFO: symbol $symname has "
echo -n "been added to the "
echo -n "EXPERIMENTAL section of the "
echo "version map"
continue
else
echo -n "ERROR: symbol $symname "
echo -n "is added in a section "
echo -n "other than the EXPERIMENTAL "
echo -n "is added in the $secname "
echo -n "section, but is expected to "
echo -n "be added in the EXPERIMENTAL "
echo "section of the version map"
ret=1
continue
fi
fi
# This symbol is moving between two sections (the
# original section is not experimental).
# This can be legit, just warn.
if [ "$oldsecname" != 'EXPERIMENTAL' ]
then
echo -n "INFO: symbol $symname is being "
echo -n "moved from $oldsecname to $secname. "
echo -n "Ensure that it has gone through the "
echo "deprecation process"
continue
fi
else
if [ "$secname" != "EXPERIMENTAL" ]
if ! grep -q "$mname $symname .* add" "$mapdb" && \
[ "$secname" != "EXPERIMENTAL" ]
then
# Just inform users that non-experimenal
# symbols need to go through a deprecation

0
dpdk/devtools/check-symbol-maps.sh Normal file → Executable file
View File

View File

@ -44,6 +44,8 @@ print_usage () {
}
check_forbidden_additions() { # <patch>
res=0
# refrain from new additions of rte_panic() and rte_exit()
# multiple folders and expressions are separated by spaces
awk -v FOLDERS="lib drivers" \
@ -51,7 +53,8 @@ check_forbidden_additions() { # <patch>
-v RET_ON_FAIL=1 \
-v MESSAGE='Using rte_panic/rte_exit' \
-f $(dirname $(readlink -e $0))/check-forbidden-tokens.awk \
"$1"
"$1" || res=1
# svg figures must be included with wildcard extension
# because of png conversion for pdf docs
awk -v FOLDERS='doc' \
@ -59,7 +62,9 @@ check_forbidden_additions() { # <patch>
-v RET_ON_FAIL=1 \
-v MESSAGE='Using explicit .svg extension instead of .*' \
-f $(dirname $(readlink -e $0))/check-forbidden-tokens.awk \
"$1"
"$1" || res=1
return $res
}
number=0

View File

@ -9,6 +9,7 @@ default_path=$PATH
# - DPDK_BUILD_TEST_CONFIGS (defconfig1+option1+option2 defconfig2)
# - DPDK_DEP_ARCHIVE
# - DPDK_DEP_CFLAGS
# - DPDK_DEP_ELF (y/[n])
# - DPDK_DEP_ISAL (y/[n])
# - DPDK_DEP_JSON (y/[n])
# - DPDK_DEP_LDFLAGS
@ -96,6 +97,7 @@ reset_env ()
unset CROSS
unset DPDK_DEP_ARCHIVE
unset DPDK_DEP_CFLAGS
unset DPDK_DEP_ELF
unset DPDK_DEP_ISAL
unset DPDK_DEP_JSON
unset DPDK_DEP_LDFLAGS
@ -148,7 +150,7 @@ config () # <directory> <target> <options>
test "$DPDK_DEP_ARCHIVE" != y || \
sed -ri 's,(RESOURCE_TAR=)n,\1y,' $1/.config
test "$DPDK_DEP_ISAL" != y || \
sed -ri 's,(ISAL_PMD=)n,\1y,' $1/.config
sed -ri 's,(PMD_ISAL=)n,\1y,' $1/.config
test "$DPDK_DEP_MLX" != y || \
sed -ri 's,(MLX._PMD=)n,\1y,' $1/.config
test "$DPDK_DEP_SZE" != y || \
@ -156,6 +158,8 @@ config () # <directory> <target> <options>
test "$DPDK_DEP_ZLIB" != y || \
sed -ri 's,(BNX2X_PMD=)n,\1y,' $1/.config
test "$DPDK_DEP_ZLIB" != y || \
sed -ri 's,(PMD_ZLIB=)n,\1y,' $1/.config
test "$DPDK_DEP_ZLIB" != y || \
sed -ri 's,(COMPRESSDEV_TEST=)n,\1y,' $1/.config
test "$DPDK_DEP_PCAP" != y || \
sed -ri 's,(PCAP=)n,\1y,' $1/.config
@ -176,7 +180,7 @@ config () # <directory> <target> <options>
test "$DPDK_DEP_SSL" != y || \
sed -ri 's,(PMD_OPENSSL=)n,\1y,' $1/.config
test "$DPDK_DEP_SSL" != y || \
sed -ri 's,(PMD_QAT=)n,\1y,' $1/.config
sed -ri 's,(QAT_SYM=)n,\1y,' $1/.config
test -z "$FLEXRAN_SDK" || \
sed -ri 's,(BBDEV_TURBO_SW=)n,\1y,' $1/.config
sed -ri 's,(SCHED_.*=)n,\1y,' $1/.config
@ -186,7 +190,9 @@ config () # <directory> <target> <options>
sed -ri 's,(MVPP2_PMD=)n,\1y,' $1/.config
test -z "$LIBMUSDK_PATH" || \
sed -ri 's,(MVNETA_PMD=)n,\1y,' $1/.config
test -z "$DPDK_DEP_JSON" || \
test "$DPDK_DEP_ELF" != y || \
sed -ri 's,(BPF_ELF=)n,\1y,' $1/.config
test "$DPDK_DEP_JSON" != y || \
sed -ri 's,(TELEMETRY=)n,\1y,' $1/.config
build_config_hook $1 $2 $3

12
dpdk/devtools/test-meson-builds.sh Normal file → Executable file
View File

@ -7,7 +7,7 @@
# * if a build-directory already exists we assume it was properly configured
# Run ninja after configuration is done.
srcdir=$(dirname $(readlink -m $0))/..
srcdir=$(dirname $(readlink -f $0))/..
MESON=${MESON:-meson}
use_shared="--default-library=shared"
@ -24,7 +24,7 @@ build () # <directory> <meson options>
{
builddir=$1
shift
if [ ! -d "$builddir" ] ; then
if [ ! -f "$builddir/build.ninja" ] ; then
options="--werror -Dexamples=all $*"
echo "$MESON $options $srcdir $builddir"
$MESON $options $srcdir $builddir
@ -36,6 +36,7 @@ build () # <directory> <meson options>
# shared and static linked builds with gcc and clang
for c in gcc clang ; do
command -v $c >/dev/null 2>&1 || continue
for s in static shared ; do
export CC="ccache $c"
build build-$c-$s --default-library=$s
@ -43,7 +44,12 @@ for c in gcc clang ; do
done
# test compilation with minimal x86 instruction set
build build-x86-default -Dmachine=nehalem $use_shared
default_machine='nehalem'
ok=$(cc -march=$default_machine -E - < /dev/null > /dev/null 2>&1 || echo false)
if [ "$ok" = "false" ] ; then
default_machine='corei7'
fi
build build-x86-default -Dmachine=$default_machine $use_shared
# enable cross compilation if gcc cross-compiler is found
c=aarch64-linux-gnu-gcc

0
dpdk/doc/api/generate_doxygen.sh Normal file → Executable file
View File

0
dpdk/doc/api/generate_examples.sh Normal file → Executable file
View File

View File

@ -18,7 +18,7 @@ Supported Feature Flags
without making any modifications to it (no compression done).
- "OOP SGL In SGL Out" feature flag stands for
"Out-of-place Scatter-gather list Input, Scatter-gater list Output",
"Out-of-place Scatter-gather list Input, Scatter-gather list Output",
which means PMD supports different scatter-gather styled input and output buffers
(i.e. both can consists of multiple segments).

View File

@ -9,6 +9,7 @@ from sphinx import __version__ as sphinx_version
from sphinx.highlighting import PygmentsBridge
from pygments.formatters.latex import LatexFormatter
from os import listdir
from os import environ
from os.path import basename
from os.path import dirname
from os.path import join as path_join
@ -37,7 +38,9 @@ html_add_permalinks = ""
html_show_copyright = False
highlight_language = 'none'
version = subprocess.check_output(['make', '-sRrC', '../../', 'showversion'])
# If MAKEFLAGS is exported by the user, garbage text might end up in version
version = subprocess.check_output(['make', '-sRrC', '../../', 'showversion'],
env=dict(environ, MAKEFLAGS=""))
version = version.decode('utf-8').rstrip()
release = version
@ -388,6 +391,11 @@ def setup(app):
'AEAD',
'AEAD algorithms in crypto drivers',
'AEAD algorithm')
table_file = dirname(__file__) + '/cryptodevs/overview_asym_table.txt'
generate_overview_table(table_file, 5,
'Asymmetric',
'Asymmetric algorithms in crypto drivers',
'Asymmetric algorithm')
table_file = dirname(__file__) + '/compressdevs/overview_feature_table.txt'
generate_overview_table(table_file, 1,
'Features',

View File

@ -825,10 +825,10 @@ format.
.. code-block:: python
sources = files('file1.c', ...)
headers = files('file1.c', ...)
headers = files('file1.h', ...)
The will build based on a number of conventions and assumptions within the DPDK
This will build based on a number of conventions and assumptions within the DPDK
itself, for example, that the library name is the same as the directory name in
which the files are stored.

View File

@ -40,14 +40,14 @@ The main directories that contain files related to documentation are shown below
|-- ...
The API documentation is built from `Doxygen <http://www.stack.nl/~dimitri/doxygen/>`_ comments in the header files.
The API documentation is built from `Doxygen <http://www.doxygen.nl>`_ comments in the header files.
These files are mainly in the ``lib/librte_*`` directories although some of the Poll Mode Drivers in ``drivers/net``
are also documented with Doxygen.
The configuration files that are used to control the Doxygen output are in the ``doc/api`` directory.
The user guides such as *The Programmers Guide* and the *FreeBSD* and *Linux Getting Started* Guides are generated
from RST markup text files using the `Sphinx <http://sphinx-doc.org/index.html>`_ Documentation Generator.
from RST markup text files using the `Sphinx <http://sphinx-doc.org>`_ Documentation Generator.
These files are included in the ``doc/guides/`` directory.
The output is controlled by the ``doc/guides/conf.py`` file.
@ -174,7 +174,8 @@ For full support with figure and table captioning the latest version of Sphinx c
sudo pip install --upgrade sphinx
sudo pip install --upgrade sphinx_rtd_theme
For further information on getting started with Sphinx see the `Sphinx Tutorial <http://sphinx-doc.org/tutorial.html>`_.
For further information on getting started with Sphinx see the
`Sphinx Getting Started <http://www.sphinx-doc.org/en/master/usage/quickstart.html>`_.
.. Note::
@ -204,6 +205,19 @@ The main required packages can be installed as follows:
# Red Hat/Fedora, selective install.
sudo dnf -y install texlive-collection-latexextra
`Latexmk <http://personal.psu.edu/jcc8/software/latexmk-jcc/>`_ is a perl script
for running LaTeX for resolving cross references,
and it also runs auxiliary programs like bibtex, makeindex if necessary, and dvips.
It has also a number of other useful capabilities (see man 1 latexmk).
.. code-block:: console
# Ubuntu/Debian.
sudo apt-get -y install latexmk
# Red Hat/Fedora.
sudo dnf -y install latexmk
Build commands
~~~~~~~~~~~~~~
@ -583,7 +597,7 @@ Doxygen Guidelines
The DPDK API is documented using Doxygen comment annotations in the header files.
Doxygen is a very powerful tool, it is extremely configurable and with a little effort can be used to create expressive documents.
See the `Doxygen website <http://www.stack.nl/~dimitri/doxygen/>`_ for full details on how to use it.
See the `Doxygen website <http://www.doxygen.nl>`_ for full details on how to use it.
The following are some guidelines for use of Doxygen in the DPDK API documentation:

View File

@ -8,7 +8,7 @@ Contributing Code to DPDK
This document outlines the guidelines for submitting code to DPDK.
The DPDK development process is modelled (loosely) on the Linux Kernel development model so it is worth reading the
The DPDK development process is modeled (loosely) on the Linux Kernel development model so it is worth reading the
Linux kernel guide on submitting patches:
`How to Get Your Change Into the Linux Kernel <https://www.kernel.org/doc/html/latest/process/submitting-patches.html>`_.
The rationale for many of the DPDK guidelines is explained in greater detail in the kernel guidelines.
@ -32,6 +32,10 @@ The mailing list for DPDK development is `dev@dpdk.org <http://mails.dpdk.org/ar
Contributors will need to `register for the mailing list <http://mails.dpdk.org/listinfo/dev>`_ in order to submit patches.
It is also worth registering for the DPDK `Patchwork <http://patches.dpdk.org/project/dpdk/list/>`_
If you are using the GitHub service, you can link your repository to
the ``travis-ci.org`` build service. When you push patches to your GitHub
repository, the travis service will automatically build your changes.
The development process requires some familiarity with the ``git`` version control system.
Refer to the `Pro Git Book <http://www.git-scm.com/book/>`_ for further information.

View File

@ -548,26 +548,29 @@ utilities which can be installed via a package manager. For example::
The syntax of the ``validate-abi.sh`` utility is::
./devtools/validate-abi.sh <REV1> <REV2> <TARGET>
./devtools/validate-abi.sh <REV1> <REV2>
Where ``REV1`` and ``REV2`` are valid gitrevisions(7)
https://www.kernel.org/pub/software/scm/git/docs/gitrevisions.html
on the local repo and target is the usual DPDK compilation target.
on the local repo.
For example::
# Check between the previous and latest commit:
./devtools/validate-abi.sh HEAD~1 HEAD x86_64-native-linuxapp-gcc
./devtools/validate-abi.sh HEAD~1 HEAD
# Check on a specific compilation target:
./devtools/validate-abi.sh -t x86_64-native-linux-gcc HEAD~1 HEAD
# Check between two tags:
./devtools/validate-abi.sh v2.0.0 v2.1.0 x86_64-native-linuxapp-gcc
./devtools/validate-abi.sh v2.0.0 v2.1.0
# Check between git master and local topic-branch "vhost-hacking":
./devtools/validate-abi.sh master vhost-hacking x86_64-native-linuxapp-gcc
./devtools/validate-abi.sh master vhost-hacking
After the validation script completes (it can take a while since it need to
compile both tags) it will create compatibility reports in the
``./compat_report`` directory. Listed incompatibilities can be found as
follows::
``./abi-check/compat_report`` directory. Listed incompatibilities can be found
as follows::
grep -lr Incompatible compat_reports/
grep -lr Incompatible abi-check/compat_reports/

View File

@ -1,5 +1,5 @@
.. SPDX-License-Identifier: BSD-3-Clause
Copyright(c) 2015-2017 Intel Corporation.
Copyright(c) 2015-2018 Intel Corporation.
AESN-NI Multi Buffer Crypto Poll Mode Driver
============================================
@ -51,6 +51,8 @@ Limitations
* Chained mbufs are not supported.
* Only in-place is currently supported (destination address is the same as source address).
* RTE_CRYPTO_AEAD_AES_GCM only works properly when the multi-buffer library is
0.51.0 or newer.
Installation
@ -59,8 +61,8 @@ Installation
To build DPDK with the AESNI_MB_PMD the user is required to download the multi-buffer
library from `here <https://github.com/01org/intel-ipsec-mb>`_
and compile it on their user system before building DPDK.
The latest version of the library supported by this PMD is v0.50, which
can be downloaded from `<https://github.com/01org/intel-ipsec-mb/archive/v0.50.zip>`_.
The latest version of the library supported by this PMD is v0.51, which
can be downloaded from `<https://github.com/01org/intel-ipsec-mb/archive/v0.51.zip>`.
.. code-block:: console
@ -123,7 +125,7 @@ Extra notes
For AES Counter mode (AES-CTR), the library supports two different sizes for Initialization
Vector (IV):
* 12 bytes: used mainly for IPSec, as it requires 12 bytes from the user, which internally
* 12 bytes: used mainly for IPsec, as it requires 12 bytes from the user, which internally
are appended the counter block (4 bytes), which is set to 1 for the first block
(no padding required from the user)

View File

@ -30,3 +30,8 @@ AES GMAC = Y
AES GCM (128) = Y
AES GCM (192) = Y
AES GCM (256) = Y
;
; Supported Asymmetric algorithms of the 'aesni_gcm' crypto driver.
;
[Asymmetric]

View File

@ -32,16 +32,30 @@ DES DOCSIS BPI = Y
;
[Auth]
MD5 HMAC = Y
SHA1 = Y
SHA1 HMAC = Y
SHA224 = Y
SHA224 HMAC = Y
SHA256 = Y
SHA256 HMAC = Y
SHA384 = Y
SHA384 HMAC = Y
SHA512 = Y
SHA512 HMAC = Y
AES XCBC MAC = Y
AES CMAC (128) = Y
AES GMAC = Y
;
; Supported AEAD algorithms of the 'aesni_mb' crypto driver.
;
[AEAD]
AES CCM (128) = Y
AES GCM (128) = Y
AES GCM (192) = Y
AES GCM (256) = Y
;
; Supported Asymmetric algorithms of the 'aesni_mb' crypto driver.
;
[Asymmetric]

View File

@ -26,3 +26,8 @@ SHA256 HMAC = Y
; Supported AEAD algorithms of the 'armv8' crypto driver.
;
[AEAD]
;
; Supported Asymmetric algorithms of the 'armv8' crypto driver.
;
[Asymmetric]

View File

@ -44,3 +44,8 @@ SHA512 HMAC = Y
AES GCM (128) = Y
AES GCM (192) = Y
AES GCM (256) = Y
;
; Supported Asymmetric algorithms of the 'dpaa2_sec' crypto driver.
;
[Asymmetric]

View File

@ -57,3 +57,8 @@ SHA3_512 HMAC = Y
AES GCM (128) = Y
AES GCM (192) = Y
AES GCM (256) = Y
;
; Supported Asymmetric algorithms of the 'ccp' crypto driver.
;
[Asymmetric]

View File

@ -95,3 +95,12 @@ AES GCM (256) =
AES CCM (128) =
AES CCM (192) =
AES CCM (256) =
;
; Supported Asymmetric algorithms of a default crypto driver.
;
[Asymmetric]
RSA =
DSA =
Modular Exponentiation =
Modular Inversion =
Diffie-hellman =

View File

@ -44,3 +44,8 @@ SHA512 HMAC = Y
AES GCM (128) = Y
AES GCM (192) = Y
AES GCM (256) = Y
;
; Supported Asymmetric algorithms of the 'dpaa2_sec' crypto driver.
;
[Asymmetric]

View File

@ -44,3 +44,8 @@ SHA512 HMAC = Y
AES GCM (128) = Y
AES GCM (192) = Y
AES GCM (256) = Y
;
; Supported Asymmetric algorithms of the 'dpaa_sec' crypto driver.
;
[Asymmetric]

View File

@ -22,3 +22,8 @@ KASUMI F9 = Y
; Supported AEAD algorithms of the 'kasumi' crypto driver.
;
[AEAD]
;
; Supported Asymmetric algorithms of the 'kasumi' crypto driver.
;
[Asymmetric]

View File

@ -52,3 +52,8 @@ AES GMAC = Y
AES GCM (128) = Y
AES GCM (192) = Y
AES GCM (256) = Y
;
; Supported Asymmetric algorithms of the 'mvsam' crypto driver.
;
[Asymmetric]

View File

@ -24,3 +24,8 @@ NULL = Y
; Supported AEAD algorithms of the 'null' crypto driver.
;
[AEAD]
;
; Supported Asymmetric algorithms of the 'null' crypto driver.
;
[Asymmetric]

View File

@ -60,3 +60,8 @@ ZUC EIA3 = Y
AES GCM (128) = Y
AES GCM (192) = Y
AES GCM (256) = Y
;
; Supported Asymmetric algorithms of the 'octeontx' crypto driver.
;
[Asymmetric]

View File

@ -60,3 +60,8 @@ AES GCM (256) = Y
AES CCM (128) = Y
AES CCM (192) = Y
AES CCM (256) = Y
;
; Supported Asymmetric algorithms of the 'qat' crypto driver.
;
[Asymmetric]

View File

@ -22,3 +22,8 @@ SNOW3G UIA2 = Y
; Supported AEAD algorithms of the 'snow3g' crypto driver.
;
[AEAD]
;
; Supported Asymmetric algorithms of the 'snow3g' crypto driver.
;
[Asymmetric]

View File

@ -24,3 +24,8 @@ SHA1 HMAC = Y
; Supported AEAD algorithms of the 'virtio' crypto driver.
;
[AEAD]
;
; Supported Asymmetric algorithms of the 'virtio' crypto driver.
;
[Asymmetric]

View File

@ -22,3 +22,8 @@ ZUC EIA3 = Y
; Supported AEAD algorithms of the 'zuc' crypto driver.
;
[AEAD]
;
; Supported Asymmetric algorithms of the 'zuc' crypto driver.
;
[Asymmetric]

View File

@ -46,6 +46,14 @@ Supported AEAD algorithms:
* ``RTE_CRYPTO_AEAD_AES_GCM``
* ``RTE_CRYPTO_AEAD_AES_CCM``
Supported Asymmetric Crypto algorithms:
* ``RTE_CRYPTO_ASYM_XFORM_RSA``
* ``RTE_CRYPTO_ASYM_XFORM_DSA``
* ``RTE_CRYPTO_ASYM_XFORM_DH``
* ``RTE_CRYPTO_ASYM_XFORM_MODINV``
* ``RTE_CRYPTO_ASYM_XFORM_MODEX``
Installation
------------

View File

@ -18,7 +18,7 @@ Supported Feature Flags
being the operation in-place (input address = output address).
- "OOP SGL In SGL Out" feature flag stands for
"Out-of-place Scatter-gather list Input, Scatter-gater list Output",
"Out-of-place Scatter-gather list Input, Scatter-gather list Output",
which means pmd supports different scatter-gather styled input and output buffers
(i.e. both can consists of multiple segments).
@ -58,3 +58,10 @@ Supported AEAD Algorithms
.. _table_crypto_pmd_aead_algos:
.. include:: overview_aead_table.txt
Supported Asymmetric Algorithms
-------------------------------
.. _table_crypto_pmd_asym_algos:
.. include:: overview_asym_table.txt

View File

@ -79,10 +79,9 @@ Limitations
* SNOW 3G (UIA2) and ZUC (EIA3) supported only if hash length and offset fields are byte-multiple.
* No BSD support as BSD QAT kernel driver not available.
* ZUC EEA3/EIA3 is not supported by dh895xcc devices
* Maximum additional authenticated data (AAD) for GCM is 240 bytes long.
* Maximum additional authenticated data (AAD) for GCM is 240 bytes long and must be passed to the device in a buffer rounded up to the nearest block-size multiple (x16) and padded with zeros.
* Queue pairs are not thread-safe (that is, within a single queue pair, RX and TX from different lcores is not supported).
Extra notes on KASUMI F9
~~~~~~~~~~~~~~~~~~~~~~~~

View File

@ -165,7 +165,7 @@ operation:
For pure small packet size (64 bytes) traffic however the multi-core mode is not
an optimal solution, as it doesn't give significant per-core performance improvement.
For mixed traffic (IMIX) the optimal number of worker cores is around 2-3.
For large packets (1.5 Kbytes) scheduler shows linear scaling in performance
For large packets (1.5 kbytes) scheduler shows linear scaling in performance
up to eight cores.
Each worker uses its own slave cryptodev. Only software cryptodevs
are supported. Only the same type of cryptodevs should be used concurrently.

View File

@ -8,7 +8,7 @@ The OPDL (Ordered Packet Distribution Library) eventdev is a specific\
implementation of the eventdev API. It is particularly suited to packet\
processing workloads that have high throughput and low latency requirements.\
All packets follow the same path through the device. The order in which\
packets follow is determinted by the order in which queues are set up.\
packets follow is determined by the order in which queues are set up.\
Events are left on the ring until they are transmitted. As a result packets\
do not go out of order

View File

@ -70,7 +70,7 @@ Credit Quanta
The credit quanta is the number of credits that a port will fetch at a time from
the instance's credit pool. Higher numbers will cause less overhead in the
atomic credit fetch code, however it also reduces the overall number of credits
in the system faster. A balanced number (eg 32) ensures that only small numbers
in the system faster. A balanced number (e.g. 32) ensures that only small numbers
of credits are pre-allocated at a time, while also mitigating performance impact
of the atomics.
@ -100,7 +100,7 @@ feature would be significant.
~~~~~~~~~~~~~~~~~~
The software eventdev does not support creating queues that handle all types of
traffic. An eventdev with this capability allows enqueueing Atomic, Ordered and
traffic. An eventdev with this capability allows enqueuing Atomic, Ordered and
Parallel traffic to the same queue, but scheduling each of them appropriately.
The reason to not allow Atomic, Ordered and Parallel event types in the

View File

@ -328,7 +328,7 @@ On host_server_2: Terminal 1
.. code-block:: console
testomd> show port info all
testpmd> show port info all
testpmd> show port stats all
testpmd> show bonding config 2
testpmd> port attach 0000:00:04.0

View File

@ -243,7 +243,7 @@ On host_server_2: Terminal 1
.. code-block:: console
testomd> show port info all
testpmd> show port info all
testpmd> show port stats all
Virtio traffic is seen at P0 and P1.
@ -338,7 +338,7 @@ reset_vf_on_212_131.sh
#!/bin/sh
# This script is run on the host 10.237.212.131 to reset SRIOV
# BDF for Ninatic NIC is 0000:06:00.0
# BDF for Niantic NIC is 0000:06:00.0
cat /sys/bus/pci/devices/0000\:06\:00.0/max_vfs
echo 0 > /sys/bus/pci/devices/0000\:06\:00.0/max_vfs
cat /sys/bus/pci/devices/0000\:06\:00.0/max_vfs

View File

@ -23,7 +23,7 @@ In this example we will create a simple rule that drops packets whose IPv4
destination equals 192.168.3.2. This code is equivalent to the following
testpmd command (wrapped for clarity)::
tpmd> flow create 0 ingress pattern eth / vlan /
testpmd> flow create 0 ingress pattern eth / vlan /
ipv4 dst is 192.168.3.2 / end actions drop / end
Code
@ -118,7 +118,7 @@ a mask.
This code is equivalent to the following testpmd command (wrapped for
clarity)::
tpmd> flow create 0 ingress pattern eth / vlan /
testpmd> flow create 0 ingress pattern eth / vlan /
ipv4 dst spec 192.168.3.0 dst mask 255.255.255.0 /
end actions drop / end
@ -219,7 +219,7 @@ In this example we will create a rule that routes all vlan id 123 to queue 3.
This code is equivalent to the following testpmd command (wrapped for
clarity)::
tpmd> flow create 0 ingress pattern eth / vlan vid spec 123 /
testpmd> flow create 0 ingress pattern eth / vlan vid spec 123 /
end actions queue index 3 / end
Code

View File

@ -1,7 +1,7 @@
.. SPDX-License-Identifier: BSD-3-Clause
Copyright(c) 2016 Intel Corporation.
.. _virtio_user_as_excpetional_path:
.. _virtio_user_as_exceptional_path:
Virtio_user as Exceptional Path
===============================
@ -22,7 +22,7 @@ solution is very promising in:
* Features
vhost-net is born to be a networking solution, which has lots of networking
related featuers, like multi queue, tso, multi-seg mbuf, etc.
related features, like multi queue, tso, multi-seg mbuf, etc.
* Performance
@ -38,7 +38,7 @@ in :numref:`figure_virtio_user_as_exceptional_path`.
.. figure:: img/virtio_user_as_exceptional_path.*
Overview of a DPDK app using virtio-user as excpetional path
Overview of a DPDK app using virtio-user as exceptional path
Sample Usage
@ -75,7 +75,7 @@ compiling the kernel and those kernel modules should be inserted.
* ``queues``
Number of multi-queues. Each qeueue will be served by a kthread. For example:
Number of multi-queues. Each queue will be served by a kthread. For example:
.. code-block:: console

View File

@ -14,25 +14,25 @@ This chapter describes how to cross compile DPDK for ARM64 from x86 build hosts.
Obtain the cross tool chain
---------------------------
The latest cross compile tool chain can be downloaded from:
https://releases.linaro.org/components/toolchain/binaries/latest/aarch64-linux-gnu/.
https://developer.arm.com/open-source/gnu-toolchain/gnu-a/downloads.
Following is the step to get the version 7.2.1, latest one at the time of this writing.
Following is the step to get the version 8.2, latest one at the time of this writing.
.. code-block:: console
wget https://releases.linaro.org/components/toolchain/binaries/latest/aarch64-linux-gnu/gcc-linaro-7.2.1-2017.11-x86_64_aarch64-linux-gnu.tar.xz
wget https://developer.arm.com/-/media/Files/downloads/gnu-a/8.2-2019.01/gcc-arm-8.2-2019.01-x86_64-aarch64-linux-gnu.tar.xz
Unzip and add into the PATH
---------------------------
.. code-block:: console
tar -xvf gcc-linaro-7.2.1-2017.11-x86_64_aarch64-linux-gnu.tar.xz
export PATH=$PATH:<cross_install_dir>/gcc-linaro-7.2.1-2017.11-x86_64_aarch64-linux-gnu/bin
tar -xvf gcc-arm-8.2-2019.01-x86_64-aarch64-linux-gnu.tar.xz
export PATH=$PATH:<cross_install_dir>/gcc-arm-8.2-2019.01-x86_64-aarch64-linux-gnu/bin
.. note::
For the host requirements and other info, refer to the release note section: https://releases.linaro.org/components/toolchain/binaries/latest/
For the host requirements and other info, refer to the release note section: https://releases.linaro.org/components/toolchain/binaries/
Getting the prerequisite library
--------------------------------
@ -69,8 +69,8 @@ Copy the NUMA header files and lib to the cross compiler's directories:
.. code-block:: console
cp <numa_install_dir>/include/numa*.h <cross_install_dir>/gcc-linaro-7.2.1-2017.11-x86_64_aarch64-linux-gnu/bin/../aarch64-linux-gnu/libc/usr/include/
cp <numa_install_dir>/lib/libnuma.a <cross_install_dir>/gcc-linaro-7.2.1-2017.11-x86_64_aarch64-linux-gnu/lib/gcc/aarch64-linux-gnu/7.2.1/
cp <numa_install_dir>/include/numa*.h <cross_install_dir>/gcc-arm-8.2-2019.01-x86_64-aarch64-linux-gnu/bin/../aarch64-linux-gnu/libc/usr/include/
cp <numa_install_dir>/lib/libnuma.a <cross_install_dir>/gcc-arm-8.2-2019.01-x86_64-aarch64-linux-gnu/lib/gcc/aarch64-linux-gnu/8.2/
.. _configure_and_cross_compile_dpdk_build:

View File

@ -70,6 +70,15 @@ Compilation of the DPDK
* libnuma-dev in Debian/Ubuntu;
.. note::
On systems with NUMA support, `libnuma-dev` (aka `numactl-devel`)
is a recommended dependency when `--legacy-mem` switch is used,
and a *required* dependency if default memory mode is used.
While DPDK will compile and run without `libnuma`
even on NUMA-enabled systems,
both usability and performance will be degraded.
* Python, version 2.7+ or 3.2+, to use various helper scripts included in the DPDK package.
@ -175,7 +184,7 @@ In the case of a dual-socket NUMA system,
the number of hugepages reserved at boot time is generally divided equally between the two sockets
(on the assumption that sufficient memory is present on both sockets).
See the Documentation/kernel-parameters.txt file in your Linux source tree for further details of these and other kernel options.
See the Documentation/admin-guide/kernel-parameters.txt file in your Linux source tree for further details of these and other kernel options.
**Alternative:**

View File

@ -18,7 +18,7 @@ Supported features
- Port statistics
- RSS (Receive Side Scaling)
- Checksum offload
- Jumbo Frame upto 16K
- Jumbo Frame up to 16K
Configuration Information
^^^^^^^^^^^^^^^^^^^^^^^^^

View File

@ -126,7 +126,7 @@ enabling debugging options may affect system performance.
- ``CONFIG_RTE_LIBRTE_CXGBE_TPUT`` (default **y**)
Toggle behaviour to prefer Throughput or Latency.
Toggle behavior to prefer Throughput or Latency.
Runtime Options
~~~~~~~~~~~~~~~
@ -140,7 +140,7 @@ be passed as part of EAL arguments. For example,
- ``keep_ovlan`` (default **0**)
Toggle behaviour to keep/strip outer VLAN in Q-in-Q packets. If
Toggle behavior to keep/strip outer VLAN in Q-in-Q packets. If
enabled, the outer VLAN tag is preserved in Q-in-Q packets. Otherwise,
the outer VLAN tag is stripped in Q-in-Q packets.

View File

@ -251,7 +251,7 @@ state during application initialization:
automatically be assigned from the these high perf PUSH queues. Any queue
configuration beyond that will be standard Rx queues. The application can
choose to change their number if HW portals are limited.
The valid values are from '0' to '4'. The valuse shall be set to '0' if the
The valid values are from '0' to '4'. The values shall be set to '0' if the
application want to use eventdev with DPAA device.

View File

@ -379,7 +379,7 @@ active -- Ethernet, crypto, compression, etc.
DPBP based Mempool driver
~~~~~~~~~~~~~~~~~~~~~~~~~
The DPBP driver is bound to a DPBP objects and provides sevices to
The DPBP driver is bound to a DPBP objects and provides services to
create a hardware offloaded packet buffer mempool.
DPAA2 NIC Driver

View File

@ -69,7 +69,7 @@ Supported ENETC SoCs
Prerequisites
~~~~~~~~~~~~~
There are three main pre-requisities for executing ENETC PMD on a ENETC
There are three main pre-requisites for executing ENETC PMD on a ENETC
compatible board:
1. **ARM 64 Tool Chain**

View File

@ -224,7 +224,7 @@ the use of SR-IOV.
passthrough devices do not require libvirt, port profiles, and VM-FEX.
.. _enic-genic-flow-api:
.. _enic-generic-flow-api:
Generic Flow API support
------------------------
@ -247,7 +247,7 @@ Generic Flow API is supported. The baseline support is:
in the pattern.
- Attributes: ingress
- Items: eth, ipv4, ipv6, udp, tcp, vxlan, inner eth, ipv4, ipv6, udp, tcp
- Items: eth, vlan, ipv4, ipv6, udp, tcp, vxlan, inner eth, vlan, ipv4, ipv6, udp, tcp
- Actions: queue and void
- Selectors: 'is', 'spec' and 'mask'. 'last' is not supported
- In total, up to 64 bytes of mask is allowed across all headers
@ -255,7 +255,7 @@ Generic Flow API is supported. The baseline support is:
- **1300 and later series VICS with advanced filters enabled**
- Attributes: ingress
- Items: eth, ipv4, ipv6, udp, tcp, vxlan, inner eth, ipv4, ipv6, udp, tcp
- Items: eth, vlan, ipv4, ipv6, udp, tcp, vxlan, inner eth, vlan, ipv4, ipv6, udp, tcp
- Actions: queue, mark, drop, flag and void
- Selectors: 'is', 'spec' and 'mask'. 'last' is not supported
- In total, up to 64 bytes of mask is allowed across all headers
@ -266,6 +266,12 @@ Generic Flow API is supported. The baseline support is:
- Action: count
The VIC performs packet matching after applying VLAN strip. If VLAN
stripping is enabled, EtherType in the ETH item corresponds to the
stripped VLAN header's EtherType. Stripping does not affect the VLAN
item. TCI and EtherType in the VLAN item are matched against those in
the (stripped) VLAN header whether stripping is enabled or disabled.
More features may be added in future firmware and new versions of the VIC.
Please refer to the release notes.
@ -450,6 +456,7 @@ PKT_RX_VLAN_STRIPPED mbuf flags would not be set. This mode is enabled with the
1000 for 1300 series VICs). Filters are checked for matching in the order they
were added. Since there currently is no grouping or priority support,
'catch-all' filters should be added last.
- The supported range of IDs for the 'MARK' action is 0 - 0xFFFD.
- **Statistics**

View File

@ -285,7 +285,7 @@ Inner RSS
Supports RX RSS hashing on Inner headers.
* **[users] rte_flow_action_rss**: ``level``.
* **[uses] rte_flow_action_rss**: ``level``.
* **[provides] mbuf**: ``mbuf.ol_flags:PKT_RX_RSS_HASH``, ``mbuf.rss``.
@ -495,7 +495,7 @@ Supports adding traffic mirroring rules.
Inline crypto
-------------
Supports inline crypto processing (eg. inline IPsec). See Security library and PMD documentation for more details.
Supports inline crypto processing (e.g. inline IPsec). See Security library and PMD documentation for more details.
* **[uses] rte_eth_rxconf,rte_eth_rxmode**: ``offloads:DEV_RX_OFFLOAD_SECURITY``,
* **[uses] rte_eth_txconf,rte_eth_txmode**: ``offloads:DEV_TX_OFFLOAD_SECURITY``.

View File

@ -23,6 +23,7 @@ N-tuple filter = Y
Tunnel filter = Y
Flow director = Y
Flow control = Y
Flow API = Y
CRC offload = Y
VLAN offload = Y
L3 checksum offload = Y

View File

@ -571,7 +571,7 @@ bandwidth setting.
TC TX scheduling mode setting
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
There're 2 TX scheduling modes for TCs, round robin and strict priority mode.
There are 2 TX scheduling modes for TCs, round robin and strict priority mode.
If a TC is set to strict priority mode, it can consume unlimited bandwidth.
It means if APP has set the max bandwidth for that TC, it comes to no
effect.
@ -695,3 +695,9 @@ See :numref:`figure_intel_perf_test_setup` for the performance test setup.
* Start creating a stream on packet generator.
* Set the Ethernet II type to 0x0800.
Tx bytes affected by the link status change
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
For firmware versions prior to 6.01 for X710 series and 3.33 for X722 series, the tx_bytes statistics data is affected by
the link down event. Each time the link status changes to down, the tx_bytes decreases 110 bytes.

View File

@ -19,9 +19,9 @@ Config File Options
The following option can be modified in the ``config`` file.
- ``CONFIG_RTE_LIBRTE_IFCVF_VDPA_PMD`` (default ``y`` for linux)
- ``CONFIG_RTE_LIBRTE_IFC_PMD`` (default ``y`` for linux)
Toggle compilation of the ``librte_ifcvf_vdpa`` driver.
Toggle compilation of the ``librte_pmd_ifc`` driver.
IFCVF vDPA Implementation

View File

@ -203,8 +203,8 @@ as a workaround.
X550 does not support legacy interrupt mode
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Desccription
^^^^^^^^^^^^
Description
^^^^^^^^^^^
X550 cannot get interrupts if using ``uio_pci_generic`` module or using legacy
interrupt mode of ``igb_uio`` or ``vfio``. Because the errata of X550 states
that the Interrupt Status bit is not implemented. The errata is the item #22

View File

@ -64,7 +64,7 @@ backend device by default.
PMD arguments
-------------
``no_request_thread``, by default PMD creates a phtread for each KNI interface
``no_request_thread``, by default PMD creates a pthread for each KNI interface
to handle Linux network interface control commands, like ``ifconfig kni0 up``
With ``no_request_thread`` option, pthread is not created and control commands

View File

@ -85,6 +85,11 @@ Limitations
- Forked secondary process not supported.
- All mempools must be initialized before rte_eth_dev_start().
- External memory unregistered in EAL memseg list cannot be used for DMA
unless such memory has been registered by ``mlx5_mr_update_ext_mp()`` in
primary process and remapped to the same virtual address in secondary
process. If the external memory is registered by primary process but has
different virtual address in secondary process, unexpected error may happen.
- Flow pattern without any specific vlan will match for vlan packets as well:
@ -148,7 +153,7 @@ Limitations
- E-Switch VXLAN decapsulation Flow:
- can be appiled to PF port only.
- can be applied to PF port only.
- must specify VF port action (packet redirection from PF to VF).
- must specify tunnel outer UDP local (destination) port, wildcards not allowed.
- must specify tunnel outer VNI, wildcards not allowed.
@ -163,7 +168,7 @@ Limitations
- must specify the VXLAN item with tunnel outer parameters.
- must specify the tunnel outer VNI in the VXLAN item.
- must specify the tunnel outer remote (destination) UDP port in the VXLAN item.
- must specify the tunnel outer local (source) IPv4 or IPv6 in the , this address will locally (with scope link) assigned to the outer network interace, wildcards not allowed.
- must specify the tunnel outer local (source) IPv4 or IPv6 in the , this address will locally (with scope link) assigned to the outer network interface, wildcards not allowed.
- must specify the tunnel outer remote (destination) IPv4 or IPv6 in the VXLAN item, group IPs allowed.
- must specify the tunnel outer destination MAC address in the VXLAN item, this address will be used to create neigh rule.
@ -227,20 +232,6 @@ Environment variables
enabled and most useful when ``CONFIG_RTE_EAL_PMD_PATH`` is also set,
since ``LD_LIBRARY_PATH`` has no effect in this case.
- ``MLX5_PMD_ENABLE_PADDING``
Enables HW packet padding in PCI bus transactions.
When packet size is cache aligned and CRC stripping is enabled, 4 fewer
bytes are written to the PCI bus. Enabling padding makes such packets
aligned again.
In cases where PCI bandwidth is the bottleneck, padding can improve
performance by 10%.
This is disabled by default since this can also decrease performance for
unaligned packet sizes.
- ``MLX5_SHUT_UP_BF``
Configures HW Tx doorbell register as IO-mapped.
@ -295,6 +286,19 @@ Run-time configuration
- CPU having 128B cacheline with ConnectX-5 and Bluefield.
- ``rxq_pkt_pad_en`` parameter [int]
A nonzero value enables padding Rx packet to the size of cacheline on PCI
transaction. This feature would waste PCI bandwidth but could improve
performance by avoiding partial cacheline write which may cause costly
read-modify-copy in memory transaction on some architectures. Disabled by
default.
Supported on:
- x86_64 with ConnectX-4, ConnectX-4 LX, ConnectX-5, ConnectX-6 and Bluefield.
- POWER8 and ARMv8 with ConnectX-4 LX, ConnectX-5, ConnectX-6 and Bluefield.
- ``mprq_en`` parameter [int]
A nonzero value enables configuring Multi-Packet Rx queues. Rx queue is
@ -307,7 +311,7 @@ Run-time configuration
buffers per a packet, one large buffer is posted in order to receive multiple
packets on the buffer. A MPRQ buffer consists of multiple fixed-size strides
and each stride receives one packet. MPRQ can improve throughput for
small-packet tarffic.
small-packet traffic.
When MPRQ is enabled, max_rx_pkt_len can be larger than the size of
user-provided mbuf even if DEV_RX_OFFLOAD_SCATTER isn't enabled. PMD will
@ -318,7 +322,7 @@ Run-time configuration
- ``mprq_log_stride_num`` parameter [int]
Log 2 of the number of strides for Multi-Packet Rx queue. Configuring more
strides can reduce PCIe tarffic further. If configured value is not in the
strides can reduce PCIe traffic further. If configured value is not in the
range of device capability, the default value will be set with a warning
message. The default value is 4 which is 16 strides per a buffer, valid only
if ``mprq_en`` is set.
@ -565,7 +569,7 @@ Either RDMA Core library with a recent enough Linux kernel release
(recommended) or Mellanox OFED, which provides compatibility with older
releases.
RMDA Core with Linux Kernel
RDMA Core with Linux Kernel
^^^^^^^^^^^^^^^^^^^^^^^^^^^
- Minimal kernel version : v4.14 or the most recent 4.14-rc (see `Linux installation documentation`_)

View File

@ -91,7 +91,7 @@ Limitations
chance to start in a sane state.
- MUSDK architecture does not support changing configuration in run time.
All nessesary configurations should be done before first dev_start().
All necessary configurations should be done before first dev_start().
- RX queue start/stop is not supported.

View File

@ -89,7 +89,7 @@ operations:
.. Note::
The dpkd-devbind.py script can not be used since it only handles PCI devices.
The dpdk-devbind.py script can not be used since it only handles PCI devices.
Prerequisites

View File

@ -96,7 +96,7 @@ Non-supported Features
The features not yet supported include:
- Receive queue interupts
- Receive queue interrupts
- Priority-based flow control
@ -207,12 +207,12 @@ Supported actions:
Validating flow rules depends on the firmware variant.
Ethernet destinaton individual/group match
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Ethernet destination individual/group match
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Ethernet item supports I/G matching, if only the corresponding bit is set
in the mask of destination address. If destinaton address in the spec is
multicast, it matches all multicast (and broadcast) packets, oherwise it
in the mask of destination address. If destination address in the spec is
multicast, it matches all multicast (and broadcast) packets, otherwise it
matches unicast packets that are not filtered by other flow rules.
Exceptions to flow rules
@ -346,10 +346,10 @@ boolean parameters value.
- ``perf_profile`` [auto|throughput|low-latency] (default **throughput**)
Choose hardware tunning to be optimized for either throughput or
Choose hardware tuning to be optimized for either throughput or
low-latency.
**auto** allows NIC firmware to make a choice based on
installed licences and firmware variant configured using **sfboot**.
installed licenses and firmware variant configured using **sfboot**.
- ``stats_update_period_ms`` [long] (default **1000**)

View File

@ -89,7 +89,7 @@ The NFB cards are multi-port multi-queue cards, where (generally) data from any
Ethernet port may be sent to any queue.
They were historically represented in DPDK as a single port.
However, the new NFB-200G2QL card employs an addon cable which allows to connect
However, the new NFB-200G2QL card employs an add-on cable which allows to connect
it to two physical PCI-E slots at the same time (see the diagram below).
This is done to allow 200 Gbps of traffic to be transferred through the PCI-E
bus (note that a single PCI-E 3.0 x16 slot provides only 125 Gbps theoretical

View File

@ -40,7 +40,7 @@ actual MAC address: ``00:64:74:61:70:[00-FF]``.
--vdev=net_tap0,mac="00:64:74:61:70:11"
The MAC address will have a user value passed as string. The MAC address is in
format with delimeter ``:``. The string is byte converted to hex and you get
format with delimiter ``:``. The string is byte converted to hex and you get
the actual MAC address: ``00:64:74:61:70:11``.
It is possible to specify a remote netdevice to capture packets from by adding

View File

@ -4,7 +4,7 @@
NXP QorIQ DPAA Board Support Package
====================================
This doc has information about steps to setup QorIq dpaa
This doc has information about steps to setup QorIQ dpaa
based layerscape platform and information about common offload
hw block drivers of **NXP QorIQ DPAA** SoC family.
@ -38,7 +38,7 @@ Common Offload HW Block Drivers
Steps To Setup Platform
-----------------------
There are four main pre-requisities for executing DPAA PMD on a DPAA
There are four main pre-requisites for executing DPAA PMD on a DPAA
compatible board:
1. **ARM 64 Tool Chain**

View File

@ -4,7 +4,7 @@
NXP QorIQ DPAA2 Board Support Package
=====================================
This doc has information about steps to setup NXP QoriQ DPAA2 platform
This doc has information about steps to setup NXP QorIQ DPAA2 platform
and information about common offload hw block drivers of
**NXP QorIQ DPAA2** SoC family.
@ -48,7 +48,7 @@ Common Offload HW Block Drivers
Steps To Setup Platform
-----------------------
There are four main pre-requisities for executing DPAA2 PMD on a DPAA2
There are four main pre-requisites for executing DPAA2 PMD on a DPAA2
compatible board:
1. **ARM 64 Tool Chain**

View File

@ -78,7 +78,7 @@ From the application point of view, each instance of a bbdev device consists of
one or more queues identified by queue IDs. While different devices may have
different capabilities (e.g. support different operation types), all queues on
a device support identical configuration possibilities. A queue is configured
for only one type of operation and is configured at initializations time.
for only one type of operation and is configured at initialization time.
When an operation is enqueued to a specific queue ID, the result is dequeued
from the same queue ID.
@ -678,7 +678,7 @@ bbdev framework, by giving a sample code performing a loop-back operation with a
baseband processor capable of transceiving data packets.
The following sample C-like pseudo-code shows the basic steps to encode several
buffers using (**sw_trubo**) bbdev PMD.
buffers using (**sw_turbo**) bbdev PMD.
.. code-block:: c

View File

@ -17,7 +17,7 @@ Device Creation
Physical compression devices are discovered during the bus probe of the EAL function
which is executed at DPDK initialization, based on their unique device identifier.
For eg. PCI devices can be identified using PCI BDF (bus/bridge, device, function).
For e.g. PCI devices can be identified using PCI BDF (bus/bridge, device, function).
Specific physical compression devices, like other physical devices in DPDK can be
white-listed or black-listed using the EAL command line options.
@ -379,7 +379,7 @@ using priv_xform would look like:
setup op->m_src and op->m_dst;
}
num_enqd = rte_compressdev_enqueue_burst(cdev_id, 0, comp_ops, NUM_OPS);
/* wait for this to complete before enqueing next*/
/* wait for this to complete before enqueuing next*/
do {
num_deque = rte_compressdev_dequeue_burst(cdev_id, 0 , &processed_ops, NUM_OPS);
} while (num_dqud < num_enqd);
@ -526,7 +526,7 @@ An example pseudocode to set up and process a stream having NUM_CHUNKS with each
op->src.length = CHUNK_LEN;
op->input_chksum = 0;
num_enqd = rte_compressdev_enqueue_burst(cdev_id, 0, &op[i], 1);
/* wait for this to complete before enqueing next*/
/* wait for this to complete before enqueuing next*/
do {
num_deqd = rte_compressdev_dequeue_burst(cdev_id, 0 , &processed_ops, 1);
} while (num_deqd < num_enqd);

View File

@ -14,7 +14,7 @@ and AEAD symmetric and asymmetric Crypto operations.
Design Principles
-----------------
The cryptodev library follows the same basic principles as those used in DPDKs
The cryptodev library follows the same basic principles as those used in DPDK's
Ethernet Device framework. The Crypto framework provides a generic Crypto device
framework which supports both physical (hardware) and virtual (software) Crypto
devices as well as a generic Crypto API which allows Crypto devices to be
@ -48,7 +48,7 @@ From the command line using the --vdev EAL option
* If DPDK application requires multiple software crypto PMD devices then required
number of ``--vdev`` with appropriate libraries are to be added.
* An Application with crypto PMD instaces sharing the same library requires unique ID.
* An Application with crypto PMD instances sharing the same library requires unique ID.
Example: ``--vdev 'crypto_aesni_mb0' --vdev 'crypto_aesni_mb1'``
@ -382,7 +382,7 @@ Operation Management and Allocation
The cryptodev library provides an API set for managing Crypto operations which
utilize the Mempool Library to allocate operation buffers. Therefore, it ensures
that the crytpo operation is interleaved optimally across the channels and
that the crypto operation is interleaved optimally across the channels and
ranks for optimal processing.
A ``rte_crypto_op`` contains a field indicating the pool that it originated from.
When calling ``rte_crypto_op_free(op)``, the operation returns to its original pool.
@ -586,7 +586,7 @@ Sample code
There are various sample applications that show how to use the cryptodev library,
such as the L2fwd with Crypto sample application (L2fwd-crypto) and
the IPSec Security Gateway application (ipsec-secgw).
the IPsec Security Gateway application (ipsec-secgw).
While these applications demonstrate how an application can be created to perform
generic crypto operation, the required complexity hides the basic steps of
@ -767,7 +767,7 @@ using one of the crypto PMDs available in DPDK.
/*
* Dequeue the crypto operations until all the operations
* are proccessed in the crypto device.
* are processed in the crypto device.
*/
uint16_t num_dequeued_ops, total_num_dequeued_ops = 0;
do {
@ -846,7 +846,7 @@ the order in which the transforms are passed indicates the order of the chaining
Not all asymmetric crypto xforms are supported for chaining. Currently supported
asymmetric crypto chaining is Diffie-Hellman private key generation followed by
public generation. Also, currently API does not support chaining of symmetric and
asymmetric crypto xfroms.
asymmetric crypto xforms.
Each xform defines specific asymmetric crypto algo. Currently supported are:
* RSA

View File

@ -216,8 +216,6 @@ Objects
Misc
^^^^
* rte.doc.mk: Documentation in the development kit framework
* rte.gnuconfigure.mk: Build an application that is configure-based.
* rte.subdir.mk: Build several directories in the development kit framework.
@ -249,7 +247,7 @@ Creates the following symbol:
Which ``dpdk-pmdinfogen`` scans for. Using this information other relevant
bits of data can be exported from the object file and used to produce a
hardware support description, that ``dpdk-pmdinfogen`` then encodes into a
json formatted string in the following format:
JSON formatted string in the following format:
.. code-block:: c

View File

@ -423,6 +423,6 @@ References
1- EFD is based on collaborative research work between Intel and
Carnegie Mellon University (CMU), interested readers can refer to the paper
“Scaling Up Clustered Network Appliances with ScaleBricks;” Dong Zhou et al.
"Scaling Up Clustered Network Appliances with ScaleBricks" Dong Zhou et al.
at SIGCOMM 2015 (`http://conferences.sigcomm.org/sigcomm/2015/pdf/papers/p241.pdf`)
for more information.

View File

@ -147,14 +147,13 @@ A default validator callback is provided by EAL, which can be enabled with a
``--socket-limit`` command-line option, for a simple way to limit maximum amount
of memory that can be used by DPDK application.
.. note::
In multiprocess scenario, all related processes (i.e. primary process, and
secondary processes running with the same prefix) must be in the same memory
modes. That is, if primary process is run in dynamic memory mode, all of its
secondary processes must be run in the same mode. The same is applicable to
``--single-file-segments`` command-line option - both primary and secondary
processes must shared this mode.
.. warning::
Memory subsystem uses DPDK IPC internally, so memory allocations/callbacks
and IPC must not be mixed: it is not safe to allocate/free memory inside
memory-related or IPC callbacks, and it is not safe to use IPC inside
memory-related callbacks. See chapter
:ref:`Multi-process Support <Multi-process_Support>` for more details about
DPDK IPC.
+ Legacy memory mode
@ -450,6 +449,28 @@ Those TLS include *_cpuset* and *_socket_id*:
* *_socket_id* stores the NUMA node of the CPU set. If the CPUs in CPU set belong to different NUMA node, the *_socket_id* will be set to SOCKET_ID_ANY.
Control Thread API
~~~~~~~~~~~~~~~~~~
It is possible to create Control Threads using the public API
``rte_ctrl_thread_create()``.
Those threads can be used for management/infrastructure tasks and are used
internally by DPDK for multi process support and interrupt handling.
Those threads will be scheduled on CPUs part of the original process CPU
affinity from which the dataplane and service lcores are excluded.
For example, on a 8 CPUs system, starting a dpdk application with -l 2,3
(dataplane cores), then depending on the affinity configuration which can be
controlled with tools like taskset (Linux) or cpuset (FreeBSD),
- with no affinity configuration, the Control Threads will end up on
0-1,4-7 CPUs.
- with affinity restricted to 2-4, the Control Threads will end up on
CPU 4.
- with affinity restricted to 2-3, the Control Threads will end up on
CPU 2 (master lcore, which is the default when no CPU is available).
.. _known_issue_label:
Known Issues
@ -635,7 +656,7 @@ The most important fields in the structure and how they are used are described b
Malloc heap is a doubly-linked list, where each element keeps track of its
previous and next elements. Due to the fact that hugepage memory can come and
go, neighbouring malloc elements may not necessarily be adjacent in memory.
go, neighboring malloc elements may not necessarily be adjacent in memory.
Also, since a malloc element may span multiple pages, its contents may not
necessarily be IOVA-contiguous either - each malloc element is only guaranteed
to be virtually contiguous.

View File

@ -157,7 +157,7 @@ The servicing_weight member of struct rte_event_eth_rx_adapter_queue_conf
is applicable when the adapter uses a service core function. The application
has to enable Rx queue interrupts when configuring the ethernet device
using the ``rte_eth_dev_configure()`` function and then use a servicing_weight
of zero when addding the Rx queue to the adapter.
of zero when adding the Rx queue to the adapter.
The adapter creates a thread blocked on the interrupt, on an interrupt this
thread enqueues the port id and the queue id to a ring buffer. The adapter
@ -175,9 +175,9 @@ Rx Callback for SW Rx Adapter
For SW based packet transfers, i.e., when the
``RTE_EVENT_ETH_RX_ADAPTER_CAP_INTERNAL_PORT`` is not set in the adapter's
capabilities flags for a particular ethernet device, the service function
temporarily enqueues mbufs to an event buffer before batch enqueueing these
temporarily enqueues mbufs to an event buffer before batch enqueuing these
to the event device. If the buffer fills up, the service function stops
dequeueing packets from the ethernet device. The application may want to
dequeuing packets from the ethernet device. The application may want to
monitor the buffer fill level and instruct the service function to selectively
enqueue packets to the event device. The application may also use some other
criteria to decide which packets should enter the event device even when

View File

@ -42,7 +42,7 @@ The rte_event structure contains the following metadata fields, which the
application fills in to have the event scheduled as required:
* ``flow_id`` - The targeted flow identifier for the enq/deq operation.
* ``event_type`` - The source of this event, eg RTE_EVENT_TYPE_ETHDEV or CPU.
* ``event_type`` - The source of this event, e.g. RTE_EVENT_TYPE_ETHDEV or CPU.
* ``sub_event_type`` - Distinguishes events inside the application, that have
the same event_type (see above)
* ``op`` - This field takes one of the RTE_EVENT_OP_* values, and tells the
@ -265,7 +265,7 @@ Linking Queues and Ports
The final step is to "wire up" the ports to the queues. After this, the
eventdev is capable of scheduling events, and when cores request work to do,
the correct events are provided to that core. Note that the RX core takes input
from eg: a NIC so it is not linked to any eventdev queues.
from e.g.: a NIC so it is not linked to any eventdev queues.
Linking all workers to atomic queues, and the TX core to the single-link queue
can be achieved like this:
@ -276,7 +276,7 @@ can be achieved like this:
uint8_t tx_port_id = 5;
uint8_t atomic_qs[] = {0, 1};
uint8_t single_link_q = 2;
uin8t_t priority = RTE_EVENT_DEV_PRIORITY_NORMAL;
uint8_t priority = RTE_EVENT_DEV_PRIORITY_NORMAL;
for(int worker_port_id = 1; worker_port_id <= 4; worker_port_id++) {
int links_made = rte_event_port_link(dev_id, worker_port_id, atomic_qs, NULL, 2);

View File

@ -191,3 +191,22 @@ Header fields deciding if packets are neighbors include:
ignore IPv4 ID fields for the packets whose DF bit is 1.
Additionally, packets which have different value of DF bit can't
be merged.
GRO Library Limitations
-----------------------
- GRO library uses MBUF->l2_len/l3_len/l4_len/outer_l2_len/
outer_l3_len/packet_type to get protocol headers for the
input packet, rather than parsing the packet header. Therefore,
before call GRO APIs to merge packets, user applications
must set MBUF->l2_len/l3_len/l4_len/outer_l2_len/outer_l3_len/
packet_type to the same values as the protocol headers of the
packet.
- GRO library doesn't support to process the packets with IPv4
Options or VLAN tagged.
- GRO library just supports to process the packet organized
in a single MBUF. If the input packet consists of multiple
MBUFs (i.e. chained MBUFs), GRO reassembly behaviors are
unknown.

View File

@ -225,7 +225,7 @@ application functions:
``config_promiscusity``:
Called when the user changes the promiscusity state of the KNI
Called when the user changes the promiscuity state of the KNI
interface. For example, when the user runs ``ip link set promisc
[on|off] dev <ifaceX>``. If the user sets this callback function to
NULL, but sets the ``port_id`` field to a value other than -1, a default

View File

@ -477,22 +477,22 @@ Create a bonded device in round robin mode with two slaves specified by their PC
.. code-block:: console
$RTE_TARGET/app/testpmd -l 0-3 -n 4 --vdev 'net_bonding0,mode=0, slave=0000:00a:00.01,slave=0000:004:00.00' -- --port-topology=chained
$RTE_TARGET/app/testpmd -l 0-3 -n 4 --vdev 'net_bonding0,mode=0,slave=0000:0a:00.01,slave=0000:04:00.00' -- --port-topology=chained
Create a bonded device in round robin mode with two slaves specified by their PCI address and an overriding MAC address:
.. code-block:: console
$RTE_TARGET/app/testpmd -l 0-3 -n 4 --vdev 'net_bonding0,mode=0, slave=0000:00a:00.01,slave=0000:004:00.00,mac=00:1e:67:1d:fd:1d' -- --port-topology=chained
$RTE_TARGET/app/testpmd -l 0-3 -n 4 --vdev 'net_bonding0,mode=0,slave=0000:0a:00.01,slave=0000:04:00.00,mac=00:1e:67:1d:fd:1d' -- --port-topology=chained
Create a bonded device in active backup mode with two slaves specified, and a primary slave specified by their PCI addresses:
.. code-block:: console
$RTE_TARGET/app/testpmd -l 0-3 -n 4 --vdev 'net_bonding0,mode=1, slave=0000:00a:00.01,slave=0000:004:00.00,primary=0000:00a:00.01' -- --port-topology=chained
$RTE_TARGET/app/testpmd -l 0-3 -n 4 --vdev 'net_bonding0,mode=1,slave=0000:0a:00.01,slave=0000:04:00.00,primary=0000:0a:00.01' -- --port-topology=chained
Create a bonded device in balance mode with two slaves specified by their PCI addresses, and a transmission policy of layer 3 + 4 forwarding:
.. code-block:: console
$RTE_TARGET/app/testpmd -l 0-3 -n 4 --vdev 'net_bonding0,mode=2, slave=0000:00a:00.01,slave=0000:004:00.00,xmit_policy=l34' -- --port-topology=chained
$RTE_TARGET/app/testpmd -l 0-3 -n 4 --vdev 'net_bonding0,mode=2,slave=0000:0a:00.01,slave=0000:04:00.00,xmit_policy=l34' -- --port-topology=chained

View File

@ -195,4 +195,4 @@ References
`http://www.ietf.org/rfc/rfc1519 <http://www.ietf.org/rfc/rfc1519>`_
* Pankaj Gupta, Algorithms for Routing Lookups and Packet Classification, PhD Thesis, Stanford University,
2000 (`http://klamath.stanford.edu/~pankaj/thesis/ thesis_1sided.pdf <http://klamath.stanford.edu/~pankaj/thesis/%20thesis_1sided.pdf>`_ )
2000 (`http://klamath.stanford.edu/~pankaj/thesis/thesis_1sided.pdf <http://klamath.stanford.edu/~pankaj/thesis/thesis_1sided.pdf>`_ )

View File

@ -25,7 +25,7 @@ individual device. Since the metrics library is self-contained, the only
restriction on port numbers is that they are less than ``RTE_MAX_ETHPORTS``
- there is no requirement for the ports to actually exist.
Initialising the library
Initializing the library
------------------------
Before the library can be used, it has to be initialized by calling

View File

@ -176,7 +176,7 @@ Some of these are documented below:
* The use of function pointers between multiple processes running based of different compiled binaries is not supported,
since the location of a given function in one process may be different to its location in a second.
This prevents the librte_hash library from behaving properly as in a multi-threaded instance,
This prevents the librte_hash library from behaving properly as in a multi-process instance,
since it uses a pointer to the hash function internally.
To work around this issue, it is recommended that multi-process applications perform the hash calculations by directly calling
@ -263,9 +263,9 @@ To send a request, a message descriptor ``rte_mp_msg`` must be populated.
Additionally, a ``timespec`` value must be specified as a timeout, after which
IPC will stop waiting and return.
For synchronous synchronous requests, the ``rte_mp_reply`` descriptor must also
be created. This is where the responses will be stored. The list of fields that
will be populated by IPC are as follows:
For synchronous requests, the ``rte_mp_reply`` descriptor must also be created.
This is where the responses will be stored.
The list of fields that will be populated by IPC are as follows:
* ``nb_sent`` - number indicating how many requests were sent (i.e. how many
peer processes were active at the time of the request).
@ -273,7 +273,7 @@ will be populated by IPC are as follows:
those peer processes that were active at the time of request, how many have
replied)
* ``msgs`` - pointer to where all of the responses are stored. The order in
which responses appear is undefined. Whendoing sycnrhonous requests, this
which responses appear is undefined. When doing synchronous requests, this
memory must be freed by the requestor after request completes!
For asynchronous requests, a function pointer to the callback function must be
@ -309,6 +309,13 @@ If a response is required, a new ``rte_mp_msg`` message descriptor must be
constructed and sent via ``rte_mp_reply()`` function, along with ``peer``
pointer. The resulting response will then be delivered to the correct requestor.
.. warning::
Simply returning a value when processing a request callback will not send a
response to the request - it must always be explicitly sent even in case
of errors. Implementation of error signalling rests with the application,
there is no built-in way to indicate success or error for a request. Failing
to do so will cause the requestor to time out while waiting on a response.
Misc considerations
~~~~~~~~~~~~~~~~~~~~~~~~
@ -318,6 +325,11 @@ supported. However, since sending messages (not requests) does not involve an
IPC thread, sending messages while processing another message or request is
supported.
Since the memory sybsystem uses IPC internally, memory allocations and IPC must
not be mixed: it is not safe to use IPC inside a memory-related callback, nor is
it safe to allocate/free memory inside IPC callbacks. Attempting to do so may
lead to a deadlock.
Asynchronous request callbacks may be triggered either from IPC thread or from
interrupt thread, depending on whether the request has timed out. It is
therefore suggested to avoid waiting for interrupt-based events (such as alarms)

Some files were not shown because too many files have changed in this diff Show More