patches for DPDK stable branches
 help / color / mirror / Atom feed
* [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3
@ 2018-05-06  6:36 Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'mbuf: improve tunnel Tx offloads " Yuanhan Liu
                   ` (24 more replies)
  0 siblings, 25 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Thomas Monjalon; +Cc: Olivier Matz, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From 0f01bfeeebccfdb1a1f1163e50a7c17fb241d15a Mon Sep 17 00:00:00 2001
From: Thomas Monjalon <thomas@monjalon.net>
Date: Fri, 20 Apr 2018 01:39:52 +0200
Subject: [PATCH] mbuf: fix Tx checksum offload API doc

[ upstream commit f00dcb7b0a74928b8b846f73b37386d7b1bb4869 ]

When introducing rte_eth_tx_prepare(), the constraints on checksum
pre-filling for Tx offloads were relaxed because implemented in
the PMDs with rte_net_intel_cksum_flags_prepare() helper.
As a consequence, these old requirements are removed for:
	- PKT_TX_OUTER_IP_CKSUM
	- PKT_TX_IP_CKSUM
	- PKT_TX_[L4]_CKSUM
	- PKT_TX_TCP_SEG

Not sure SCTP offload is properly implemented though.

A reference to rte_eth_tx_prepare() is added in rte_eth_tx_burst() doc.

Fixes: 609dd68ef14f ("mbuf: enhance the API documentation of offload flags")
Fixes: 4fb7e803eb1a ("ethdev: add Tx preparation")

Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
---
 lib/librte_ether/rte_ethdev.h |  3 +++
 lib/librte_mbuf/rte_mbuf.h    | 16 +++-------------
 2 files changed, 6 insertions(+), 13 deletions(-)

diff --git a/lib/librte_ether/rte_ethdev.h b/lib/librte_ether/rte_ethdev.h
index 2cc2eedf2..eba11ca50 100644
--- a/lib/librte_ether/rte_ethdev.h
+++ b/lib/librte_ether/rte_ethdev.h
@@ -3125,6 +3125,9 @@ static inline int rte_eth_tx_descriptor_status(uint16_t port_id,
  * invoke this function concurrently on the same tx queue without SW lock.
  * @see rte_eth_dev_info_get, struct rte_eth_txconf::txq_flags
  *
+ * @see rte_eth_tx_prepare to perform some prior checks or adjustments
+ * for offloads.
+ *
  * @param port_id
  *   The port identifier of the Ethernet device.
  * @param queue_id
diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h
index 16a6048c2..3966ed11e 100644
--- a/lib/librte_mbuf/rte_mbuf.h
+++ b/lib/librte_mbuf/rte_mbuf.h
@@ -245,12 +245,8 @@ extern "C" {
  *  - set the PKT_TX_TCP_SEG flag in mbuf->ol_flags (this flag implies
  *    PKT_TX_TCP_CKSUM)
  *  - set the flag PKT_TX_IPV4 or PKT_TX_IPV6
- *  - if it's IPv4, set the PKT_TX_IP_CKSUM flag and write the IP checksum
- *    to 0 in the packet
+ *  - if it's IPv4, set the PKT_TX_IP_CKSUM flag
  *  - fill the mbuf offload information: l2_len, l3_len, l4_len, tso_segsz
- *  - calculate the pseudo header checksum without taking ip_len in account,
- *    and set it in the TCP header. Refer to rte_ipv4_phdr_cksum() and
- *    rte_ipv6_phdr_cksum() that can be used as helpers.
  */
 #define PKT_TX_TCP_SEG       (1ULL << 50)
 
@@ -263,9 +259,6 @@ extern "C" {
  *  - fill l2_len and l3_len in mbuf
  *  - set the flags PKT_TX_TCP_CKSUM, PKT_TX_SCTP_CKSUM or PKT_TX_UDP_CKSUM
  *  - set the flag PKT_TX_IPV4 or PKT_TX_IPV6
- *  - calculate the pseudo header checksum and set it in the L4 header (only
- *    for TCP or UDP). See rte_ipv4_phdr_cksum() and rte_ipv6_phdr_cksum().
- *    For SCTP, set the crc field to 0.
  */
 #define PKT_TX_L4_NO_CKSUM   (0ULL << 52) /**< Disable L4 cksum of TX pkt. */
 #define PKT_TX_TCP_CKSUM     (1ULL << 52) /**< TCP cksum of TX pkt. computed by NIC. */
@@ -277,7 +270,6 @@ extern "C" {
  * Offload the IP checksum in the hardware. The flag PKT_TX_IPV4 should
  * also be set by the application, although a PMD will only check
  * PKT_TX_IP_CKSUM.
- *  - set the IP checksum field in the packet to 0
  *  - fill the mbuf offload information: l2_len, l3_len
  */
 #define PKT_TX_IP_CKSUM      (1ULL << 54)
@@ -302,10 +294,8 @@ extern "C" {
 
 /**
  * Offload the IP checksum of an external header in the hardware. The
- * flag PKT_TX_OUTER_IPV4 should also be set by the application, alto ugh
- * a PMD will only check PKT_TX_IP_CKSUM.  The IP checksum field in the
- * packet must be set to 0.
- *  - set the outer IP checksum field in the packet to 0
+ * flag PKT_TX_OUTER_IPV4 should also be set by the application, although
+ * a PMD will only check PKT_TX_OUTER_IP_CKSUM.
  *  - fill the mbuf offload information: outer_l2_len, outer_l3_len
  */
 #define PKT_TX_OUTER_IP_CKSUM   (1ULL << 58)
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'mbuf: improve tunnel Tx offloads API doc' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'app/crypto-perf: fix excess crypto device error' " Yuanhan Liu
                   ` (23 subsequent siblings)
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Thomas Monjalon; +Cc: Olivier Matz, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From 1ca376a0a1c246241632da244a36c459991611ed Mon Sep 17 00:00:00 2001
From: Thomas Monjalon <thomas@monjalon.net>
Date: Fri, 20 Apr 2018 01:53:10 +0200
Subject: [PATCH] mbuf: improve tunnel Tx offloads API doc

[ upstream commit ab66fe0e4a1ca058c4e23efd475e48788c0977e7 ]

Add few details to remind TSO flag, checksum flags and header lengths.

The doxygen syntax for MPLS-in-UDP is fixed.

Fixes: d95188551fa1 ("mbuf: introduce new Tx offload flag for MPLS-in-UDP")

Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
---
 lib/librte_mbuf/rte_mbuf.h | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h
index 3966ed11e..807a8d419 100644
--- a/lib/librte_mbuf/rte_mbuf.h
+++ b/lib/librte_mbuf/rte_mbuf.h
@@ -222,14 +222,17 @@ extern "C" {
 
 /**
  * Bits 45:48 used for the tunnel type.
- * When doing Tx offload like TSO or checksum, the HW needs to configure the
- * tunnel type into the HW descriptors.
+ * The tunnel type must be specified for TSO or checksum on the inner part
+ * of tunnel packets.
+ * These flags can be used with PKT_TX_TCP_SEG for TSO, or PKT_TX_xxx_CKSUM.
+ * The mbuf fields for inner and outer header lengths are required:
+ * outer_l2_len, outer_l3_len, l2_len, l3_len, l4_len and tso_segsz for TSO.
  */
 #define PKT_TX_TUNNEL_VXLAN   (0x1ULL << 45)
 #define PKT_TX_TUNNEL_GRE     (0x2ULL << 45)
 #define PKT_TX_TUNNEL_IPIP    (0x3ULL << 45)
 #define PKT_TX_TUNNEL_GENEVE  (0x4ULL << 45)
-/**< TX packet with MPLS-in-UDP RFC 7510 header. */
+/** TX packet with MPLS-in-UDP RFC 7510 header. */
 #define PKT_TX_TUNNEL_MPLSINUDP (0x5ULL << 45)
 /* add new TX TUNNEL type here */
 #define PKT_TX_TUNNEL_MASK    (0xFULL << 45)
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'app/crypto-perf: fix excess crypto device error' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'mbuf: improve tunnel Tx offloads " Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'examples/l2fwd-crypto: fix the default aead assignments' " Yuanhan Liu
                   ` (22 subsequent siblings)
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Hemant Agrawal; +Cc: Pablo de Lara, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From 6a1c07537dc657043e2f4e0480918e632587bcda Mon Sep 17 00:00:00 2001
From: Hemant Agrawal <hemant.agrawal@nxp.com>
Date: Mon, 2 Apr 2018 21:03:15 +0530
Subject: [PATCH] app/crypto-perf: fix excess crypto device error

[ upstream commit dc476f122d9d80173a3b2b68870dc9f334f296c3 ]

If number of available devices are more than logical core,
there is no need to throw an error.
Just use the less number of devices instead.

Fixes: f8be1786b1b8 ("app/crypto-perf: introduce performance test application")

Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
---
 app/test-crypto-perf/main.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/app/test-crypto-perf/main.c b/app/test-crypto-perf/main.c
index 29373f5b4..8e072fb35 100644
--- a/app/test-crypto-perf/main.c
+++ b/app/test-crypto-perf/main.c
@@ -106,12 +106,12 @@ cperf_initialize_cryptodev(struct cperf_options *opts, uint8_t *enabled_cdevs,
 
 	nb_lcores = rte_lcore_count() - 1;
 
-	if (enabled_cdev_count > nb_lcores) {
-		printf("Number of capable crypto devices (%d) "
-				"has to be less or equal to number of slave "
-				"cores (%d)\n", enabled_cdev_count, nb_lcores);
-		return -EINVAL;
-	}
+	/*
+	 * Use less number of devices,
+	 * if there are more available than cores.
+	 */
+	if (enabled_cdev_count > nb_lcores)
+		enabled_cdev_count = nb_lcores;
 
 	/* Create a mempool shared by all the devices */
 	uint32_t max_sess_size = 0, sess_size;
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'examples/l2fwd-crypto: fix the default aead assignments' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'mbuf: improve tunnel Tx offloads " Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'app/crypto-perf: fix excess crypto device error' " Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'crypto/zuc: do not set default op status' " Yuanhan Liu
                   ` (21 subsequent siblings)
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Hemant Agrawal; +Cc: Akhil Goyal, Pablo de Lara, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From 6b403bbfd7b2799d8e08f9af8e9fa4dc0119f40a Mon Sep 17 00:00:00 2001
From: Hemant Agrawal <hemant.agrawal@nxp.com>
Date: Wed, 11 Apr 2018 14:45:47 +0530
Subject: [PATCH] examples/l2fwd-crypto: fix the default aead assignments

[ upstream commit d2c4b7d365d6c680d77d1fe7aa399c9d64514127 ]

The code is incorrectly updating the authxform instead of
aead xforms.

Fixes: b79e4c00af0e ("cryptodev: use AES-GCM/CCM as AEAD algorithms")

Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
Acked-by: Akhil Goyal <akhil.goyal@nxp.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
---
 examples/l2fwd-crypto/main.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/examples/l2fwd-crypto/main.c b/examples/l2fwd-crypto/main.c
index d4e1682c8..ff5752224 100644
--- a/examples/l2fwd-crypto/main.c
+++ b/examples/l2fwd-crypto/main.c
@@ -1506,8 +1506,8 @@ l2fwd_crypto_default_options(struct l2fwd_crypto_options *options)
 	options->aead_iv_random_size = -1;
 	options->aead_iv.length = 0;
 
-	options->auth_xform.aead.algo = RTE_CRYPTO_AEAD_AES_GCM;
-	options->auth_xform.aead.op = RTE_CRYPTO_AEAD_OP_ENCRYPT;
+	options->aead_xform.aead.algo = RTE_CRYPTO_AEAD_AES_GCM;
+	options->aead_xform.aead.op = RTE_CRYPTO_AEAD_OP_ENCRYPT;
 
 	options->aad_param = 0;
 	options->aad_random_size = -1;
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'crypto/zuc: do not set default op status' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
                   ` (2 preceding siblings ...)
  2018-05-06  6:36 ` [dpdk-stable] patch 'examples/l2fwd-crypto: fix the default aead assignments' " Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'crypto/zuc: batch ops with same transform' " Yuanhan Liu
                   ` (20 subsequent siblings)
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Pablo de Lara; +Cc: Fiona Trahe, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From fb22752ef6a840cc690446f96599b4f167edb880 Mon Sep 17 00:00:00 2001
From: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Date: Thu, 19 Apr 2018 15:55:39 +0100
Subject: [PATCH] crypto/zuc: do not set default op status

[ upstream commit 466dcf34d728db0ae86d83f37dd7db5c20dd2979 ]

When crypto operations are allocated from the operation
pool, their status get reset to NOT_PROCESSED.
Therefore, there is no need to set this status again.

Fixes: cf7685d68f00 ("crypto/zuc: add driver for ZUC library")

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Fiona Trahe <fiona.trahe@intel.com>
---
 drivers/crypto/zuc/rte_zuc_pmd.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/drivers/crypto/zuc/rte_zuc_pmd.c b/drivers/crypto/zuc/rte_zuc_pmd.c
index 590224bfc..a951b49bf 100644
--- a/drivers/crypto/zuc/rte_zuc_pmd.c
+++ b/drivers/crypto/zuc/rte_zuc_pmd.c
@@ -380,9 +380,6 @@ zuc_pmd_enqueue_burst(void *queue_pair, struct rte_crypto_op **ops,
 	for (i = 0; i < nb_ops; i++) {
 		curr_c_op = ops[i];
 
-		/* Set status as enqueued (not processed yet) by default. */
-		curr_c_op->status = RTE_CRYPTO_OP_STATUS_NOT_PROCESSED;
-
 		curr_sess = zuc_get_session(qp, curr_c_op);
 		if (unlikely(curr_sess == NULL ||
 				curr_sess->op == ZUC_OP_NOT_SUPPORTED)) {
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'crypto/zuc: batch ops with same transform' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
                   ` (3 preceding siblings ...)
  2018-05-06  6:36 ` [dpdk-stable] patch 'crypto/zuc: do not set default op status' " Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'crypto/dpaa2_sec: fix HMAC supported digest sizes' " Yuanhan Liu
                   ` (19 subsequent siblings)
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Pablo de Lara; +Cc: Fiona Trahe, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From 85f88384eb261cf39faf0f75ac34b4638737ccda Mon Sep 17 00:00:00 2001
From: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Date: Thu, 19 Apr 2018 15:55:41 +0100
Subject: [PATCH] crypto/zuc: batch ops with same transform

[ upstream commit 17c36a6746419ae8d1a14b1d1345d4a892511c57 ]

The ZUC API to encrypt packets does not require the operations
to share the same key. Currently, the operations were being
batched only when they shared the same key, but this is not needed.

Instead, now operations will be batched based on the transform
(cipher only, auth only...).

Fixes: cf7685d68f00 ("crypto/zuc: add driver for ZUC library")

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Acked-by: Fiona Trahe <fiona.trahe@intel.com>
---
 drivers/crypto/zuc/rte_zuc_pmd.c | 105 ++++++++++++++++++++++++---------------
 1 file changed, 64 insertions(+), 41 deletions(-)

diff --git a/drivers/crypto/zuc/rte_zuc_pmd.c b/drivers/crypto/zuc/rte_zuc_pmd.c
index a951b49bf..8b13be9e9 100644
--- a/drivers/crypto/zuc/rte_zuc_pmd.c
+++ b/drivers/crypto/zuc/rte_zuc_pmd.c
@@ -40,7 +40,7 @@
 
 #include "rte_zuc_pmd_private.h"
 
-#define ZUC_MAX_BURST 8
+#define ZUC_MAX_BURST 4
 #define BYTE_LEN 8
 
 static uint8_t cryptodev_driver_id;
@@ -196,10 +196,10 @@ zuc_get_session(struct zuc_qp *qp, struct rte_crypto_op *op)
 	return sess;
 }
 
-/** Encrypt/decrypt mbufs with same cipher key. */
+/** Encrypt/decrypt mbufs. */
 static uint8_t
 process_zuc_cipher_op(struct rte_crypto_op **ops,
-		struct zuc_session *session,
+		struct zuc_session **sessions,
 		uint8_t num_ops)
 {
 	unsigned i;
@@ -208,6 +208,7 @@ process_zuc_cipher_op(struct rte_crypto_op **ops,
 	uint8_t *iv[ZUC_MAX_BURST];
 	uint32_t num_bytes[ZUC_MAX_BURST];
 	uint8_t *cipher_keys[ZUC_MAX_BURST];
+	struct zuc_session *sess;
 
 	for (i = 0; i < num_ops; i++) {
 		if (((ops[i]->sym->cipher.data.length % BYTE_LEN) != 0)
@@ -218,6 +219,8 @@ process_zuc_cipher_op(struct rte_crypto_op **ops,
 			break;
 		}
 
+		sess = sessions[i];
+
 #ifdef RTE_LIBRTE_PMD_ZUC_DEBUG
 		if (!rte_pktmbuf_is_contiguous(ops[i]->sym->m_src) ||
 				(ops[i]->sym->m_dst != NULL &&
@@ -239,10 +242,10 @@ process_zuc_cipher_op(struct rte_crypto_op **ops,
 			rte_pktmbuf_mtod(ops[i]->sym->m_src, uint8_t *) +
 				(ops[i]->sym->cipher.data.offset >> 3);
 		iv[i] = rte_crypto_op_ctod_offset(ops[i], uint8_t *,
-				session->cipher_iv_offset);
+				sess->cipher_iv_offset);
 		num_bytes[i] = ops[i]->sym->cipher.data.length >> 3;
 
-		cipher_keys[i] = session->pKey_cipher;
+		cipher_keys[i] = sess->pKey_cipher;
 
 		processed_ops++;
 	}
@@ -253,10 +256,10 @@ process_zuc_cipher_op(struct rte_crypto_op **ops,
 	return processed_ops;
 }
 
-/** Generate/verify hash from mbufs with same hash key. */
+/** Generate/verify hash from mbufs. */
 static int
 process_zuc_hash_op(struct zuc_qp *qp, struct rte_crypto_op **ops,
-		struct zuc_session *session,
+		struct zuc_session **sessions,
 		uint8_t num_ops)
 {
 	unsigned i;
@@ -265,6 +268,7 @@ process_zuc_hash_op(struct zuc_qp *qp, struct rte_crypto_op **ops,
 	uint32_t *dst;
 	uint32_t length_in_bits;
 	uint8_t *iv;
+	struct zuc_session *sess;
 
 	for (i = 0; i < num_ops; i++) {
 		/* Data must be byte aligned */
@@ -274,17 +278,19 @@ process_zuc_hash_op(struct zuc_qp *qp, struct rte_crypto_op **ops,
 			break;
 		}
 
+		sess = sessions[i];
+
 		length_in_bits = ops[i]->sym->auth.data.length;
 
 		src = rte_pktmbuf_mtod(ops[i]->sym->m_src, uint8_t *) +
 				(ops[i]->sym->auth.data.offset >> 3);
 		iv = rte_crypto_op_ctod_offset(ops[i], uint8_t *,
-				session->auth_iv_offset);
+				sess->auth_iv_offset);
 
-		if (session->auth_op == RTE_CRYPTO_AUTH_OP_VERIFY) {
+		if (sess->auth_op == RTE_CRYPTO_AUTH_OP_VERIFY) {
 			dst = (uint32_t *)qp->temp_digest;
 
-			sso_zuc_eia3_1_buffer(session->pKey_hash,
+			sso_zuc_eia3_1_buffer(sess->pKey_hash,
 					iv, src,
 					length_in_bits,	dst);
 			/* Verify digest. */
@@ -294,7 +300,7 @@ process_zuc_hash_op(struct zuc_qp *qp, struct rte_crypto_op **ops,
 		} else  {
 			dst = (uint32_t *)ops[i]->sym->auth.digest.data;
 
-			sso_zuc_eia3_1_buffer(session->pKey_hash,
+			sso_zuc_eia3_1_buffer(sess->pKey_hash,
 					iv, src,
 					length_in_bits, dst);
 		}
@@ -304,33 +310,34 @@ process_zuc_hash_op(struct zuc_qp *qp, struct rte_crypto_op **ops,
 	return processed_ops;
 }
 
-/** Process a batch of crypto ops which shares the same session. */
+/** Process a batch of crypto ops which shares the same operation type. */
 static int
-process_ops(struct rte_crypto_op **ops, struct zuc_session *session,
+process_ops(struct rte_crypto_op **ops, enum zuc_operation op_type,
+		struct zuc_session **sessions,
 		struct zuc_qp *qp, uint8_t num_ops,
 		uint16_t *accumulated_enqueued_ops)
 {
 	unsigned i;
 	unsigned enqueued_ops, processed_ops;
 
-	switch (session->op) {
+	switch (op_type) {
 	case ZUC_OP_ONLY_CIPHER:
 		processed_ops = process_zuc_cipher_op(ops,
-				session, num_ops);
+				sessions, num_ops);
 		break;
 	case ZUC_OP_ONLY_AUTH:
-		processed_ops = process_zuc_hash_op(qp, ops, session,
+		processed_ops = process_zuc_hash_op(qp, ops, sessions,
 				num_ops);
 		break;
 	case ZUC_OP_CIPHER_AUTH:
-		processed_ops = process_zuc_cipher_op(ops, session,
+		processed_ops = process_zuc_cipher_op(ops, sessions,
 				num_ops);
-		process_zuc_hash_op(qp, ops, session, processed_ops);
+		process_zuc_hash_op(qp, ops, sessions, processed_ops);
 		break;
 	case ZUC_OP_AUTH_CIPHER:
-		processed_ops = process_zuc_hash_op(qp, ops, session,
+		processed_ops = process_zuc_hash_op(qp, ops, sessions,
 				num_ops);
-		process_zuc_cipher_op(ops, session, processed_ops);
+		process_zuc_cipher_op(ops, sessions, processed_ops);
 		break;
 	default:
 		/* Operation not supported. */
@@ -346,10 +353,10 @@ process_ops(struct rte_crypto_op **ops, struct zuc_session *session,
 			ops[i]->status = RTE_CRYPTO_OP_STATUS_SUCCESS;
 		/* Free session if a session-less crypto op. */
 		if (ops[i]->sess_type == RTE_CRYPTO_OP_SESSIONLESS) {
-			memset(session, 0, sizeof(struct zuc_session));
+			memset(sessions[i], 0, sizeof(struct zuc_session));
 			memset(ops[i]->sym->session, 0,
 					rte_cryptodev_get_header_session_size());
-			rte_mempool_put(qp->sess_mp, session);
+			rte_mempool_put(qp->sess_mp, sessions[i]);
 			rte_mempool_put(qp->sess_mp, ops[i]->sym->session);
 			ops[i]->sym->session = NULL;
 		}
@@ -370,7 +377,10 @@ zuc_pmd_enqueue_burst(void *queue_pair, struct rte_crypto_op **ops,
 	struct rte_crypto_op *c_ops[ZUC_MAX_BURST];
 	struct rte_crypto_op *curr_c_op;
 
-	struct zuc_session *prev_sess = NULL, *curr_sess = NULL;
+	struct zuc_session *curr_sess;
+	struct zuc_session *sessions[ZUC_MAX_BURST];
+	enum zuc_operation prev_zuc_op = ZUC_OP_NOT_SUPPORTED;
+	enum zuc_operation curr_zuc_op;
 	struct zuc_qp *qp = queue_pair;
 	unsigned i;
 	uint8_t burst_size = 0;
@@ -388,50 +398,63 @@ zuc_pmd_enqueue_burst(void *queue_pair, struct rte_crypto_op **ops,
 			break;
 		}
 
-		/* Batch ops that share the same session. */
-		if (prev_sess == NULL) {
-			prev_sess = curr_sess;
-			c_ops[burst_size++] = curr_c_op;
-		} else if (curr_sess == prev_sess) {
-			c_ops[burst_size++] = curr_c_op;
+		curr_zuc_op = curr_sess->op;
+
+		/*
+		 * Batch ops that share the same operation type
+		 * (cipher only, auth only...).
+		 */
+		if (burst_size == 0) {
+			prev_zuc_op = curr_zuc_op;
+			c_ops[0] = curr_c_op;
+			sessions[0] = curr_sess;
+			burst_size++;
+		} else if (curr_zuc_op == prev_zuc_op) {
+			c_ops[burst_size] = curr_c_op;
+			sessions[burst_size] = curr_sess;
+			burst_size++;
 			/*
 			 * When there are enough ops to process in a batch,
 			 * process them, and start a new batch.
 			 */
 			if (burst_size == ZUC_MAX_BURST) {
-				processed_ops = process_ops(c_ops, prev_sess,
-						qp, burst_size, &enqueued_ops);
+				processed_ops = process_ops(c_ops, curr_zuc_op,
+						sessions, qp, burst_size,
+						&enqueued_ops);
 				if (processed_ops < burst_size) {
 					burst_size = 0;
 					break;
 				}
 
 				burst_size = 0;
-				prev_sess = NULL;
 			}
 		} else {
 			/*
-			 * Different session, process the ops
-			 * of the previous session.
+			 * Different operation type, process the ops
+			 * of the previous type.
 			 */
-			processed_ops = process_ops(c_ops, prev_sess,
-					qp, burst_size, &enqueued_ops);
+			processed_ops = process_ops(c_ops, prev_zuc_op,
+					sessions, qp, burst_size,
+					&enqueued_ops);
 			if (processed_ops < burst_size) {
 				burst_size = 0;
 				break;
 			}
 
 			burst_size = 0;
-			prev_sess = curr_sess;
+			prev_zuc_op = curr_zuc_op;
 
-			c_ops[burst_size++] = curr_c_op;
+			c_ops[0] = curr_c_op;
+			sessions[0] = curr_sess;
+			burst_size++;
 		}
 	}
 
 	if (burst_size != 0) {
-		/* Process the crypto ops of the last session. */
-		processed_ops = process_ops(c_ops, prev_sess,
-				qp, burst_size, &enqueued_ops);
+		/* Process the crypto ops of the last operation type. */
+		processed_ops = process_ops(c_ops, prev_zuc_op,
+				sessions, qp, burst_size,
+				&enqueued_ops);
 	}
 
 	qp->qp_stats.enqueue_err_count += nb_ops - enqueued_ops;
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'crypto/dpaa2_sec: fix HMAC supported digest sizes' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
                   ` (4 preceding siblings ...)
  2018-05-06  6:36 ` [dpdk-stable] patch 'crypto/zuc: batch ops with same transform' " Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'mk: fix make defconfig on FreeBSD' " Yuanhan Liu
                   ` (18 subsequent siblings)
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Hemant Agrawal; +Cc: Nipun Gupta, Akhil Goyal, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From 2419984694b55d44dcda3e6cfe89203006ba9138 Mon Sep 17 00:00:00 2001
From: Hemant Agrawal <hemant.agrawal@nxp.com>
Date: Thu, 19 Apr 2018 22:22:38 +0530
Subject: [PATCH] crypto/dpaa2_sec: fix HMAC supported digest sizes

[ upstream commit e37effdc3d48c5f63871639c9007a10a5f57b825 ]

For HMAC algorithms (MD5-HMAC, SHAx-HMAC), the supported
digest sizes are not a fixed value, but a range between
1 and the maximum digest size for those algorithms.

Fixes: f947fd77185f ("crypto/dpaa2_sec: fix HMAC supported key sizes")

Signed-off-by: Nipun Gupta <nipun.gupta@nxp.com>
Signed-off-by: Hemant Agrawal <hemant.agrawal@nxp.com>
Acked-by: Akhil Goyal <akhil.goyal@nxp.com>
---
 drivers/crypto/dpaa2_sec/dpaa2_sec_priv.h | 26 +++++++++++++-------------
 1 file changed, 13 insertions(+), 13 deletions(-)

diff --git a/drivers/crypto/dpaa2_sec/dpaa2_sec_priv.h b/drivers/crypto/dpaa2_sec/dpaa2_sec_priv.h
index 8e583803e..ae8c0c302 100644
--- a/drivers/crypto/dpaa2_sec/dpaa2_sec_priv.h
+++ b/drivers/crypto/dpaa2_sec/dpaa2_sec_priv.h
@@ -211,9 +211,9 @@ static const struct rte_cryptodev_capabilities dpaa2_sec_capabilities[] = {
 					.increment = 1
 				},
 				.digest_size = {
-					.min = 16,
+					.min = 1,
 					.max = 16,
-					.increment = 0
+					.increment = 1
 				},
 				.iv_size = { 0 }
 			}, }
@@ -232,9 +232,9 @@ static const struct rte_cryptodev_capabilities dpaa2_sec_capabilities[] = {
 					.increment = 1
 				},
 				.digest_size = {
-					.min = 20,
+					.min = 1,
 					.max = 20,
-					.increment = 0
+					.increment = 1
 				},
 				.iv_size = { 0 }
 			}, }
@@ -253,9 +253,9 @@ static const struct rte_cryptodev_capabilities dpaa2_sec_capabilities[] = {
 					.increment = 1
 				},
 				.digest_size = {
-					.min = 28,
+					.min = 1,
 					.max = 28,
-					.increment = 0
+					.increment = 1
 				},
 				.iv_size = { 0 }
 			}, }
@@ -274,9 +274,9 @@ static const struct rte_cryptodev_capabilities dpaa2_sec_capabilities[] = {
 					.increment = 1
 				},
 				.digest_size = {
-						.min = 32,
-						.max = 32,
-						.increment = 0
+					.min = 1,
+					.max = 32,
+					.increment = 1
 				},
 				.iv_size = { 0 }
 				}, }
@@ -295,9 +295,9 @@ static const struct rte_cryptodev_capabilities dpaa2_sec_capabilities[] = {
 					.increment = 1
 				},
 				.digest_size = {
-					.min = 48,
+					.min = 1,
 					.max = 48,
-					.increment = 0
+					.increment = 1
 				},
 				.iv_size = { 0 }
 			}, }
@@ -316,9 +316,9 @@ static const struct rte_cryptodev_capabilities dpaa2_sec_capabilities[] = {
 					.increment = 1
 				},
 				.digest_size = {
-					.min = 64,
+					.min = 1,
 					.max = 64,
-					.increment = 0
+					.increment = 1
 				},
 				.iv_size = { 0 }
 			}, }
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'mk: fix make defconfig on FreeBSD' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
                   ` (5 preceding siblings ...)
  2018-05-06  6:36 ` [dpdk-stable] patch 'crypto/dpaa2_sec: fix HMAC supported digest sizes' " Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'mempool: fix leak when no objects are populated' " Yuanhan Liu
                   ` (17 subsequent siblings)
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: David Hunt; +Cc: Anatoly Burakov, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From 63fd5f7696943eba4ba10652b6bd2fe61e834692 Mon Sep 17 00:00:00 2001
From: David Hunt <david.hunt@intel.com>
Date: Mon, 23 Apr 2018 14:09:02 +0100
Subject: [PATCH] mk: fix make defconfig on FreeBSD

[ upstream commit 6ace79505d326d05aaa3c57facca7ca8e1675b11 ]

On FreeBSD, make defconfig generates the config as
"defconfig_x86_64-bsdapp-", which does not resolve to any known
config file.

On FreeBSD, we get amd64 out of "uname -m", which was not handled by
the list of checks, but which now resolves to x86_64-native.

Then we run '$CC --version', and use grep -o with the list of known
compilers, and set to either gcc, icc or clang. Grep's '-o' option
returns the matched word rather than the whole line, making the
result easier to use.

The remaining code in the patch then takes ${compiler}, the "uname -m"
output and assembles them all together into a valid freebsd config name,
i.e. "defconfig_x86_64-native-bsdapp-clang".

Fixes: bce6c42c4ad5 ("mk: add sensible default target with defconfig")

Signed-off-by: David Hunt <david.hunt@intel.com>
Tested-by: Anatoly Burakov <anatoly.burakov@intel.com>
---
 mk/rte.sdkconfig.mk | 19 ++++++++++++++-----
 1 file changed, 14 insertions(+), 5 deletions(-)

diff --git a/mk/rte.sdkconfig.mk b/mk/rte.sdkconfig.mk
index 97363416a..59cf6b19b 100644
--- a/mk/rte.sdkconfig.mk
+++ b/mk/rte.sdkconfig.mk
@@ -64,7 +64,6 @@ notemplate:
 	@echo "use T=template from the following list:"
 	@$(MAKE) -rR showconfigs | sed 's,^,  ,'
 
-
 .PHONY: defconfig
 defconfig:
 	@$(MAKE) config T=$(shell \
@@ -75,15 +74,25 @@ defconfig:
                         print "arm-armv7a"} \
                 else if ($$0 == "ppc64") { \
                         print "ppc_64-power8"} \
+                else if ($$0 == "amd64") { \
+                        print "x86_64-native"} \
                 else { \
-                        printf "%s-native", $$0} }')-$(shell \
+                        printf "%s-native", $$0} }' \
+		)-$(shell \
                 uname | awk '{ \
                 if ($$0 == "Linux") { \
                         print "linuxapp"} \
                 else { \
-                        print "bsdapp"} }')-$(shell \
-                ${CC} -v 2>&1 | \
-                grep " version " | cut -d ' ' -f 1)
+                        print "bsdapp"} }' \
+		)-$(shell \
+		${CC} --version | grep -o 'cc\|gcc\|icc\|clang' | awk \
+		'{ \
+		if ($$1 == "cc") { \
+			print "gcc" } \
+		else { \
+			print $$1 } \
+		}' \
+		)
 
 .PHONY: config
 ifeq ($(RTE_CONFIG_TEMPLATE),)
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'mempool: fix leak when no objects are populated' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
                   ` (6 preceding siblings ...)
  2018-05-06  6:36 ` [dpdk-stable] patch 'mk: fix make defconfig on FreeBSD' " Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'test: fix memory flags test for low NUMA nodes number' " Yuanhan Liu
                   ` (16 subsequent siblings)
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Andrew Rybchenko; +Cc: Olivier Matz, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From 383a388cb2287fff950d68a95252e985476168bf Mon Sep 17 00:00:00 2001
From: Andrew Rybchenko <arybchenko@solarflare.com>
Date: Mon, 16 Apr 2018 14:24:30 +0100
Subject: [PATCH] mempool: fix leak when no objects are populated

[ upstream commit 25e6755056eaba45921b898b9986af68277ac6ac ]

Fixes: 84121f197187 ("mempool: store memory chunks in a list")

Suggested-by: Olivier Matz <olivier.matz@6wind.com>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
---
 lib/librte_mempool/rte_mempool.c | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/lib/librte_mempool/rte_mempool.c b/lib/librte_mempool/rte_mempool.c
index 5bd74eac8..5bb286a41 100644
--- a/lib/librte_mempool/rte_mempool.c
+++ b/lib/librte_mempool/rte_mempool.c
@@ -437,12 +437,18 @@ rte_mempool_populate_iova(struct rte_mempool *mp, char *vaddr,
 	}
 
 	/* not enough room to store one object */
-	if (i == 0)
-		return -EINVAL;
+	if (i == 0) {
+		ret = -EINVAL;
+		goto fail;
+	}
 
 	STAILQ_INSERT_TAIL(&mp->mem_list, memhdr, next);
 	mp->nb_mem_chunks++;
 	return i;
+
+fail:
+	rte_free(memhdr);
+	return ret;
 }
 
 int
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'test: fix memory flags test for low NUMA nodes number' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
                   ` (7 preceding siblings ...)
  2018-05-06  6:36 ` [dpdk-stable] patch 'mempool: fix leak when no objects are populated' " Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'test/mempool: fix autotest retry' " Yuanhan Liu
                   ` (15 subsequent siblings)
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Phil Yang; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From 65b92b604c5c0200e8e0d8f5be0d60f256adc47f Mon Sep 17 00:00:00 2001
From: Phil Yang <phil.yang@arm.com>
Date: Tue, 6 Feb 2018 10:21:38 +0800
Subject: [PATCH] test: fix memory flags test for low NUMA nodes number

[ upstream commit 896af46bd1ade6d8d1f452f03c6e08e0965d7ef9 ]

Since RTE_MAX_NUMA_NODES is configurable, the existing socket number
could greater than RTE_MAX_NUMA_NODES. Optimize test case to cover this
situation.(i.e RTE_MAX_NUMA_NODES=1)

Fixes: 45f1b6e8680a ("app: add new tests on eal flags")

Signed-off-by: Phil Yang <phil.yang@arm.com>
---
 test/test/test_eal_flags.c | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/test/test/test_eal_flags.c b/test/test/test_eal_flags.c
index 310109e6d..473ea113d 100644
--- a/test/test/test_eal_flags.c
+++ b/test/test/test_eal_flags.c
@@ -61,7 +61,7 @@
 #define memtest "memtest"
 #define memtest1 "memtest1"
 #define memtest2 "memtest2"
-#define SOCKET_MEM_STRLEN (RTE_MAX_NUMA_NODES * 10)
+#define SOCKET_MEM_STRLEN (RTE_MAX_NUMA_NODES * 20)
 #define launch_proc(ARGV) process_dup(ARGV, \
 		sizeof(ARGV)/(sizeof(ARGV[0])), __func__)
 
@@ -1166,10 +1166,11 @@ test_memory_flags(void)
 #ifdef RTE_EXEC_ENV_BSDAPP
 	int i, num_sockets = 1;
 #else
-	int i, num_sockets = get_number_of_sockets();
+	int i, num_sockets = RTE_MIN(get_number_of_sockets(),
+			RTE_MAX_NUMA_NODES);
 #endif
 
-	if (num_sockets <= 0 || num_sockets > RTE_MAX_NUMA_NODES) {
+	if (num_sockets <= 0) {
 		printf("Error - cannot get number of sockets!\n");
 		return -1;
 	}
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'test/mempool: fix autotest retry' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
                   ` (8 preceding siblings ...)
  2018-05-06  6:36 ` [dpdk-stable] patch 'test: fix memory flags test for low NUMA nodes number' " Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'bus/pci: fix find device implementation' " Yuanhan Liu
                   ` (14 subsequent siblings)
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Andrew Rybchenko; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From cc8e68493a1266a746bfe21ea19eaaec0627a729 Mon Sep 17 00:00:00 2001
From: Andrew Rybchenko <arybchenko@solarflare.com>
Date: Wed, 25 Apr 2018 18:00:37 +0100
Subject: [PATCH] test/mempool: fix autotest retry

[ upstream commit 2d645858a93e21a41e84928d4fb869318c3639a6 ]

Single producer / single consumer mempool handle is stored in static
variable and the mempool allocated if stored value is NULL.
If the mempool is freed, NULL should be restored to make sure that
the mempool is allocated once again next time when the test is run.

Fixes: 8ef772aee072 ("app/test: rework mempool test")

Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
---
 test/test/test_mempool.c | 15 +++++++++------
 1 file changed, 9 insertions(+), 6 deletions(-)

diff --git a/test/test/test_mempool.c b/test/test/test_mempool.c
index 37ead503b..56b0fd022 100644
--- a/test/test/test_mempool.c
+++ b/test/test/test_mempool.c
@@ -355,17 +355,17 @@ test_mempool_sp_sc(void)
 	}
 	if (rte_mempool_lookup("test_mempool_sp_sc") != mp_spsc) {
 		printf("Cannot lookup mempool from its name\n");
-		rte_mempool_free(mp_spsc);
-		RET_ERR();
+		ret = -1;
+		goto err;
 	}
 	lcore_next = rte_get_next_lcore(lcore_id, 0, 1);
 	if (lcore_next >= RTE_MAX_LCORE) {
-		rte_mempool_free(mp_spsc);
-		RET_ERR();
+		ret = -1;
+		goto err;
 	}
 	if (rte_eal_lcore_role(lcore_next) != ROLE_RTE) {
-		rte_mempool_free(mp_spsc);
-		RET_ERR();
+		ret = -1;
+		goto err;
 	}
 	rte_spinlock_init(&scsp_spinlock);
 	memset(scsp_obj_table, 0, sizeof(scsp_obj_table));
@@ -376,7 +376,10 @@ test_mempool_sp_sc(void)
 
 	if (rte_eal_wait_lcore(lcore_next) < 0)
 		ret = -1;
+
+err:
 	rte_mempool_free(mp_spsc);
+	mp_spsc = NULL;
 
 	return ret;
 }
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'bus/pci: fix find device implementation' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
                   ` (9 preceding siblings ...)
  2018-05-06  6:36 ` [dpdk-stable] patch 'test/mempool: fix autotest retry' " Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'net/sfc: add missing Rx fini on RSS setup fail path' " Yuanhan Liu
                   ` (13 subsequent siblings)
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Gaetan Rivet; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From 899885d1c17155a6d24e004e6e1dfcde3789f14d Mon Sep 17 00:00:00 2001
From: Gaetan Rivet <gaetan.rivet@6wind.com>
Date: Fri, 27 Apr 2018 16:13:05 +0200
Subject: [PATCH] bus/pci: fix find device implementation

[ upstream commit 64de7e4069b9b84b0f2d840b44e334233412d55f ]

If start is set, and a device before it matches the data
passed for comparison, then this first device is returned.

This induces potentially infinite loops.

Fixes: c7fe1eea8a74 ("bus: simplify finding starting point")

Signed-off-by: Gaetan Rivet <gaetan.rivet@6wind.com>
---
 drivers/bus/pci/pci_common.c  | 21 ++++++++++++---------
 drivers/bus/pci/rte_bus_pci.h |  3 +++
 2 files changed, 15 insertions(+), 9 deletions(-)

diff --git a/drivers/bus/pci/pci_common.c b/drivers/bus/pci/pci_common.c
index 104fdf904..6789748e2 100644
--- a/drivers/bus/pci/pci_common.c
+++ b/drivers/bus/pci/pci_common.c
@@ -488,17 +488,20 @@ static struct rte_device *
 pci_find_device(const struct rte_device *start, rte_dev_cmp_t cmp,
 		const void *data)
 {
-	struct rte_pci_device *dev;
+	const struct rte_pci_device *pstart;
+	struct rte_pci_device *pdev;
 
-	FOREACH_DEVICE_ON_PCIBUS(dev) {
-		if (start && &dev->device == start) {
-			start = NULL; /* starting point found */
-			continue;
-		}
-		if (cmp(&dev->device, data) == 0)
-			return &dev->device;
+	if (start != NULL) {
+		pstart = RTE_DEV_TO_PCI_CONST(start);
+		pdev = TAILQ_NEXT(pstart, next);
+	} else {
+		pdev = TAILQ_FIRST(&rte_pci_bus.device_list);
+	}
+	while (pdev != NULL) {
+		if (cmp(&pdev->device, data) == 0)
+			return &pdev->device;
+		pdev = TAILQ_NEXT(pdev, next);
 	}
-
 	return NULL;
 }
 
diff --git a/drivers/bus/pci/rte_bus_pci.h b/drivers/bus/pci/rte_bus_pci.h
index d4a299641..c6af61d74 100644
--- a/drivers/bus/pci/rte_bus_pci.h
+++ b/drivers/bus/pci/rte_bus_pci.h
@@ -103,6 +103,9 @@ struct rte_pci_device {
  */
 #define RTE_DEV_TO_PCI(ptr) container_of(ptr, struct rte_pci_device, device)
 
+#define RTE_DEV_TO_PCI_CONST(ptr) \
+	container_of(ptr, const struct rte_pci_device, device)
+
 #define RTE_ETH_DEV_TO_PCI(eth_dev)	RTE_DEV_TO_PCI((eth_dev)->device)
 
 /** Any PCI device identifier (vendor, device, ...) */
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'net/sfc: add missing Rx fini on RSS setup fail path' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
                   ` (10 preceding siblings ...)
  2018-05-06  6:36 ` [dpdk-stable] patch 'bus/pci: fix find device implementation' " Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'net/bnxt: set padding flags in Rx descriptor' " Yuanhan Liu
                   ` (12 subsequent siblings)
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Ivan Malov; +Cc: Andrew Rybchenko, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From 467c776f37826597b4764cc801ba0af7920a2ed8 Mon Sep 17 00:00:00 2001
From: Ivan Malov <ivan.malov@oktetlabs.ru>
Date: Tue, 17 Apr 2018 16:18:38 +0100
Subject: [PATCH] net/sfc: add missing Rx fini on RSS setup fail path

[ upstream commit 00b94c1c21d4e8300c51acdd5a0e43bed4552bae ]

Fixes: 4ec1fc3ba881 ("net/sfc: add basic stubs for RSS support on driver attach")

Signed-off-by: Ivan Malov <ivan.malov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
---
 drivers/net/sfc/sfc.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/net/sfc/sfc.c b/drivers/net/sfc/sfc.c
index 49d7e9370..2196c3f10 100644
--- a/drivers/net/sfc/sfc.c
+++ b/drivers/net/sfc/sfc.c
@@ -548,6 +548,8 @@ sfc_set_rss_defaults(struct sfc_adapter *sa)
 
 fail_hash_support_get:
 fail_scale_support_get:
+	efx_rx_fini(sa->nic);
+
 fail_rx_init:
 	efx_ev_fini(sa->nic);
 
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'net/bnxt: set padding flags in Rx descriptor' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
                   ` (11 preceding siblings ...)
  2018-05-06  6:36 ` [dpdk-stable] patch 'net/sfc: add missing Rx fini on RSS setup fail path' " Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'net/bnxt: fix endianness of flag' " Yuanhan Liu
                   ` (11 subsequent siblings)
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Ajit Khaparde; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From 77d2a6e3f83567e4968ae38ec424c0c6cc82da36 Mon Sep 17 00:00:00 2001
From: Ajit Khaparde <ajit.khaparde@broadcom.com>
Date: Mon, 16 Apr 2018 18:11:14 -0700
Subject: [PATCH] net/bnxt: set padding flags in Rx descriptor

[ upstream commit f4253e97e7b0bc372ad6ba31fb05df5c79f97b5c ]

Set the RX_PROD_PKT_BD_FLAGS_EOP_PAD in Rx buffer descriptors.

Fixes: 2eb53b134aae ("net/bnxt: add initial Rx code")

Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
---
 drivers/net/bnxt/bnxt_rxr.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/bnxt/bnxt_rxr.c b/drivers/net/bnxt/bnxt_rxr.c
index 5128335f6..e56dcbb7f 100644
--- a/drivers/net/bnxt/bnxt_rxr.c
+++ b/drivers/net/bnxt/bnxt_rxr.c
@@ -730,7 +730,7 @@ int bnxt_init_one_rx_ring(struct bnxt_rx_queue *rxq)
 	if (rxq->rx_buf_use_size <= size)
 		size = rxq->rx_buf_use_size;
 
-	type = RX_PROD_PKT_BD_TYPE_RX_PROD_PKT;
+	type = RX_PROD_PKT_BD_TYPE_RX_PROD_PKT | RX_PROD_PKT_BD_FLAGS_EOP_PAD;
 
 	rxr = rxq->rx_ring;
 	ring = rxr->rx_ring_struct;
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'net/bnxt: fix endianness of flag' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
                   ` (12 preceding siblings ...)
  2018-05-06  6:36 ` [dpdk-stable] patch 'net/bnxt: set padding flags in Rx descriptor' " Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'net/bnxt: fix Rx checksum flags for tunnel frames' " Yuanhan Liu
                   ` (10 subsequent siblings)
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Ajit Khaparde; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From d28d38bfdf24f4db77b4987df1552b1f3534522b Mon Sep 17 00:00:00 2001
From: Ajit Khaparde <ajit.khaparde@broadcom.com>
Date: Mon, 16 Apr 2018 18:11:15 -0700
Subject: [PATCH] net/bnxt: fix endianness of flag

[ upstream commit 8e92b4f1553dc45b6093ba1cb9162b98b4cf95ce ]

In bnxt_hwrm_vnic_alloc, use rte_cpu_to_le_32 while setting the flags.

Fixes: 2691827e82c0 ("net/bnxt: add HWRM VNIC alloc")

Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
---
 drivers/net/bnxt/bnxt_hwrm.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/net/bnxt/bnxt_hwrm.c b/drivers/net/bnxt/bnxt_hwrm.c
index f7e437160..120043d2f 100644
--- a/drivers/net/bnxt/bnxt_hwrm.c
+++ b/drivers/net/bnxt/bnxt_hwrm.c
@@ -1100,7 +1100,8 @@ int bnxt_hwrm_vnic_alloc(struct bnxt *bp, struct bnxt_vnic_info *vnic)
 	HWRM_PREP(req, VNIC_ALLOC);
 
 	if (vnic->func_default)
-		req.flags = HWRM_VNIC_ALLOC_INPUT_FLAGS_DEFAULT;
+		req.flags =
+			rte_cpu_to_le_32(HWRM_VNIC_ALLOC_INPUT_FLAGS_DEFAULT);
 	rc = bnxt_hwrm_send_message(bp, &req, sizeof(req));
 
 	HWRM_CHECK_RESULT();
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'net/bnxt: fix Rx checksum flags for tunnel frames' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
                   ` (13 preceding siblings ...)
  2018-05-06  6:36 ` [dpdk-stable] patch 'net/bnxt: fix endianness of flag' " Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'net/bnxt: free memory allocated for VF filters' " Yuanhan Liu
                   ` (9 subsequent siblings)
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Ajit Khaparde; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From 517758bd5d464e8ec56396e9777a966619b1c612 Mon Sep 17 00:00:00 2001
From: Ajit Khaparde <ajit.khaparde@broadcom.com>
Date: Mon, 16 Apr 2018 18:11:17 -0700
Subject: [PATCH] net/bnxt: fix Rx checksum flags for tunnel frames

[ upstream commit f3a050b65852ba3cfaebdae24cdd4edd54f82380 ]

Fix Rx checksum status for tunnel frames as seen by hardware.
Current code does not handle cases for tunnel frames correctly.

Fixes: 7ec39d8c524b ("net/bnxt: update status of Rx IP/L4 CKSUM")

Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
---
 drivers/net/bnxt/bnxt_rxr.h | 16 ++++++++++++----
 1 file changed, 12 insertions(+), 4 deletions(-)

diff --git a/drivers/net/bnxt/bnxt_rxr.h b/drivers/net/bnxt/bnxt_rxr.h
index a94373d19..05d6c3cd1 100644
--- a/drivers/net/bnxt/bnxt_rxr.h
+++ b/drivers/net/bnxt/bnxt_rxr.h
@@ -52,17 +52,25 @@
 #define BNXT_TPA_OUTER_L3_OFF(hdr_info)	\
 	((hdr_info) & 0x1ff)
 
-#define RX_CMP_L4_CS_BITS	rte_cpu_to_le_32(RX_PKT_CMPL_FLAGS2_L4_CS_CALC)
+#define RX_CMP_L4_CS_BITS	\
+	rte_cpu_to_le_32(RX_PKT_CMPL_FLAGS2_L4_CS_CALC | \
+			 RX_PKT_CMPL_FLAGS2_T_L4_CS_CALC)
 
-#define RX_CMP_L4_CS_ERR_BITS	rte_cpu_to_le_32(RX_PKT_CMPL_ERRORS_L4_CS_ERROR)
+#define RX_CMP_L4_CS_ERR_BITS	\
+	rte_cpu_to_le_32(RX_PKT_CMPL_ERRORS_L4_CS_ERROR | \
+			 RX_PKT_CMPL_ERRORS_T_L4_CS_ERROR)
 
 #define RX_CMP_L4_CS_OK(rxcmp1)						\
 	    (((rxcmp1)->flags2 & RX_CMP_L4_CS_BITS) &&		\
 	     !((rxcmp1)->errors_v2 & RX_CMP_L4_CS_ERR_BITS))
 
-#define RX_CMP_IP_CS_ERR_BITS	rte_cpu_to_le_32(RX_PKT_CMPL_ERRORS_IP_CS_ERROR)
+#define RX_CMP_IP_CS_ERR_BITS	\
+	rte_cpu_to_le_32(RX_PKT_CMPL_ERRORS_IP_CS_ERROR | \
+			 RX_PKT_CMPL_ERRORS_T_IP_CS_ERROR)
 
-#define RX_CMP_IP_CS_BITS	rte_cpu_to_le_32(RX_PKT_CMPL_FLAGS2_IP_CS_CALC)
+#define RX_CMP_IP_CS_BITS	\
+	rte_cpu_to_le_32(RX_PKT_CMPL_FLAGS2_IP_CS_CALC | \
+			 RX_PKT_CMPL_FLAGS2_T_IP_CS_CALC)
 
 #define RX_CMP_IP_CS_OK(rxcmp1)						\
 		(((rxcmp1)->flags2 & RX_CMP_IP_CS_BITS) &&	\
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'net/bnxt: free memory allocated for VF filters' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
                   ` (14 preceding siblings ...)
  2018-05-06  6:36 ` [dpdk-stable] patch 'net/bnxt: fix Rx checksum flags for tunnel frames' " Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'net/ixgbe: enable vector PMD for icc 32 bits' " Yuanhan Liu
                   ` (8 subsequent siblings)
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Ajit Khaparde; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From 45d2281f87735421a083b4fee4cde1ceb7d653b5 Mon Sep 17 00:00:00 2001
From: Ajit Khaparde <ajit.khaparde@broadcom.com>
Date: Mon, 16 Apr 2018 18:11:23 -0700
Subject: [PATCH] net/bnxt: free memory allocated for VF filters

[ upstream commit f11fd694a84a3108b93aaf807f1d1f12cb112ac4 ]

Memory allocated to hold VF filter info is not being freed currently.
This can cause potential memory leak.

Fixes: 7a5b0874440e ("net/bnxt: support to add a VF MAC address")

Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
---
 drivers/net/bnxt/bnxt_filter.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/drivers/net/bnxt/bnxt_filter.c b/drivers/net/bnxt/bnxt_filter.c
index 32af60612..8d3ddf1d2 100644
--- a/drivers/net/bnxt/bnxt_filter.c
+++ b/drivers/net/bnxt/bnxt_filter.c
@@ -159,6 +159,14 @@ void bnxt_free_filter_mem(struct bnxt *bp)
 
 	rte_free(bp->filter_info);
 	bp->filter_info = NULL;
+
+	for (i = 0; i < bp->pf.max_vfs; i++) {
+		STAILQ_FOREACH(filter, &bp->pf.vf_info[i].filter, next) {
+			rte_free(filter);
+			STAILQ_REMOVE(&bp->pf.vf_info[i].filter, filter,
+				      bnxt_filter_info, next);
+		}
+	}
 }
 
 int bnxt_alloc_filter_mem(struct bnxt *bp)
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'net/ixgbe: enable vector PMD for icc 32 bits' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
                   ` (15 preceding siblings ...)
  2018-05-06  6:36 ` [dpdk-stable] patch 'net/bnxt: free memory allocated for VF filters' " Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'net/bnx2x: fix for PCI FLR after ungraceful exit' " Yuanhan Liu
                   ` (7 subsequent siblings)
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Pablo de Lara; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From 8c4193c577f508fb6701bc18624afc99b8b53dfd Mon Sep 17 00:00:00 2001
From: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Date: Tue, 17 Apr 2018 14:39:04 +0100
Subject: [PATCH] net/ixgbe: enable vector PMD for icc 32 bits

[ upstream commit 7bd0994f0127a24860dc3bc03d60b37612d3ecf0 ]

IXGBE vector PMD was re-enabled for 32 bits, but only for gcc.
This commit enables it for icc too.

Fixes: e6672d2f0f88 ("net/ixgbe: enable ixgbe vector PMD for i686")

Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
---
 config/defconfig_i686-native-linuxapp-icc | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/config/defconfig_i686-native-linuxapp-icc b/config/defconfig_i686-native-linuxapp-icc
index 269e88e95..46ffb11ed 100644
--- a/config/defconfig_i686-native-linuxapp-icc
+++ b/config/defconfig_i686-native-linuxapp-icc
@@ -47,11 +47,6 @@ CONFIG_RTE_TOOLCHAIN_ICC=y
 CONFIG_RTE_LIBRTE_KNI=n
 
 #
-# Vectorized PMD is not supported on 32-bit
-#
-CONFIG_RTE_IXGBE_INC_VECTOR=n
-
-#
 # Solarflare PMD is not supported on 32-bit
 #
 CONFIG_RTE_LIBRTE_SFC_EFX_PMD=n
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'net/bnx2x: fix for PCI FLR after ungraceful exit' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
                   ` (16 preceding siblings ...)
  2018-05-06  6:36 ` [dpdk-stable] patch 'net/ixgbe: enable vector PMD for icc 32 bits' " Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'net/bnxt: avoid invalid vnic id in set L2 Rx mask' " Yuanhan Liu
                   ` (6 subsequent siblings)
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Rasesh Mody; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From 9e492ac6e7b204b97b13aaa102649f143aa54c0b Mon Sep 17 00:00:00 2001
From: Rasesh Mody <rasesh.mody@qlogic.com>
Date: Wed, 18 Apr 2018 13:15:08 -0700
Subject: [PATCH] net/bnx2x: fix for PCI FLR after ungraceful exit

[ upstream commit 66ba596aa6b5750b16549a322ef9a09fa7f0e3f6 ]

This patch provides a fix for PCI function level reset after an
ungraceful exit from an application. The fix is to enable internal
target read as part of device attach before getting device information
from device config space, device itself and shared memory. In addition
to that, add a 200ms delay for the recovery flow to complete.

Fixes: 540a211084a7 ("bnx2x: driver core")

Signed-off-by: Rasesh Mody <rasesh.mody@qlogic.com>
---
 drivers/net/bnx2x/bnx2x.c | 24 ++++++++++++------------
 1 file changed, 12 insertions(+), 12 deletions(-)

diff --git a/drivers/net/bnx2x/bnx2x.c b/drivers/net/bnx2x/bnx2x.c
index 9394f6c50..7927d2a67 100644
--- a/drivers/net/bnx2x/bnx2x.c
+++ b/drivers/net/bnx2x/bnx2x.c
@@ -8289,16 +8289,6 @@ static int bnx2x_get_device_info(struct bnx2x_softc *sc)
 			REG_WR(sc, PXP2_REG_PGL_ADDR_90_F1, 0);
 			REG_WR(sc, PXP2_REG_PGL_ADDR_94_F1, 0);
 		}
-
-/*
- * Enable internal target-read (in case we are probed after PF
- * FLR). Must be done prior to any BAR read access. Only for
- * 57712 and up
- */
-		if (!CHIP_IS_E1x(sc)) {
-			REG_WR(sc, PGLUE_B_REG_INTERNAL_PFID_ENABLE_TARGET_READ,
-			       1);
-		}
 	}
 
 	/* get the nvram size */
@@ -9675,7 +9665,17 @@ int bnx2x_attach(struct bnx2x_softc *sc)
 	bnx2x_init_rte(sc);
 
 	if (IS_PF(sc)) {
-/* get device info and set params */
+		/* Enable internal target-read (in case we are probed after PF
+		 * FLR). Must be done prior to any BAR read access. Only for
+		 * 57712 and up
+		 */
+		if (!CHIP_IS_E1x(sc)) {
+			REG_WR(sc, PGLUE_B_REG_INTERNAL_PFID_ENABLE_TARGET_READ,
+			       1);
+			DELAY(200000);
+		}
+
+		/* get device info and set params */
 		if (bnx2x_get_device_info(sc) != 0) {
 			PMD_DRV_LOG(NOTICE, "getting device info");
 			return -ENXIO;
@@ -9684,7 +9684,7 @@ int bnx2x_attach(struct bnx2x_softc *sc)
 /* get phy settings from shmem and 'and' against admin settings */
 		bnx2x_get_phy_info(sc);
 	} else {
-/* Left mac of VF unfilled, PF should set it for VF */
+		/* Left mac of VF unfilled, PF should set it for VF */
 		memset(sc->link_params.mac_addr, 0, ETHER_ADDR_LEN);
 	}
 
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'net/bnxt: avoid invalid vnic id in set L2 Rx mask' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
                   ` (17 preceding siblings ...)
  2018-05-06  6:36 ` [dpdk-stable] patch 'net/bnx2x: fix for PCI FLR after ungraceful exit' " Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'app/testpmd: fix command token' " Yuanhan Liu
                   ` (5 subsequent siblings)
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Ajit Khaparde; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From f18d545e659b0ad798f4e9784bedf473bbed2ccb Mon Sep 17 00:00:00 2001
From: Ajit Khaparde <ajit.khaparde@broadcom.com>
Date: Fri, 20 Apr 2018 07:22:01 -0700
Subject: [PATCH] net/bnxt: avoid invalid vnic id in set L2 Rx mask

[ upstream commit 1b533790f44ee160bae86bdcc5307d7b52225726 ]

In some cases bnxt_hwrm_cfa_l2_set_rx_mask is being called before
VNICs are allocated. The FW returns an error in such cases.
Move bnxt_init_nic to bnxt_dev_init such that the ids are initialized
to an invalid id.
Prevent sending the command to the FW only with a valid vnic id.

Fixes: 244bc98b0da7 ("net/bnxt: set L2 Rx mask")

Signed-off-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
---
 drivers/net/bnxt/bnxt_ethdev.c | 7 ++-----
 drivers/net/bnxt/bnxt_hwrm.c   | 3 +++
 2 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/net/bnxt/bnxt_ethdev.c b/drivers/net/bnxt/bnxt_ethdev.c
index 049afd0bf..b011f437f 100644
--- a/drivers/net/bnxt/bnxt_ethdev.c
+++ b/drivers/net/bnxt/bnxt_ethdev.c
@@ -400,10 +400,6 @@ static int bnxt_init_nic(struct bnxt *bp)
 	bnxt_init_vnics(bp);
 	bnxt_init_filters(bp);
 
-	rc = bnxt_init_chip(bp);
-	if (rc)
-		return rc;
-
 	return 0;
 }
 
@@ -573,7 +569,7 @@ static int bnxt_dev_start_op(struct rte_eth_dev *eth_dev)
 	}
 	bp->dev_stopped = 0;
 
-	rc = bnxt_init_nic(bp);
+	rc = bnxt_init_chip(bp);
 	if (rc)
 		goto error;
 
@@ -3058,6 +3054,7 @@ skip_init:
 		goto error_free_int;
 
 	bnxt_enable_int(bp);
+	bnxt_init_nic(bp);
 
 	return 0;
 
diff --git a/drivers/net/bnxt/bnxt_hwrm.c b/drivers/net/bnxt/bnxt_hwrm.c
index 120043d2f..5018d3511 100644
--- a/drivers/net/bnxt/bnxt_hwrm.c
+++ b/drivers/net/bnxt/bnxt_hwrm.c
@@ -252,6 +252,9 @@ int bnxt_hwrm_cfa_l2_set_rx_mask(struct bnxt *bp,
 	struct hwrm_cfa_l2_set_rx_mask_output *resp = bp->hwrm_cmd_resp_addr;
 	uint32_t mask = 0;
 
+	if (vnic->fw_vnic_id == INVALID_HW_RING_ID)
+		return rc;
+
 	HWRM_PREP(req, CFA_L2_SET_RX_MASK);
 	req.vnic_id = rte_cpu_to_le_16(vnic->fw_vnic_id);
 
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'app/testpmd: fix command token' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
                   ` (18 preceding siblings ...)
  2018-05-06  6:36 ` [dpdk-stable] patch 'net/bnxt: avoid invalid vnic id in set L2 Rx mask' " Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'net/nfp: fix mbufs releasing when stop or close' " Yuanhan Liu
                   ` (4 subsequent siblings)
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Qi Zhang; +Cc: Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From 9ade31d84dda22e9d8d817d3368b04eca5aacf50 Mon Sep 17 00:00:00 2001
From: Qi Zhang <qi.z.zhang@intel.com>
Date: Tue, 24 Apr 2018 13:59:57 +0800
Subject: [PATCH] app/testpmd: fix command token

[ upstream commit 4c53d4eaf11551c69201b192a7da153d1d88a9a5 ]

Correct token for queue start stop command.

Fixes: 5f4ec54f1d16 ("testpmd: queue start and stop")

Signed-off-by: Qi Zhang <qi.z.zhang@intel.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
 app/test-pmd/cmdline.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/app/test-pmd/cmdline.c b/app/test-pmd/cmdline.c
index b3c3f2419..77c11b841 100644
--- a/app/test-pmd/cmdline.c
+++ b/app/test-pmd/cmdline.c
@@ -2127,7 +2127,7 @@ cmdline_parse_inst_t cmd_config_rxtx_queue = {
 	.data = NULL,
 	.help_str = "port <port_id> rxq|txq <queue_id> start|stop",
 	.tokens = {
-		(void *)&cmd_config_speed_all_port,
+		(void *)&cmd_config_rxtx_queue_port,
 		(void *)&cmd_config_rxtx_queue_portid,
 		(void *)&cmd_config_rxtx_queue_rxtxq,
 		(void *)&cmd_config_rxtx_queue_qid,
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'net/nfp: fix mbufs releasing when stop or close' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
                   ` (19 preceding siblings ...)
  2018-05-06  6:36 ` [dpdk-stable] patch 'app/testpmd: fix command token' " Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'net/tap: fix icc build' " Yuanhan Liu
                   ` (3 subsequent siblings)
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Alejandro Lucero; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From 26e8845b2614eca8942a157870ba2627fce1df6c Mon Sep 17 00:00:00 2001
From: Alejandro Lucero <alejandro.lucero@netronome.com>
Date: Mon, 23 Apr 2018 12:23:58 +0100
Subject: [PATCH] net/nfp: fix mbufs releasing when stop or close

[ upstream commit 0c0e46c36bcc5dfe9d2aa605e1a5f714d45e0b7f ]

PMDs have the responsibility of releasing mbufs sent through xmit burst
function. NFP PMD attaches those sent mbufs to the TX ring structure,
and it is at the next time a specific ring descriptor is going to be
used when the previous linked mbuf, already transmitted at that point,
is released. Those mbufs belonging to a chained mbuf got its own link
to a ring descriptor, and they are released independently of the mbuf
head of that chain.

The problem is how those mbufs are released when the PMD is stopped or
closed. Instead of releasing those mbufs as the xmit functions does,
this is independently of being in a mbuf chain, the code calls
rte_pktmbuf_free which will release not just the mbuf head in that
chain but all the chained mbufs. The loop will try to release those
mbufs which have already been released again when chained mbufs exist.

This patch fixes the problem using rte_pktmbuf_free_seg instead.

Fixes: b812daadad0d ("nfp: add Rx and Tx")

Signed-off-by: Alejandro Lucero <alejandro.lucero@netronome.com>
---
 drivers/net/nfp/nfp_net.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/nfp/nfp_net.c b/drivers/net/nfp/nfp_net.c
index cfb357b91..d9cd04732 100644
--- a/drivers/net/nfp/nfp_net.c
+++ b/drivers/net/nfp/nfp_net.c
@@ -301,7 +301,7 @@ nfp_net_tx_queue_release_mbufs(struct nfp_net_txq *txq)
 
 	for (i = 0; i < txq->tx_count; i++) {
 		if (txq->txbufs[i].mbuf) {
-			rte_pktmbuf_free(txq->txbufs[i].mbuf);
+			rte_pktmbuf_free_seg(txq->txbufs[i].mbuf);
 			txq->txbufs[i].mbuf = NULL;
 		}
 	}
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'net/tap: fix icc build' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
                   ` (20 preceding siblings ...)
  2018-05-06  6:36 ` [dpdk-stable] patch 'net/nfp: fix mbufs releasing when stop or close' " Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'drivers/net: fix link autoneg value for virtual PMDs' " Yuanhan Liu
                   ` (2 subsequent siblings)
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Ferruh Yigit; +Cc: Pablo de Lara, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From 3ef1c8cf9c642c21c20e17bf41e19433fc8c2809 Mon Sep 17 00:00:00 2001
From: Ferruh Yigit <ferruh.yigit@intel.com>
Date: Mon, 12 Mar 2018 19:31:33 +0000
Subject: [PATCH] net/tap: fix icc build

[ upstream commit 6db80eb7c97e7db9c006641cc7ecae46c625d64e ]

build error:
.../dpdk/drivers/net/tap/rte_eth_tap.c(598):
error #279: controlling expression is constant
	RTE_ASSERT(!"unsupported request type: must not happen");

Although RTE_ASSERT helps debugging this issue when assert enabled,
constant expression in assert means this path can be taken during
runtime and there is no protection against it when assert is disabled.

Adding error log and error return back, replacing RTE_ASSERT.

Fixes: 7748a4b44196 ("net/tap: add debug messages")

Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
---
 drivers/net/tap/rte_eth_tap.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/net/tap/rte_eth_tap.c b/drivers/net/tap/rte_eth_tap.c
index b8187f9b2..bf5506e4b 100644
--- a/drivers/net/tap/rte_eth_tap.c
+++ b/drivers/net/tap/rte_eth_tap.c
@@ -544,7 +544,9 @@ apply:
 	case SIOCSIFMTU:
 		break;
 	default:
-		RTE_ASSERT(!"unsupported request type: must not happen");
+		RTE_LOG(WARNING, PMD, "%s: ioctl() called with wrong arg\n",
+			pmd->name);
+		return -EINVAL;
 	}
 	if (ioctl(pmd->ioctl_sock, request, ifr) < 0)
 		goto error;
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'drivers/net: fix link autoneg value for virtual PMDs' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
                   ` (21 preceding siblings ...)
  2018-05-06  6:36 ` [dpdk-stable] patch 'net/tap: fix icc build' " Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'net/sfc: process RSS settings on Rx configure step' " Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'net/sfc: ignore spec bits not covered by mask' " Yuanhan Liu
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Ferruh Yigit; +Cc: Thomas Monjalon, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From 1bb4b0ec227b7e51d52a16065d835ce650c57d57 Mon Sep 17 00:00:00 2001
From: Ferruh Yigit <ferruh.yigit@intel.com>
Date: Fri, 20 Apr 2018 01:01:24 +0100
Subject: [PATCH] drivers/net: fix link autoneg value for virtual PMDs

[ upstream commit 18869f97f163a58d29d45a2e85c6ed444b1c72e1 ]

These drivers never attempt link speed negotiation. Change link_autoneg
value to ETH_LINK_FIXED to be more accurate and consistent between PMDs.

Fixes: 1e3a958f40b3 ("ethdev: fix link autonegotiation value")

Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
Acked-by: Thomas Monjalon <thomas@monjalon.net>
---
 drivers/net/af_packet/rte_eth_af_packet.c | 2 +-
 drivers/net/kni/rte_eth_kni.c             | 2 +-
 drivers/net/null/rte_eth_null.c           | 2 +-
 drivers/net/pcap/rte_eth_pcap.c           | 2 +-
 drivers/net/ring/rte_eth_ring.c           | 2 +-
 drivers/net/softnic/rte_eth_softnic.c     | 2 +-
 drivers/net/tap/rte_eth_tap.c             | 2 +-
 7 files changed, 7 insertions(+), 7 deletions(-)

diff --git a/drivers/net/af_packet/rte_eth_af_packet.c b/drivers/net/af_packet/rte_eth_af_packet.c
index d51540898..5a101cef9 100644
--- a/drivers/net/af_packet/rte_eth_af_packet.c
+++ b/drivers/net/af_packet/rte_eth_af_packet.c
@@ -124,7 +124,7 @@ static struct rte_eth_link pmd_link = {
 	.link_speed = ETH_SPEED_NUM_10G,
 	.link_duplex = ETH_LINK_FULL_DUPLEX,
 	.link_status = ETH_LINK_DOWN,
-	.link_autoneg = ETH_LINK_AUTONEG
+	.link_autoneg = ETH_LINK_FIXED,
 };
 
 static uint16_t
diff --git a/drivers/net/kni/rte_eth_kni.c b/drivers/net/kni/rte_eth_kni.c
index c1a2ea51d..5c7950117 100644
--- a/drivers/net/kni/rte_eth_kni.c
+++ b/drivers/net/kni/rte_eth_kni.c
@@ -90,7 +90,7 @@ static const struct rte_eth_link pmd_link = {
 		.link_speed = ETH_SPEED_NUM_10G,
 		.link_duplex = ETH_LINK_FULL_DUPLEX,
 		.link_status = ETH_LINK_DOWN,
-		.link_autoneg = ETH_LINK_AUTONEG,
+		.link_autoneg = ETH_LINK_FIXED,
 };
 static int is_kni_initialized;
 
diff --git a/drivers/net/null/rte_eth_null.c b/drivers/net/null/rte_eth_null.c
index 726a5c5e4..7a5f12570 100644
--- a/drivers/net/null/rte_eth_null.c
+++ b/drivers/net/null/rte_eth_null.c
@@ -91,7 +91,7 @@ static struct rte_eth_link pmd_link = {
 	.link_speed = ETH_SPEED_NUM_10G,
 	.link_duplex = ETH_LINK_FULL_DUPLEX,
 	.link_status = ETH_LINK_DOWN,
-	.link_autoneg = ETH_LINK_AUTONEG,
+	.link_autoneg = ETH_LINK_FIXED,
 };
 
 static uint16_t
diff --git a/drivers/net/pcap/rte_eth_pcap.c b/drivers/net/pcap/rte_eth_pcap.c
index 3385d0439..39947105b 100644
--- a/drivers/net/pcap/rte_eth_pcap.c
+++ b/drivers/net/pcap/rte_eth_pcap.c
@@ -124,7 +124,7 @@ static struct rte_eth_link pmd_link = {
 		.link_speed = ETH_SPEED_NUM_10G,
 		.link_duplex = ETH_LINK_FULL_DUPLEX,
 		.link_status = ETH_LINK_DOWN,
-		.link_autoneg = ETH_LINK_AUTONEG,
+		.link_autoneg = ETH_LINK_FIXED,
 };
 
 static int
diff --git a/drivers/net/ring/rte_eth_ring.c b/drivers/net/ring/rte_eth_ring.c
index 8583a6735..dbd350e18 100644
--- a/drivers/net/ring/rte_eth_ring.c
+++ b/drivers/net/ring/rte_eth_ring.c
@@ -89,7 +89,7 @@ static struct rte_eth_link pmd_link = {
 		.link_speed = ETH_SPEED_NUM_10G,
 		.link_duplex = ETH_LINK_FULL_DUPLEX,
 		.link_status = ETH_LINK_DOWN,
-		.link_autoneg = ETH_LINK_AUTONEG
+		.link_autoneg = ETH_LINK_FIXED,
 };
 
 static uint16_t
diff --git a/drivers/net/softnic/rte_eth_softnic.c b/drivers/net/softnic/rte_eth_softnic.c
index c8f918df1..3c695e4da 100644
--- a/drivers/net/softnic/rte_eth_softnic.c
+++ b/drivers/net/softnic/rte_eth_softnic.c
@@ -551,7 +551,7 @@ pmd_ethdev_register(struct rte_vdev_device *vdev,
 	soft_dev->data->dev_private = dev_private;
 	soft_dev->data->dev_link.link_speed = hard_speed;
 	soft_dev->data->dev_link.link_duplex = ETH_LINK_FULL_DUPLEX;
-	soft_dev->data->dev_link.link_autoneg = ETH_LINK_AUTONEG;
+	soft_dev->data->dev_link.link_autoneg = ETH_LINK_FIXED;
 	soft_dev->data->dev_link.link_status = ETH_LINK_DOWN;
 	soft_dev->data->mac_addrs = &eth_addr;
 	soft_dev->data->promiscuous = 1;
diff --git a/drivers/net/tap/rte_eth_tap.c b/drivers/net/tap/rte_eth_tap.c
index bf5506e4b..c38c02ef1 100644
--- a/drivers/net/tap/rte_eth_tap.c
+++ b/drivers/net/tap/rte_eth_tap.c
@@ -95,7 +95,7 @@ static struct rte_eth_link pmd_link = {
 	.link_speed = ETH_SPEED_NUM_10G,
 	.link_duplex = ETH_LINK_FULL_DUPLEX,
 	.link_status = ETH_LINK_DOWN,
-	.link_autoneg = ETH_LINK_AUTONEG
+	.link_autoneg = ETH_LINK_FIXED,
 };
 
 static void
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'net/sfc: process RSS settings on Rx configure step' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
                   ` (22 preceding siblings ...)
  2018-05-06  6:36 ` [dpdk-stable] patch 'drivers/net: fix link autoneg value for virtual PMDs' " Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  2018-05-06  6:36 ` [dpdk-stable] patch 'net/sfc: ignore spec bits not covered by mask' " Yuanhan Liu
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Ivan Malov; +Cc: Andrew Rybchenko, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From ec3882def363854ef1c2393e76cbe13a972d28ca Mon Sep 17 00:00:00 2001
From: Ivan Malov <ivan.malov@oktetlabs.ru>
Date: Wed, 25 Apr 2018 18:51:41 +0100
Subject: [PATCH] net/sfc: process RSS settings on Rx configure step

[ upstream commit 7803554a9e388538fc3ad32dedffbbe2dde055c8 ]

One may submit advanced RSS settings as part of
rte_eth_conf to customise RSS configuration from
the very beginning. Currently the driver does not
check that piece of settings and proceeds with
default choices for RSS hash functions and RSS key.

This patch implements the required processing.

Fixes: 4ec1fc3ba881 ("net/sfc: add basic stubs for RSS support on driver attach")

Signed-off-by: Ivan Malov <ivan.malov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
---
 drivers/net/sfc/sfc_rx.c | 42 ++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 42 insertions(+)

diff --git a/drivers/net/sfc/sfc_rx.c b/drivers/net/sfc/sfc_rx.c
index be778d387..8fc93d682 100644
--- a/drivers/net/sfc/sfc_rx.c
+++ b/drivers/net/sfc/sfc_rx.c
@@ -1096,6 +1096,41 @@ sfc_efx_to_rte_hash_type(efx_rx_hash_type_t efx_hash_types)
 
 #if EFSYS_OPT_RX_SCALE
 static int
+sfc_rx_process_adv_conf_rss(struct sfc_adapter *sa,
+			    struct rte_eth_rss_conf *conf)
+{
+	efx_rx_hash_type_t efx_hash_types = sa->rss_hash_types;
+
+	if (sa->rss_support != EFX_RX_SCALE_EXCLUSIVE) {
+		if ((conf->rss_hf != 0 && conf->rss_hf != SFC_RSS_OFFLOADS) ||
+		    conf->rss_key != NULL)
+			return EINVAL;
+	}
+
+	if (conf->rss_hf != 0) {
+		if ((conf->rss_hf & ~SFC_RSS_OFFLOADS) != 0) {
+			sfc_err(sa, "unsupported hash functions requested");
+			return EINVAL;
+		}
+
+		efx_hash_types = sfc_rte_to_efx_hash_type(conf->rss_hf);
+	}
+
+	if (conf->rss_key != NULL) {
+		if (conf->rss_key_len != sizeof(sa->rss_key)) {
+			sfc_err(sa, "RSS key size is wrong (should be %lu)",
+				sizeof(sa->rss_key));
+			return EINVAL;
+		}
+		rte_memcpy(sa->rss_key, conf->rss_key, sizeof(sa->rss_key));
+	}
+
+	sa->rss_hash_types = efx_hash_types;
+
+	return 0;
+}
+
+static int
 sfc_rx_rss_config(struct sfc_adapter *sa)
 {
 	int rc = 0;
@@ -1347,16 +1382,23 @@ sfc_rx_configure(struct sfc_adapter *sa)
 			   MIN(sa->rxq_count, EFX_MAXRSS) : 0;
 
 	if (sa->rss_channels > 0) {
+		struct rte_eth_rss_conf *adv_conf_rss;
 		unsigned int sw_index;
 
 		for (sw_index = 0; sw_index < EFX_RSS_TBL_SIZE; ++sw_index)
 			sa->rss_tbl[sw_index] = sw_index % sa->rss_channels;
+
+		adv_conf_rss = &dev_conf->rx_adv_conf.rss_conf;
+		rc = sfc_rx_process_adv_conf_rss(sa, adv_conf_rss);
+		if (rc != 0)
+			goto fail_rx_process_adv_conf_rss;
 	}
 #endif
 
 done:
 	return 0;
 
+fail_rx_process_adv_conf_rss:
 fail_rx_qinit_info:
 fail_rxqs_realloc:
 fail_rxqs_alloc:
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

* [dpdk-stable] patch 'net/sfc: ignore spec bits not covered by mask' has been queued to LTS release 17.11.3
  2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
                   ` (23 preceding siblings ...)
  2018-05-06  6:36 ` [dpdk-stable] patch 'net/sfc: process RSS settings on Rx configure step' " Yuanhan Liu
@ 2018-05-06  6:36 ` Yuanhan Liu
  24 siblings, 0 replies; 26+ messages in thread
From: Yuanhan Liu @ 2018-05-06  6:36 UTC (permalink / raw)
  To: Andrew Rybchenko; +Cc: Andy Moreton, Roman Zhukov, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.3

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/09/18. So please
shout if anyone has objections.

Thanks.

	--yliu

---
>From c3ec08aed095f45c21ebd4cb6d9d920d57e0ccdf Mon Sep 17 00:00:00 2001
From: Andrew Rybchenko <arybchenko@solarflare.com>
Date: Wed, 25 Apr 2018 18:18:34 +0100
Subject: [PATCH] net/sfc: ignore spec bits not covered by mask

[ upstream commit c43e0f690413fc7233b735e641f22e8eb47c50c0 ]

mask is a simple bit-mask applied before interpreting the contents
of spec and last.

Fixes: a9825ccf5bb8 ("net/sfc: support flow API filters")

Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Andy Moreton <amoreton@solarflare.com>
Reviewed-by: Roman Zhukov <roman.zhukov@oktetlabs.ru>
---
 drivers/net/sfc/sfc_flow.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/net/sfc/sfc_flow.c b/drivers/net/sfc/sfc_flow.c
index e770b98e8..fddc6706b 100644
--- a/drivers/net/sfc/sfc_flow.c
+++ b/drivers/net/sfc/sfc_flow.c
@@ -107,7 +107,6 @@ sfc_flow_parse_init(const struct rte_flow_item *item,
 	const uint8_t *spec;
 	const uint8_t *mask;
 	const uint8_t *last;
-	uint8_t match;
 	uint8_t supp;
 	unsigned int i;
 
@@ -168,12 +167,11 @@ sfc_flow_parse_init(const struct rte_flow_item *item,
 		return -rte_errno;
 	}
 
-	/* Check that mask and spec not asks for more match than supp_mask */
+	/* Check that mask does not ask for more match than supp_mask */
 	for (i = 0; i < size; i++) {
-		match = spec[i] | mask[i];
 		supp = ((const uint8_t *)supp_mask)[i];
 
-		if ((match | supp) != supp) {
+		if (~supp & mask[i]) {
 			rte_flow_error_set(error, ENOTSUP,
 					   RTE_FLOW_ERROR_TYPE_ITEM, item,
 					   "Item's field is not supported");
-- 
2.11.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

end of thread, other threads:[~2018-05-06  6:38 UTC | newest]

Thread overview: 26+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-05-06  6:36 [dpdk-stable] patch 'mbuf: fix Tx checksum offload API doc' has been queued to LTS release 17.11.3 Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'mbuf: improve tunnel Tx offloads " Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'app/crypto-perf: fix excess crypto device error' " Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'examples/l2fwd-crypto: fix the default aead assignments' " Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'crypto/zuc: do not set default op status' " Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'crypto/zuc: batch ops with same transform' " Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'crypto/dpaa2_sec: fix HMAC supported digest sizes' " Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'mk: fix make defconfig on FreeBSD' " Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'mempool: fix leak when no objects are populated' " Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'test: fix memory flags test for low NUMA nodes number' " Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'test/mempool: fix autotest retry' " Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'bus/pci: fix find device implementation' " Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'net/sfc: add missing Rx fini on RSS setup fail path' " Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'net/bnxt: set padding flags in Rx descriptor' " Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'net/bnxt: fix endianness of flag' " Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'net/bnxt: fix Rx checksum flags for tunnel frames' " Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'net/bnxt: free memory allocated for VF filters' " Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'net/ixgbe: enable vector PMD for icc 32 bits' " Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'net/bnx2x: fix for PCI FLR after ungraceful exit' " Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'net/bnxt: avoid invalid vnic id in set L2 Rx mask' " Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'app/testpmd: fix command token' " Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'net/nfp: fix mbufs releasing when stop or close' " Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'net/tap: fix icc build' " Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'drivers/net: fix link autoneg value for virtual PMDs' " Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'net/sfc: process RSS settings on Rx configure step' " Yuanhan Liu
2018-05-06  6:36 ` [dpdk-stable] patch 'net/sfc: ignore spec bits not covered by mask' " Yuanhan Liu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).