numam-dpdk/doc/guides/prog_guide
Wei Dai a4996bd89c ethdev: new Rx/Tx offloads API
This patch check if a input requested offloading is valid or not.
Any reuqested offloading must be supported in the device capabilities.
Any offloading is disabled by default if it is not set in the parameter
dev_conf->[rt]xmode.offloads to rte_eth_dev_configure() and
[rt]x_conf->offloads to rte_eth_[rt]x_queue_setup().
If any offloading is enabled in rte_eth_dev_configure() by application,
it is enabled on all queues no matter whether it is per-queue or
per-port type and no matter whether it is set or cleared in
[rt]x_conf->offloads to rte_eth_[rt]x_queue_setup().
If a per-queue offloading hasn't be enabled in rte_eth_dev_configure(),
it can be enabled or disabled for individual queue in
ret_eth_[rt]x_queue_setup().
A new added offloading is the one which hasn't been enabled in
rte_eth_dev_configure() and is reuqested to be enabled in
rte_eth_[rt]x_queue_setup(), it must be per-queue type,
otherwise trigger an error log.
The underlying PMD must be aware that the requested offloadings
to PMD specific queue_setup() function only carries those
new added offloadings of per-queue type.

This patch can make above such checking in a common way in rte_ethdev
layer to avoid same checking in underlying PMD.

This patch assumes that all PMDs in 18.05-rc2 have already
converted to offload API defined in 17.11 . It also assumes
that all PMDs can return correct offloading capabilities
in rte_eth_dev_infos_get().

In the beginning of [rt]x_queue_setup() of underlying PMD,
add offloads = [rt]xconf->offloads |
dev->data->dev_conf.[rt]xmode.offloads; to keep same as offload API
defined in 17.11 to avoid upper application broken due to offload
API change.
PMD can use the info that input [rt]xconf->offloads only carry
the new added per-queue offloads to do some optimization or some
code change on base of this patch.

Signed-off-by: Wei Dai <wei.dai@intel.com>
Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
Signed-off-by: Qi Zhang <qi.z.zhang@intel.com>
2018-05-14 22:31:51 +01:00
..
img doc: add compressdev library guide 2018-05-10 17:46:20 +01:00
bbdev.rst bbdev: change names of baseband devices 2018-05-10 17:46:20 +01:00
bpf_lib.rst doc: add BPF library guide 2018-05-12 00:38:19 +02:00
build_app.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
compressdev.rst doc: add compressdev library guide 2018-05-10 17:46:20 +01:00
cryptodev_lib.rst doc: add private data info in crypto guide 2018-04-23 18:20:09 +01:00
dev_kit_build_system.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
dev_kit_root_make_help.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
efd_lib.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
env_abstraction_layer.rst doc: fix a typo in the EAL guide 2018-04-23 01:47:59 +02:00
event_crypto_adapter.rst doc: add event crypto adapter guide 2018-05-10 14:08:57 +02:00
event_ethernet_rx_adapter.rst eventdev: add Rx timestamp 2018-04-16 10:04:58 +02:00
event_timer_adapter.rst doc: add event timer adapter guide 2018-04-16 11:04:46 +02:00
eventdev.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
ext_app_lib_make_help.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
extend_dpdk.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
flow_classify_lib.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
generic_receive_offload_lib.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
generic_segmentation_offload_lib.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
glossary.rst mbuf: remove control mbuf 2018-04-11 23:40:40 +02:00
hash_lib.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
index.rst doc: add BPF library guide 2018-05-12 00:38:19 +02:00
intro.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
ip_fragment_reassembly_lib.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
kernel_nic_interface.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
link_bonding_poll_mode_drv_lib.rst net/bonding: support flow API 2018-04-27 17:34:42 +01:00
lpm6_lib.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
lpm_lib.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
mbuf_lib.rst mbuf: remove control mbuf 2018-04-11 23:40:40 +02:00
member_lib.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
mempool_lib.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
metrics_lib.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
multi_proc_support.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
overview.rst mbuf: remove control mbuf 2018-04-11 23:40:40 +02:00
packet_classif_access_ctrl.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
packet_distrib_lib.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
packet_framework.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
pdump_lib.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
perf_opt_guidelines.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
poll_mode_drv.rst ethdev: new Rx/Tx offloads API 2018-05-14 22:31:51 +01:00
port_hotplug_framework.rst ethdev: remove detachable device flag 2017-10-26 02:33:01 +02:00
power_man.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
profile_app.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
qos_framework.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
rawdev.rst doc: fix a typo in rawdev guide 2018-04-23 01:47:59 +02:00
reorder_lib.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
ring_lib.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
rte_flow.rst ethdev: add shared counter to flow API 2018-04-27 18:00:57 +01:00
rte_security.rst security: support user data retrieval 2018-01-20 16:10:20 +01:00
service_cores.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
source_org.rst ethdev: rename folder to library name 2018-04-27 18:01:00 +01:00
switch_representation.rst doc: add switch representation documentation 2018-04-27 18:00:56 +01:00
thread_safety_dpdk_functions.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
timer_lib.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
traffic_management.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00
traffic_metering_and_policing.rst ethdev: rename folder to library name 2018-04-27 18:01:00 +01:00
vhost_lib.rst doc/vhost: update zero copy performance tip 2018-05-14 22:26:36 +01:00
writing_efficient_code.rst doc: convert Intel license headers to SPDX tags 2018-02-06 23:27:08 +01:00