Phil Yang [Fri, 12 Oct 2018 09:34:55 +0000 (17:34 +0800)]
app/testpmd: fix vdev socket initialization
The cmdline settings of port-numa-config and rxring-numa-config have
been flushed by the following init_config. If we don't configure the
port-numa-config, the virtual device will allocate the device ports to
socket 0. It will cause failure when the socket 0 is unavailable.
Now that logging of initialization is controlled by dynamic debug
level, remove the #ifdef for RTE_LIBRTE_QEDE_DEBUG_INIT since that
config option does not exist in common_base and is not documented.
Yongseok Koh [Fri, 12 Oct 2018 08:42:33 +0000 (08:42 +0000)]
net/mlx5: support multiple groups and jump action
rte_flow has 'group' attribute and 'jump' action in order to support
multiple groups. This feature is known as multi-table support ('chain' in
linux TC flower) in general because a group means a table of flows. Example
commands are:
flow create 0 transfer priority 1 ingress
pattern eth / vlan vid is 100 / end
actions jump group 1 / end
flow create 0 transfer priority 1 ingress
pattern eth / vlan vid is 200 / end
actions jump group 2 / end
flow create 0 transfer group 1 priority 2 ingress
pattern eth / vlan vid is 100 /
ipv4 dst spec 192.168.40.0 dst prefix 24 / end
actions drop / end
flow create 0 transfer group 1 priority 2 ingress
pattern end
actions of_pop_vlan / port_id id 1 / end
flow create 0 transfer group 2 priority 2 ingress
pattern eth / vlan vid is 200 /
ipv4 dst spec 192.168.40.0 dst prefix 24 / end
actions of_pop_vlan / port_id id 2 / end
flow create 0 transfer group 2 priority 2 ingress
pattern end
actions port_id id 2 / end
With theses flows, if a packet having vlan 200 and src_ip as 192.168.40.1,
this packet will firstly hit the 1st flow. Then it will hit the 5th flow
because of the 'jump' action. As a result, the packet will be forwarded to
port 2 (VF representor) with vlan tag being stripped off. If the packet had
vlan 100 instead, it would be dropped by the 3rd flow.
Igor Russkikh [Fri, 12 Oct 2018 11:09:14 +0000 (11:09 +0000)]
net/atlantic: implement firmware operations
AQC NICs comes in fields with two major
FW generations: 1x and 3x.
This is part of linux atlantic driver shared code,
responsible for internal NIC firmware interactions,
including link management ops, FW initialization,
various lifecycle features.
Signed-off-by: Igor Russkikh <igor.russkikh@aquantia.com> Signed-off-by: Pavel Belous <pavel.belous@aquantia.com>
John Daley [Wed, 10 Oct 2018 22:11:31 +0000 (15:11 -0700)]
net/enic: fix counter action
- track whether counter DMAs are active or not so they can be stopped if
needed before DMA memory is freed
- fix counter DMA shut-down by changing vnic_dev_counter_dma_cfg() to
take the number of counters to DMA instead of high counter index and
use num counters = 0 to shut off DMAs
- remove unnecessary checks that DMA counter memory is valid and that
counter DMAs are in use
- change the minimum DMA period to match what 1400 series adapter is
capable of
- fix comments and change a couple variable names to make more sense
Fixes: 86df6c4e2fce ("net/enic: support flow counter action") Signed-off-by: John Daley <johndale@cisco.com> Reviewed-by: Hyong Youb Kim <hyonkim@cisco.com>
Fiona Trahe [Thu, 11 Oct 2018 17:14:05 +0000 (18:14 +0100)]
common/qat: fix failure to create PMD
If QAT crypto pmd failed to be created due to reaching MAX
cryptodevs it prevented QAT comp PMD being created. And vice versa.
Change to warning in these cases and allow the other PMD to be created.
Fixes: c0c90bc4cade ("compress/qat: add create and destroy functions") Cc: stable@dpdk.org Signed-off-by: Fiona Trahe <fiona.trahe@intel.com> Acked-by: Tomasz Cel <tomaszx.cel@intel.com>
Fan Zhang [Mon, 15 Oct 2018 11:28:16 +0000 (12:28 +0100)]
cryptodev: fix library version
This patch fixes the cryptodev library version number that was
missed updating in DPDK 18.08.
Fixes: a4493be5bdfa ("cryptodev: replace bus specific struct with generic dev") Cc: stable@dpdk.org Signed-off-by: Fan Zhang <roy.fan.zhang@intel.com> Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
Hemant Agrawal [Fri, 12 Oct 2018 14:40:54 +0000 (20:10 +0530)]
crypto/caam_jr: add security offload
This patch provides the support for protocol offload
to the hardware. following security operations are
added:
- session_create
- session_destroy
- capabilities_get
Gagandeep Singh [Fri, 12 Oct 2018 14:40:51 +0000 (20:10 +0530)]
crypto/caam_jr: add enqueue/dequeue operations
This patch add support for :
1. creating run time sec hw decriptors for a given request.
2. enqueue operation to the caam jr ring
3. dequeue operation from the caam jr ring in poll mode
4. creating a crypto protocol descriptor for session - first time.
Gagandeep Singh [Fri, 12 Oct 2018 14:40:45 +0000 (20:10 +0530)]
crypto/caam_jr: add UIO specific operations
caam_jr need support from kernel caam driver for
job ring initialisation. So to access register space
for job ring and allow re configure and map to userspace
UIO interface is used. This also allows to handle the
caam interrupts from the user space.
Gagandeep Singh [Fri, 12 Oct 2018 14:40:44 +0000 (20:10 +0530)]
crypto/caam_jr: add routines to configure HW
This patch add routines for configuring the hw
to support various features.
These routines will be used by the PMD ops.
The patch also defines structure and macros used
to access hw capabilities.
Gagandeep Singh [Fri, 12 Oct 2018 14:40:42 +0000 (20:10 +0530)]
crypto/caam_jr: introduce basic driver
The caam_jr poll mode crypto driver is supported for
NXP SEC 4.x+ (CAAM) hardware accelerator.
This driver is by default supported on LE platforms,
if it is used on BE platforms like LS104X,
config option CONFIG_RTE_LIBRTE_PMD_CAAM_JR_BE can be
enabled.
This patch add skeleton for caam jobring driver
with probe and uintialisation functions
Fan Zhang [Wed, 10 Oct 2018 11:04:41 +0000 (12:04 +0100)]
crypto/aesni_mb: support AES-GCM algorithm
This patch updates the current AESNI-MB PMD with added AES-GCM
algorithm support. The patch includes the necessary changes
to the code including the capability update, control and data
patch changes for the AES-GCM algorithm support.
Signed-off-by: Fan Zhang <roy.fan.zhang@intel.com> Acked-by: Arek Kusztal <arkadiuszx.kusztal@intel.com>
Tomasz Cel [Tue, 9 Oct 2018 16:08:10 +0000 (18:08 +0200)]
crypto/qat: support AES-CMAC
This patch add AES-CMAC support. CMAC is a keyed hash function
that is based on a symmetric key block cipher. It is One-Key
CBC MAC improvement over XCBC-MAC. RFC 4493. NIST SP 800-38B.
Signed-off-by: Tomasz Cel <tomaszx.cel@intel.com> Signed-off-by: Arek Kusztal <arkadiuszx.kusztal@intel.com> Acked-by: Fiona Trahe <fiona.trahe@intel.com>
Junxiao Shi [Tue, 9 Oct 2018 14:16:23 +0000 (10:16 -0400)]
cryptodev: fix pool element size for undefined operation
The documentation of rte_crypto_op_pool_create indicates that
specifying RTE_CRYPTO_OP_TYPE_UNDEFINED would create a pool that
supports all operation types. This change makes the code
consistent with documentation.
Fixes: c0f87eb5252b ("cryptodev: change burst API to be crypto op oriented") Cc: stable@dpdk.org Signed-off-by: Junxiao Shi <git@mail1.yoursunny.com> Acked-by: Akhil Goyal <akhil.goyal@nxp.com>
event dpaa2 device support both ethernet as well as
crypto queues to be attached to it. eth_rx_adapter
provide infrastructure to attach ethernet queues and
crypto_adapter provide support for crypto queues.
This patch add support for dpaa2_eventdev to attach
dpaa2_sec queues.
dpaa2_sec hw queues can be attached to a hw dpaa2 event
device and the application can configure the event
crypto adapter to access the dpaa2_sec packets using
hardware events.
This patch defines APIs which can be used by the dpaa2
event device to attach/detach dpaa2_sec queues.
Anoob Joseph [Tue, 9 Oct 2018 09:07:39 +0000 (14:37 +0530)]
crypto/octeontx: add global resource init
Adding initialization of global resources. This will be saved as
metadata in cptvf and would be used by common code. Exit path for
failure case is also added along with the new routines.
Anoob Joseph [Tue, 9 Oct 2018 09:07:38 +0000 (14:37 +0530)]
common/cpt: add PMD ops helper functions
Adding pmd ops helper functions. Control path accessed APIs would be
added as helper functions. Adding microcode defined macros etc as
dependencies to the helper functions.
Anoob Joseph [Tue, 9 Oct 2018 09:07:34 +0000 (14:37 +0530)]
crypto/octeontx: add PMD skeleton
Adding OCTEON TX crypto PMD skeleton. Updating the maintainers files to
claim responsibility. Also enabling driver by default by adding the
component in common_base.
Zyta Szpak [Mon, 27 Aug 2018 12:22:52 +0000 (14:22 +0200)]
crypto/mvsam: support scatter gather
The patch adds support for chained source mbufs given
to crypto operations. The crypto engine accepts source buffer
containing a number of segments. The destination buffer
stays the same - always one segment.
On decryption, EIP engine will look for digest at 'auth_icv_offset'
offset in SRC buffer.It must be placed in the last segment and the
offset must be set to reach digest in the last segment.
If application doesn't placed digest in source mbuf, driver try to
copy it to a last segment.
Thomas Monjalon [Wed, 19 Sep 2018 23:37:14 +0000 (01:37 +0200)]
eal: allow probing a device again
In the devargs syntax for device representors, it is possible to add
several devices at once: -w dbdf,representor=[0-3]
It will become a more frequent case when introducing wildcards
and ranges in the new devargs syntax.
If a devargs string is provided for probing, and updated with a bigger
range for a new probing, then we do not want it to fail because
part of this range was already probed previously.
There can be new ports to create from an existing rte_device.
That's why the check for an already probed device
is moved as bus responsibility.
In the case of vdev, a global check is kept in insert_vdev(),
assuming that a vdev will always have only one port.
In the case of ifpga and vmbus, already probed devices are checked.
In the case of NXP buses, the probing is done only once (no hotplug),
though a check is added at bus level for consistency.
In the case of PCI, a driver flag is added to allow PMD probing again.
Only the PMD knows the ports attached to one rte_device.
As another consequence of being able to probe in several steps,
the field rte_device.devargs must not be considered as a full
representation of the rte_device, but only the latest probing args.
Anyway, the field rte_device.devargs is used only for probing.
Signed-off-by: Thomas Monjalon <thomas@monjalon.net> Reviewed-by: Andrew Rybchenko <arybchenko@solarflare.com> Tested-by: Andrew Rybchenko <arybchenko@solarflare.com> Acked-by: Shreyansh Jain <shreyansh.jain@nxp.com>
Thomas Monjalon [Tue, 25 Sep 2018 20:55:27 +0000 (22:55 +0200)]
eal: add function to query device status
The function rte_dev_is_probed() is added in order to improve semantic
and enforce proper check of the probing status of a device.
It will answer this rte_device query:
Is it already successfully probed or not?
Signed-off-by: Thomas Monjalon <thomas@monjalon.net> Reviewed-by: Andrew Rybchenko <arybchenko@solarflare.com> Tested-by: Andrew Rybchenko <arybchenko@solarflare.com>
Thomas Monjalon [Tue, 25 Sep 2018 20:55:27 +0000 (22:55 +0200)]
drivers/bus: move driver assignment to end of probing
The PCI mapping requires to know the PCI driver to use,
even before the probing is done. That's why the PCI driver is
referenced early inside the PCI device structure. See
commit 1d20a073fa5e ("bus/pci: reference driver structure before mapping")
However the rte_driver does not need to be referenced in rte_device
before the device probing is done.
By moving back this assignment at the end of the device probing,
it becomes possible to make clear the status of a rte_device.
Signed-off-by: Thomas Monjalon <thomas@monjalon.net> Reviewed-by: Andrew Rybchenko <arybchenko@solarflare.com> Tested-by: Andrew Rybchenko <arybchenko@solarflare.com> Reviewed-by: Rosen Xu <rosen.xu@intel.com>