patches for DPDK stable branches
 help / color / mirror / Atom feed
* [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5
@ 2019-01-03  8:13 Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'eal: explicit cast of core id when getting index' " Yongseok Koh
                   ` (35 more replies)
  0 siblings, 36 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Stephen Hemminger, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From 75a3b407cf469b17aad9bd2e8bb7f3defc9028e8 Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Sat, 12 May 2018 09:58:57 +0800
Subject: [PATCH] eal: explicit cast of builtin for bsf32

[ upstream commit 54a93341ccaaf3665352ddad0807cf3ed40c36f9 ]

rte_common.h:416:9:
warning: conversion to 'uint32_t' {aka 'unsigned int'} from
'int' may change the sign of the result [-Wsign-conversion]
  return __builtin_ctz(v);
         ^~~~~~~~~~~~~~~~

The builtin is defined to return int, but we want to
return it as uint32_t.  Its only defined valid return
values are positive integers or zero, which is OK for
uint32_t.  So just add an explicit cast.

Fixes: 03f6bced5bba ("eal: use intrinsic function")

Signed-off-by: Andy Green <andy@warmcat.com>
Reviewed-by: Stephen Hemminger <stephen@networkplumber.org>
---
 lib/librte_eal/common/include/rte_common.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/librte_eal/common/include/rte_common.h b/lib/librte_eal/common/include/rte_common.h
index f24cbe6e2..4485d634e 100644
--- a/lib/librte_eal/common/include/rte_common.h
+++ b/lib/librte_eal/common/include/rte_common.h
@@ -340,7 +340,7 @@ rte_align64pow2(uint64_t v)
 static inline uint32_t
 rte_bsf32(uint32_t v)
 {
-	return __builtin_ctz(v);
+	return (uint32_t)__builtin_ctz(v);
 }
 
 /**
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:12.158134897 -0800
+++ 0001-eal-explicit-cast-of-builtin-for-bsf32.patch	2019-01-02 23:59:11.998815000 -0800
@@ -1,8 +1,10 @@
-From 54a93341ccaaf3665352ddad0807cf3ed40c36f9 Mon Sep 17 00:00:00 2001
+From 75a3b407cf469b17aad9bd2e8bb7f3defc9028e8 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Sat, 12 May 2018 09:58:57 +0800
 Subject: [PATCH] eal: explicit cast of builtin for bsf32
 
+[ upstream commit 54a93341ccaaf3665352ddad0807cf3ed40c36f9 ]
+
 rte_common.h:416:9:
 warning: conversion to 'uint32_t' {aka 'unsigned int'} from
 'int' may change the sign of the result [-Wsign-conversion]
@@ -15,7 +17,6 @@
 uint32_t.  So just add an explicit cast.
 
 Fixes: 03f6bced5bba ("eal: use intrinsic function")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Reviewed-by: Stephen Hemminger <stephen@networkplumber.org>
@@ -24,10 +25,10 @@
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/lib/librte_eal/common/include/rte_common.h b/lib/librte_eal/common/include/rte_common.h
-index 69e5ed1e3..679f2f184 100644
+index f24cbe6e2..4485d634e 100644
 --- a/lib/librte_eal/common/include/rte_common.h
 +++ b/lib/librte_eal/common/include/rte_common.h
-@@ -413,7 +413,7 @@ rte_align64prevpow2(uint64_t v)
+@@ -340,7 +340,7 @@ rte_align64pow2(uint64_t v)
  static inline uint32_t
  rte_bsf32(uint32_t v)
  {

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

* [dpdk-stable] patch 'eal: explicit cast of core id when getting index' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'eal: declare trace buffer at top of own block' " Yongseok Koh
                   ` (34 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Stephen Hemminger, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From 8b24bc6e6ed66efab951df2c15fe0dd987dd4198 Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Sat, 12 May 2018 09:59:07 +0800
Subject: [PATCH] eal: explicit cast of core id when getting index

[ upstream commit ef3c7b50ff39a37a93ecea47481d392d8fcb2936 ]

rte_lcore.h: In function 'rte_lcore_index':
rte_lcore.h:122:14:
warning: conversion to 'int' from 'unsigned int' may change
the sign of the result [-Wsign-conversion]
   lcore_id = rte_lcore_id();

Fixes: 5583037a7950 ("eal: get relative core index")

Signed-off-by: Andy Green <andy@warmcat.com>
Reviewed-by: Stephen Hemminger <stephen@networkplumber.org>
---
 lib/librte_eal/common/include/rte_lcore.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/librte_eal/common/include/rte_lcore.h b/lib/librte_eal/common/include/rte_lcore.h
index 3735da0c7..0dd710de5 100644
--- a/lib/librte_eal/common/include/rte_lcore.h
+++ b/lib/librte_eal/common/include/rte_lcore.h
@@ -136,7 +136,7 @@ rte_lcore_index(int lcore_id)
 	if (lcore_id >= RTE_MAX_LCORE)
 		return -1;
 	if (lcore_id < 0)
-		lcore_id = rte_lcore_id();
+		lcore_id = (int)rte_lcore_id();
 	return lcore_config[lcore_id].core_index;
 }
 
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:12.213286850 -0800
+++ 0002-eal-explicit-cast-of-core-id-when-getting-index.patch	2019-01-02 23:59:12.001814000 -0800
@@ -1,8 +1,10 @@
-From ef3c7b50ff39a37a93ecea47481d392d8fcb2936 Mon Sep 17 00:00:00 2001
+From 8b24bc6e6ed66efab951df2c15fe0dd987dd4198 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Sat, 12 May 2018 09:59:07 +0800
 Subject: [PATCH] eal: explicit cast of core id when getting index
 
+[ upstream commit ef3c7b50ff39a37a93ecea47481d392d8fcb2936 ]
+
 rte_lcore.h: In function 'rte_lcore_index':
 rte_lcore.h:122:14:
 warning: conversion to 'int' from 'unsigned int' may change
@@ -10,7 +12,6 @@
    lcore_id = rte_lcore_id();
 
 Fixes: 5583037a7950 ("eal: get relative core index")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Reviewed-by: Stephen Hemminger <stephen@networkplumber.org>
@@ -19,10 +20,10 @@
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/lib/librte_eal/common/include/rte_lcore.h b/lib/librte_eal/common/include/rte_lcore.h
-index 1a2f37eaa..6e09d9181 100644
+index 3735da0c7..0dd710de5 100644
 --- a/lib/librte_eal/common/include/rte_lcore.h
 +++ b/lib/librte_eal/common/include/rte_lcore.h
-@@ -119,7 +119,7 @@ rte_lcore_index(int lcore_id)
+@@ -136,7 +136,7 @@ rte_lcore_index(int lcore_id)
  	if (lcore_id >= RTE_MAX_LCORE)
  		return -1;
  	if (lcore_id < 0)

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

* [dpdk-stable] patch 'eal: declare trace buffer at top of own block' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'eal: explicit cast of core id when getting index' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'spinlock/x86: move stack declaration before code' " Yongseok Koh
                   ` (33 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Stephen Hemminger, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From 7d236f3f9363bbf691c8ed7b534173d152d3fcaa Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Sat, 12 May 2018 09:59:32 +0800
Subject: [PATCH] eal: declare trace buffer at top of own block

[ upstream commit e3908132b7903dbbf45c6d073792cccc890812e0 ]

rte_dev.h:54:2:
warning: ISO C90 forbids mixed declarations and
code [-Wdeclaration-after-statement]
  char buffer[vsnprintf(NULL, 0, fmt, ap) + 1];

Fixes: b974e4a40cb5 ("ethdev: make error checking macros public")

Signed-off-by: Andy Green <andy@warmcat.com>
Reviewed-by: Stephen Hemminger <stephen@networkplumber.org>
---
 lib/librte_eal/common/include/rte_dev.h | 15 +++++++++------
 1 file changed, 9 insertions(+), 6 deletions(-)

diff --git a/lib/librte_eal/common/include/rte_dev.h b/lib/librte_eal/common/include/rte_dev.h
index 8088dcc53..bc6e5926f 100644
--- a/lib/librte_eal/common/include/rte_dev.h
+++ b/lib/librte_eal/common/include/rte_dev.h
@@ -60,15 +60,18 @@ rte_pmd_debug_trace(const char *func_name, const char *fmt, ...)
 
 	va_start(ap, fmt);
 
-	char buffer[vsnprintf(NULL, 0, fmt, ap) + 1];
+	{
+		char buffer[vsnprintf(NULL, 0, fmt, ap) + 1];
 
-	va_end(ap);
+		va_end(ap);
 
-	va_start(ap, fmt);
-	vsnprintf(buffer, sizeof(buffer), fmt, ap);
-	va_end(ap);
+		va_start(ap, fmt);
+		vsnprintf(buffer, sizeof(buffer), fmt, ap);
+		va_end(ap);
 
-	rte_log(RTE_LOG_ERR, RTE_LOGTYPE_PMD, "%s: %s", func_name, buffer);
+		rte_log(RTE_LOG_ERR, RTE_LOGTYPE_PMD, "%s: %s",
+			func_name, buffer);
+	}
 }
 
 /*
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:12.265616323 -0800
+++ 0003-eal-declare-trace-buffer-at-top-of-own-block.patch	2019-01-02 23:59:12.004814000 -0800
@@ -1,15 +1,16 @@
-From e3908132b7903dbbf45c6d073792cccc890812e0 Mon Sep 17 00:00:00 2001
+From 7d236f3f9363bbf691c8ed7b534173d152d3fcaa Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Sat, 12 May 2018 09:59:32 +0800
 Subject: [PATCH] eal: declare trace buffer at top of own block
 
+[ upstream commit e3908132b7903dbbf45c6d073792cccc890812e0 ]
+
 rte_dev.h:54:2:
 warning: ISO C90 forbids mixed declarations and
 code [-Wdeclaration-after-statement]
   char buffer[vsnprintf(NULL, 0, fmt, ap) + 1];
 
 Fixes: b974e4a40cb5 ("ethdev: make error checking macros public")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Reviewed-by: Stephen Hemminger <stephen@networkplumber.org>
@@ -18,10 +19,10 @@
  1 file changed, 9 insertions(+), 6 deletions(-)
 
 diff --git a/lib/librte_eal/common/include/rte_dev.h b/lib/librte_eal/common/include/rte_dev.h
-index 0955e9adb..3879ff3ca 100644
+index 8088dcc53..bc6e5926f 100644
 --- a/lib/librte_eal/common/include/rte_dev.h
 +++ b/lib/librte_eal/common/include/rte_dev.h
-@@ -51,15 +51,18 @@ rte_pmd_debug_trace(const char *func_name, const char *fmt, ...)
+@@ -60,15 +60,18 @@ rte_pmd_debug_trace(const char *func_name, const char *fmt, ...)
  
  	va_start(ap, fmt);
  

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

* [dpdk-stable] patch 'spinlock/x86: move stack declaration before code' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'eal: explicit cast of core id when getting index' " Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'eal: declare trace buffer at top of own block' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'net: move stack variable at top of VLAN strip function' " Yongseok Koh
                   ` (32 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Stephen Hemminger, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From 4a87afb90a3197866ad0676029c999ac26e95030 Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Sat, 12 May 2018 09:59:17 +0800
Subject: [PATCH] spinlock/x86: move stack declaration before code

[ upstream commit f7f18e92a51276f1e23a0595f59615f79323b358 ]

In function 'rte_try_tm':
rte_spinlock.h:82:2:
warning: ISO C90 forbids mixed declarations and code
[-Wdeclaration-after-statement]
  int retries = RTE_RTM_MAX_RETRIES;

Fixes: ba7468997ea6 ("spinlock: add HTM lock elision for x86")

Signed-off-by: Andy Green <andy@warmcat.com>
Reviewed-by: Stephen Hemminger <stephen@networkplumber.org>
---
 lib/librte_eal/common/include/arch/x86/rte_spinlock.h | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/lib/librte_eal/common/include/arch/x86/rte_spinlock.h b/lib/librte_eal/common/include/arch/x86/rte_spinlock.h
index 5675c2b45..10cd7a30c 100644
--- a/lib/librte_eal/common/include/arch/x86/rte_spinlock.h
+++ b/lib/librte_eal/common/include/arch/x86/rte_spinlock.h
@@ -105,10 +105,12 @@ static inline int rte_tm_supported(void)
 static inline int
 rte_try_tm(volatile int *lock)
 {
+	int retries;
+
 	if (!rte_rtm_supported)
 		return 0;
 
-	int retries = RTE_RTM_MAX_RETRIES;
+	retries = RTE_RTM_MAX_RETRIES;
 
 	while (likely(retries--)) {
 
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:12.316305572 -0800
+++ 0004-spinlock-x86-move-stack-declaration-before-code.patch	2019-01-02 23:59:12.006815000 -0800
@@ -1,8 +1,10 @@
-From f7f18e92a51276f1e23a0595f59615f79323b358 Mon Sep 17 00:00:00 2001
+From 4a87afb90a3197866ad0676029c999ac26e95030 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Sat, 12 May 2018 09:59:17 +0800
 Subject: [PATCH] spinlock/x86: move stack declaration before code
 
+[ upstream commit f7f18e92a51276f1e23a0595f59615f79323b358 ]
+
 In function 'rte_try_tm':
 rte_spinlock.h:82:2:
 warning: ISO C90 forbids mixed declarations and code
@@ -10,7 +12,6 @@
   int retries = RTE_RTM_MAX_RETRIES;
 
 Fixes: ba7468997ea6 ("spinlock: add HTM lock elision for x86")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Reviewed-by: Stephen Hemminger <stephen@networkplumber.org>
@@ -19,10 +20,10 @@
  1 file changed, 3 insertions(+), 1 deletion(-)
 
 diff --git a/lib/librte_eal/common/include/arch/x86/rte_spinlock.h b/lib/librte_eal/common/include/arch/x86/rte_spinlock.h
-index 4b16887ea..60321da02 100644
+index 5675c2b45..10cd7a30c 100644
 --- a/lib/librte_eal/common/include/arch/x86/rte_spinlock.h
 +++ b/lib/librte_eal/common/include/arch/x86/rte_spinlock.h
-@@ -76,10 +76,12 @@ static inline int rte_tm_supported(void)
+@@ -105,10 +105,12 @@ static inline int rte_tm_supported(void)
  static inline int
  rte_try_tm(volatile int *lock)
  {

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

* [dpdk-stable] patch 'net: move stack variable at top of VLAN strip function' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (2 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'spinlock/x86: move stack declaration before code' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'ethdev: explicit cast of buffered Tx number' " Yongseok Koh
                   ` (31 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Stephen Hemminger, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From e6dbcd545129600cd8ed4cc29dc5a3f5dd96e586 Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Sat, 12 May 2018 10:00:17 +0800
Subject: [PATCH] net: move stack variable at top of VLAN strip function

[ upstream commit 5a7e5accc695e5cf0ed840f59042dba4cbe0aae3 ]

In function 'rte_vlan_strip':
rte_ether.h:357:2:
warning: ISO C90 forbids mixed declarations and code
[-Wdeclaration-after-statement]
  struct vlan_hdr *vh = (struct vlan_hdr *)(eh + 1);

Fixes: c974021a5949 ("ether: add soft vlan encap/decap")

Signed-off-by: Andy Green <andy@warmcat.com>
Reviewed-by: Stephen Hemminger <stephen@networkplumber.org>
---
 lib/librte_net/rte_ether.h | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/lib/librte_net/rte_ether.h b/lib/librte_net/rte_ether.h
index 06d7b486c..10d906e6f 100644
--- a/lib/librte_net/rte_ether.h
+++ b/lib/librte_net/rte_ether.h
@@ -353,11 +353,12 @@ static inline int rte_vlan_strip(struct rte_mbuf *m)
 {
 	struct ether_hdr *eh
 		 = rte_pktmbuf_mtod(m, struct ether_hdr *);
+	struct vlan_hdr *vh;
 
 	if (eh->ether_type != rte_cpu_to_be_16(ETHER_TYPE_VLAN))
 		return -1;
 
-	struct vlan_hdr *vh = (struct vlan_hdr *)(eh + 1);
+	vh = (struct vlan_hdr *)(eh + 1);
 	m->ol_flags |= PKT_RX_VLAN | PKT_RX_VLAN_STRIPPED;
 	m->vlan_tci = rte_be_to_cpu_16(vh->vlan_tci);
 
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:12.373693797 -0800
+++ 0005-net-move-stack-variable-at-top-of-VLAN-strip-functio.patch	2019-01-02 23:59:12.008819000 -0800
@@ -1,8 +1,10 @@
-From 5a7e5accc695e5cf0ed840f59042dba4cbe0aae3 Mon Sep 17 00:00:00 2001
+From e6dbcd545129600cd8ed4cc29dc5a3f5dd96e586 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Sat, 12 May 2018 10:00:17 +0800
 Subject: [PATCH] net: move stack variable at top of VLAN strip function
 
+[ upstream commit 5a7e5accc695e5cf0ed840f59042dba4cbe0aae3 ]
+
 In function 'rte_vlan_strip':
 rte_ether.h:357:2:
 warning: ISO C90 forbids mixed declarations and code
@@ -10,7 +12,6 @@
   struct vlan_hdr *vh = (struct vlan_hdr *)(eh + 1);
 
 Fixes: c974021a5949 ("ether: add soft vlan encap/decap")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Reviewed-by: Stephen Hemminger <stephen@networkplumber.org>
@@ -19,10 +20,10 @@
  1 file changed, 2 insertions(+), 1 deletion(-)
 
 diff --git a/lib/librte_net/rte_ether.h b/lib/librte_net/rte_ether.h
-index 95d0a533f..27c919594 100644
+index 06d7b486c..10d906e6f 100644
 --- a/lib/librte_net/rte_ether.h
 +++ b/lib/librte_net/rte_ether.h
-@@ -350,11 +350,12 @@ static inline int rte_vlan_strip(struct rte_mbuf *m)
+@@ -353,11 +353,12 @@ static inline int rte_vlan_strip(struct rte_mbuf *m)
  {
  	struct ether_hdr *eh
  		 = rte_pktmbuf_mtod(m, struct ether_hdr *);

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

* [dpdk-stable] patch 'ethdev: explicit cast of buffered Tx number' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (3 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'net: move stack variable at top of VLAN strip function' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'hash: move stack declaration at top of CRC32c function' " Yongseok Koh
                   ` (30 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Stephen Hemminger, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From 9279c2accec9ced9b2fb1c6a62263110ed904485 Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Sat, 12 May 2018 10:00:27 +0800
Subject: [PATCH] ethdev: explicit cast of buffered Tx number

[ backported from upstream commit b90406b9f7340466cbda287cd7454fae68868348 ]

In function 'rte_eth_tx_buffer_flush':
rte_ethdev.h:4248:55:
warning: conversion from 'int' to 'uint16_t'
{aka 'short unsigned int'} may change value [-Wconversion]
   buffer->error_callback(&buffer->pkts[sent], to_send - sent,

Fixes: d6c99e62c852 ("ethdev: add buffered Tx")

Signed-off-by: Andy Green <andy@warmcat.com>
Reviewed-by: Stephen Hemminger <stephen@networkplumber.org>
---
 lib/librte_ether/rte_ethdev.h | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/lib/librte_ether/rte_ethdev.h b/lib/librte_ether/rte_ethdev.h
index c4f68d1b9..bbca590d4 100644
--- a/lib/librte_ether/rte_ethdev.h
+++ b/lib/librte_ether/rte_ethdev.h
@@ -3361,8 +3361,9 @@ rte_eth_tx_buffer_flush(uint16_t port_id, uint16_t queue_id,
 
 	/* All packets sent, or to be dealt with by callback below */
 	if (unlikely(sent != to_send))
-		buffer->error_callback(&buffer->pkts[sent], to_send - sent,
-				buffer->error_userdata);
+		buffer->error_callback(&buffer->pkts[sent],
+				       (uint16_t)(to_send - sent),
+				       buffer->error_userdata);
 
 	return sent;
 }
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:12.427744670 -0800
+++ 0006-ethdev-explicit-cast-of-buffered-Tx-number.patch	2019-01-02 23:59:12.018816000 -0800
@@ -1,8 +1,10 @@
-From b90406b9f7340466cbda287cd7454fae68868348 Mon Sep 17 00:00:00 2001
+From 9279c2accec9ced9b2fb1c6a62263110ed904485 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Sat, 12 May 2018 10:00:27 +0800
 Subject: [PATCH] ethdev: explicit cast of buffered Tx number
 
+[ backported from upstream commit b90406b9f7340466cbda287cd7454fae68868348 ]
+
 In function 'rte_eth_tx_buffer_flush':
 rte_ethdev.h:4248:55:
 warning: conversion from 'int' to 'uint16_t'
@@ -10,19 +12,18 @@
    buffer->error_callback(&buffer->pkts[sent], to_send - sent,
 
 Fixes: d6c99e62c852 ("ethdev: add buffered Tx")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Reviewed-by: Stephen Hemminger <stephen@networkplumber.org>
 ---
- lib/librte_ethdev/rte_ethdev.h | 5 +++--
+ lib/librte_ether/rte_ethdev.h | 5 +++--
  1 file changed, 3 insertions(+), 2 deletions(-)
 
-diff --git a/lib/librte_ethdev/rte_ethdev.h b/lib/librte_ethdev/rte_ethdev.h
-index 7ccf4bae6..49c2ebbd5 100644
---- a/lib/librte_ethdev/rte_ethdev.h
-+++ b/lib/librte_ethdev/rte_ethdev.h
-@@ -4240,8 +4240,9 @@ rte_eth_tx_buffer_flush(uint16_t port_id, uint16_t queue_id,
+diff --git a/lib/librte_ether/rte_ethdev.h b/lib/librte_ether/rte_ethdev.h
+index c4f68d1b9..bbca590d4 100644
+--- a/lib/librte_ether/rte_ethdev.h
++++ b/lib/librte_ether/rte_ethdev.h
+@@ -3361,8 +3361,9 @@ rte_eth_tx_buffer_flush(uint16_t port_id, uint16_t queue_id,
  
  	/* All packets sent, or to be dealt with by callback below */
  	if (unlikely(sent != to_send))

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

* [dpdk-stable] patch 'hash: move stack declaration at top of CRC32c function' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (4 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'ethdev: explicit cast of buffered Tx number' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'hash: explicit casts for truncation in CRC32c' " Yongseok Koh
                   ` (29 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Stephen Hemminger, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From a68d3fb40aa6df5a3c902b56b85564e558a1f861 Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Sat, 12 May 2018 10:00:32 +0800
Subject: [PATCH] hash: move stack declaration at top of CRC32c function

[ upstream commit f1eb05a1dc64e17bb9d9b6ad29b78f181aae36b8 ]

In function 'crc32c_2words':
rte_hash_crc.h:347:2:
warning: ISO C90 forbids mixed declarations and code
[-Wdeclaration-after-statement]
  uint32_t crc, term1, term2;

Fixes: d983cf41698f ("hash: add software CRC32 implementation")

Signed-off-by: Andy Green <andy@warmcat.com>
Reviewed-by: Stephen Hemminger <stephen@networkplumber.org>
---
 lib/librte_hash/rte_hash_crc.h | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/lib/librte_hash/rte_hash_crc.h b/lib/librte_hash/rte_hash_crc.h
index 93188c290..0d829175d 100644
--- a/lib/librte_hash/rte_hash_crc.h
+++ b/lib/librte_hash/rte_hash_crc.h
@@ -367,14 +367,13 @@ crc32c_1word(uint32_t data, uint32_t init_val)
 static inline uint32_t
 crc32c_2words(uint64_t data, uint32_t init_val)
 {
+	uint32_t crc, term1, term2;
 	union {
 		uint64_t u64;
 		uint32_t u32[2];
 	} d;
 	d.u64 = data;
 
-	uint32_t crc, term1, term2;
-
 	crc = init_val;
 	crc ^= d.u32[0];
 
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:12.485941930 -0800
+++ 0007-hash-move-stack-declaration-at-top-of-CRC32c-functio.patch	2019-01-02 23:59:12.020819000 -0800
@@ -1,8 +1,10 @@
-From f1eb05a1dc64e17bb9d9b6ad29b78f181aae36b8 Mon Sep 17 00:00:00 2001
+From a68d3fb40aa6df5a3c902b56b85564e558a1f861 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Sat, 12 May 2018 10:00:32 +0800
 Subject: [PATCH] hash: move stack declaration at top of CRC32c function
 
+[ upstream commit f1eb05a1dc64e17bb9d9b6ad29b78f181aae36b8 ]
+
 In function 'crc32c_2words':
 rte_hash_crc.h:347:2:
 warning: ISO C90 forbids mixed declarations and code
@@ -10,7 +12,6 @@
   uint32_t crc, term1, term2;
 
 Fixes: d983cf41698f ("hash: add software CRC32 implementation")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Reviewed-by: Stephen Hemminger <stephen@networkplumber.org>
@@ -19,10 +20,10 @@
  1 file changed, 1 insertion(+), 2 deletions(-)
 
 diff --git a/lib/librte_hash/rte_hash_crc.h b/lib/librte_hash/rte_hash_crc.h
-index 479f84b14..5f5fb3db1 100644
+index 93188c290..0d829175d 100644
 --- a/lib/librte_hash/rte_hash_crc.h
 +++ b/lib/librte_hash/rte_hash_crc.h
-@@ -338,14 +338,13 @@ crc32c_1word(uint32_t data, uint32_t init_val)
+@@ -367,14 +367,13 @@ crc32c_1word(uint32_t data, uint32_t init_val)
  static inline uint32_t
  crc32c_2words(uint64_t data, uint32_t init_val)
  {

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

* [dpdk-stable] patch 'hash: explicit casts for truncation in CRC32c' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (5 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'hash: move stack declaration at top of CRC32c function' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'bus/pci: replace strncpy by strlcpy' " Yongseok Koh
                   ` (28 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Stephen Hemminger, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From ba05e2e6c8db651ebe72507d6a6189f473d7b554 Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Sat, 12 May 2018 10:00:37 +0800
Subject: [PATCH] hash: explicit casts for truncation in CRC32c

[ upstream commit c981825388f81fb191f5a79c80adf0fdb074e584 ]

In function 'crc32c_sse42_u64_mimic':
rte_hash_crc.h:402:40:
warning: conversion from 'uint64_t' {aka 'long unsigned int'}
to 'uint32_t' {aka 'unsigned int'} may change value [-Wconversion]
  init_val = crc32c_sse42_u32(d.u32[0], init_val);

Fixes: 00bf774bab0b ("hash: add assembly implementation of CRC32 intrinsics")

Signed-off-by: Andy Green <andy@warmcat.com>
Reviewed-by: Stephen Hemminger <stephen@networkplumber.org>
---
 lib/librte_hash/rte_hash_crc.h | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/lib/librte_hash/rte_hash_crc.h b/lib/librte_hash/rte_hash_crc.h
index 0d829175d..5a0f2d463 100644
--- a/lib/librte_hash/rte_hash_crc.h
+++ b/lib/librte_hash/rte_hash_crc.h
@@ -427,9 +427,9 @@ crc32c_sse42_u64_mimic(uint64_t data, uint64_t init_val)
 	} d;
 
 	d.u64 = data;
-	init_val = crc32c_sse42_u32(d.u32[0], init_val);
-	init_val = crc32c_sse42_u32(d.u32[1], init_val);
-	return init_val;
+	init_val = crc32c_sse42_u32(d.u32[0], (uint32_t)init_val);
+	init_val = crc32c_sse42_u32(d.u32[1], (uint32_t)init_val);
+	return (uint32_t)init_val;
 }
 #endif
 
@@ -441,7 +441,7 @@ crc32c_sse42_u64(uint64_t data, uint64_t init_val)
 			"crc32q %[data], %[init_val];"
 			: [init_val] "+r" (init_val)
 			: [data] "rm" (data));
-	return init_val;
+	return (uint32_t)init_val;
 }
 #endif
 
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:12.543255014 -0800
+++ 0008-hash-explicit-casts-for-truncation-in-CRC32c.patch	2019-01-02 23:59:12.023814000 -0800
@@ -1,8 +1,10 @@
-From c981825388f81fb191f5a79c80adf0fdb074e584 Mon Sep 17 00:00:00 2001
+From ba05e2e6c8db651ebe72507d6a6189f473d7b554 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Sat, 12 May 2018 10:00:37 +0800
 Subject: [PATCH] hash: explicit casts for truncation in CRC32c
 
+[ upstream commit c981825388f81fb191f5a79c80adf0fdb074e584 ]
+
 In function 'crc32c_sse42_u64_mimic':
 rte_hash_crc.h:402:40:
 warning: conversion from 'uint64_t' {aka 'long unsigned int'}
@@ -10,7 +12,6 @@
   init_val = crc32c_sse42_u32(d.u32[0], init_val);
 
 Fixes: 00bf774bab0b ("hash: add assembly implementation of CRC32 intrinsics")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Reviewed-by: Stephen Hemminger <stephen@networkplumber.org>
@@ -19,10 +20,10 @@
  1 file changed, 4 insertions(+), 4 deletions(-)
 
 diff --git a/lib/librte_hash/rte_hash_crc.h b/lib/librte_hash/rte_hash_crc.h
-index 5f5fb3db1..cf28031b3 100644
+index 0d829175d..5a0f2d463 100644
 --- a/lib/librte_hash/rte_hash_crc.h
 +++ b/lib/librte_hash/rte_hash_crc.h
-@@ -398,9 +398,9 @@ crc32c_sse42_u64_mimic(uint64_t data, uint64_t init_val)
+@@ -427,9 +427,9 @@ crc32c_sse42_u64_mimic(uint64_t data, uint64_t init_val)
  	} d;
  
  	d.u64 = data;
@@ -35,7 +36,7 @@
  }
  #endif
  
-@@ -412,7 +412,7 @@ crc32c_sse42_u64(uint64_t data, uint64_t init_val)
+@@ -441,7 +441,7 @@ crc32c_sse42_u64(uint64_t data, uint64_t init_val)
  			"crc32q %[data], %[init_val];"
  			: [init_val] "+r" (init_val)
  			: [data] "rm" (data));

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

* [dpdk-stable] patch 'bus/pci: replace strncpy by strlcpy' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (6 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'hash: explicit casts for truncation in CRC32c' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'bus/dpaa: fix inconsistent struct alignment' " Yongseok Koh
                   ` (27 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Pablo de Lara, Andrew Rybchenko, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From 349ac92512cac209eed58c9d457b98401b0c5cc9 Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Mon, 14 May 2018 13:00:06 +0800
Subject: [PATCH] bus/pci: replace strncpy by strlcpy
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

[ upstream commit fe5f777b538301ecadf3fee5c30dd0b289f50c7c ]

In function ‘pci_get_kernel_driver_by_path’,
    inlined from ‘pci_scan_one.isra.1’ at
	drivers/bus/pci/linux/pci.c:317:8:
drivers/bus/pci/linux/pci.c:57:3: error:
‘strncpy’ specified bound depends on the length of the source argument
[-Werror=stringop-overflow=]
   strncpy(dri_name, name + 1, strlen(name + 1) + 1);

Fixes: d9a8cd9595f2 ("pci: add kernel driver type")

Signed-off-by: Andy Green <andy@warmcat.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Reviewed-by: Andrew Rybchenko <arybchenko@solarflare.com>
---
 drivers/bus/pci/linux/pci.c | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/drivers/bus/pci/linux/pci.c b/drivers/bus/pci/linux/pci.c
index f955ede21..aabaa6300 100644
--- a/drivers/bus/pci/linux/pci.c
+++ b/drivers/bus/pci/linux/pci.c
@@ -63,7 +63,8 @@
 extern struct rte_pci_bus rte_pci_bus;
 
 static int
-pci_get_kernel_driver_by_path(const char *filename, char *dri_name)
+pci_get_kernel_driver_by_path(const char *filename, char *dri_name,
+			      size_t len)
 {
 	int count;
 	char path[PATH_MAX];
@@ -84,7 +85,7 @@ pci_get_kernel_driver_by_path(const char *filename, char *dri_name)
 
 	name = strrchr(path, '/');
 	if (name) {
-		strncpy(dri_name, name + 1, strlen(name + 1) + 1);
+		strlcpy(dri_name, name + 1, len);
 		return 0;
 	}
 
@@ -340,7 +341,7 @@ pci_scan_one(const char *dirname, const struct rte_pci_addr *addr)
 
 	/* parse driver */
 	snprintf(filename, sizeof(filename), "%s/driver", dirname);
-	ret = pci_get_kernel_driver_by_path(filename, driver);
+	ret = pci_get_kernel_driver_by_path(filename, driver, sizeof(driver));
 	if (ret < 0) {
 		RTE_LOG(ERR, EAL, "Fail to get kernel driver\n");
 		free(dev);
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:12.598395408 -0800
+++ 0009-bus-pci-replace-strncpy-by-strlcpy.patch	2019-01-02 23:59:12.026816000 -0800
@@ -1,4 +1,4 @@
-From fe5f777b538301ecadf3fee5c30dd0b289f50c7c Mon Sep 17 00:00:00 2001
+From 349ac92512cac209eed58c9d457b98401b0c5cc9 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Mon, 14 May 2018 13:00:06 +0800
 Subject: [PATCH] bus/pci: replace strncpy by strlcpy
@@ -6,6 +6,8 @@
 Content-Type: text/plain; charset=UTF-8
 Content-Transfer-Encoding: 8bit
 
+[ upstream commit fe5f777b538301ecadf3fee5c30dd0b289f50c7c ]
+
 In function ‘pci_get_kernel_driver_by_path’,
     inlined from ‘pci_scan_one.isra.1’ at
 	drivers/bus/pci/linux/pci.c:317:8:
@@ -15,27 +17,46 @@
    strncpy(dri_name, name + 1, strlen(name + 1) + 1);
 
 Fixes: d9a8cd9595f2 ("pci: add kernel driver type")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
+Reviewed-by: Andrew Rybchenko <arybchenko@solarflare.com>
 ---
- drivers/bus/pci/linux/pci.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
+ drivers/bus/pci/linux/pci.c | 7 ++++---
+ 1 file changed, 4 insertions(+), 3 deletions(-)
 
 diff --git a/drivers/bus/pci/linux/pci.c b/drivers/bus/pci/linux/pci.c
-index 4630a8057..a73ee49c2 100644
+index f955ede21..aabaa6300 100644
 --- a/drivers/bus/pci/linux/pci.c
 +++ b/drivers/bus/pci/linux/pci.c
-@@ -54,7 +54,7 @@ pci_get_kernel_driver_by_path(const char *filename, char *dri_name)
+@@ -63,7 +63,8 @@
+ extern struct rte_pci_bus rte_pci_bus;
+ 
+ static int
+-pci_get_kernel_driver_by_path(const char *filename, char *dri_name)
++pci_get_kernel_driver_by_path(const char *filename, char *dri_name,
++			      size_t len)
+ {
+ 	int count;
+ 	char path[PATH_MAX];
+@@ -84,7 +85,7 @@ pci_get_kernel_driver_by_path(const char *filename, char *dri_name)
  
  	name = strrchr(path, '/');
  	if (name) {
 -		strncpy(dri_name, name + 1, strlen(name + 1) + 1);
-+		strlcpy(dri_name, name + 1, sizeof(dri_name));
++		strlcpy(dri_name, name + 1, len);
  		return 0;
  	}
  
+@@ -340,7 +341,7 @@ pci_scan_one(const char *dirname, const struct rte_pci_addr *addr)
+ 
+ 	/* parse driver */
+ 	snprintf(filename, sizeof(filename), "%s/driver", dirname);
+-	ret = pci_get_kernel_driver_by_path(filename, driver);
++	ret = pci_get_kernel_driver_by_path(filename, driver, sizeof(driver));
+ 	if (ret < 0) {
+ 		RTE_LOG(ERR, EAL, "Fail to get kernel driver\n");
+ 		free(dev);
 -- 
 2.11.0
 

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

* [dpdk-stable] patch 'bus/dpaa: fix inconsistent struct alignment' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (7 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'bus/pci: replace strncpy by strlcpy' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'net/nfp: fix memcpy out of source range' " Yongseok Koh
                   ` (26 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Hemant Agrawal, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From 84f4ff2891bab8ddca99b73983f7c3108b532528 Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Mon, 14 May 2018 13:00:12 +0800
Subject: [PATCH] bus/dpaa: fix inconsistent struct alignment
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

[ upstream commit dd6f8d712e927397da27f2a3d90a759eeac4f694 ]

The actual descriptor for qm_mr_entry is 64-byte aligned.

But the original code plays a trick, and puts a u8 common
to the three descriptor subtypes in the union afterwards
outside their structure definitions.

Unfortunately since they compose a struct qm_fd with
alignment 8, this trick destroys the ability of the compiler
to understand what has happened, resulting in this kind of
problem:

drivers/bus/dpaa/include/fsl_qman.h:354:3: error:
alignment 1 of ‘struct <anonymous>’ is less than 8 [-Werror=packed-not-aligned]
   } __packed dcern;

on gcc 8 / Fedora 28 out of the box.

This patch moves the u8 verb into the structure definitions
composed into the union, so the alignment of the parent struct
containing the alignment 8 object can also be seen to be
alignment 8 by the compiler.  Uses of .verb are fixed up to use
.ern.verb (the same offset of +0 inside all the structs in
the union).

The final struct layout should be unchanged.

Fixes: c47ff048b99a ("bus/dpaa: add QMAN driver core routines")
Fixes: f6fadc3e6310 ("bus/dpaa: add QMAN interface driver")

Signed-off-by: Andy Green <andy@warmcat.com>
Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>
Tested-by: Hemant Agrawal <hemant.agrawal@nxp.com>
---
 drivers/bus/dpaa/base/qbman/qman.c  | 14 +++++++-------
 drivers/bus/dpaa/include/fsl_qman.h | 24 +++++++++++++-----------
 2 files changed, 20 insertions(+), 18 deletions(-)

diff --git a/drivers/bus/dpaa/base/qbman/qman.c b/drivers/bus/dpaa/base/qbman/qman.c
index b8511103c..84f0cb0be 100644
--- a/drivers/bus/dpaa/base/qbman/qman.c
+++ b/drivers/bus/dpaa/base/qbman/qman.c
@@ -344,9 +344,9 @@ loop:
 		if (!msg)
 			return 0;
 	}
-	if ((msg->verb & QM_MR_VERB_TYPE_MASK) != QM_MR_VERB_FQRNI) {
+	if ((msg->ern.verb & QM_MR_VERB_TYPE_MASK) != QM_MR_VERB_FQRNI) {
 		/* We aren't draining anything but FQRNIs */
-		pr_err("Found verb 0x%x in MR\n", msg->verb);
+		pr_err("Found verb 0x%x in MR\n", msg->ern.verb);
 		return -1;
 	}
 	qm_mr_next(p);
@@ -513,7 +513,7 @@ static inline void qm_mr_pvb_update(struct qm_portal *portal)
 	/* when accessing 'verb', use __raw_readb() to ensure that compiler
 	 * inlining doesn't try to optimise out "excess reads".
 	 */
-	if ((__raw_readb(&res->verb) & QM_MR_VERB_VBIT) == mr->vbit) {
+	if ((__raw_readb(&res->ern.verb) & QM_MR_VERB_VBIT) == mr->vbit) {
 		mr->pi = (mr->pi + 1) & (QM_MR_SIZE - 1);
 		if (!mr->pi)
 			mr->vbit ^= QM_MR_VERB_VBIT;
@@ -810,7 +810,7 @@ mr_loop:
 			goto mr_done;
 		swapped_msg = *msg;
 		hw_fd_to_cpu(&swapped_msg.ern.fd);
-		verb = msg->verb & QM_MR_VERB_TYPE_MASK;
+		verb = msg->ern.verb & QM_MR_VERB_TYPE_MASK;
 		/* The message is a software ERN iff the 0x20 bit is set */
 		if (verb & 0x20) {
 			switch (verb) {
@@ -1504,7 +1504,7 @@ int qman_retire_fq(struct qman_fq *fq, u32 *flags)
 			 */
 			struct qm_mr_entry msg;
 
-			msg.verb = QM_MR_VERB_FQRNI;
+			msg.ern.verb = QM_MR_VERB_FQRNI;
 			msg.fq.fqs = mcr->alterfq.fqs;
 			msg.fq.fqid = fq->fqid;
 #ifdef CONFIG_FSL_QMAN_FQ_LOOKUP
@@ -2389,7 +2389,7 @@ int qman_shutdown_fq(u32 fqid)
 				qm_mr_pvb_update(low_p);
 				msg = qm_mr_current(low_p);
 				while (msg) {
-					if ((msg->verb &
+					if ((msg->ern.verb &
 					     QM_MR_VERB_TYPE_MASK)
 					    == QM_MR_VERB_FQRN)
 						found_fqrn = 1;
@@ -2457,7 +2457,7 @@ int qman_shutdown_fq(u32 fqid)
 			qm_mr_pvb_update(low_p);
 			msg = qm_mr_current(low_p);
 			while (msg) {
-				if ((msg->verb & QM_MR_VERB_TYPE_MASK) ==
+				if ((msg->ern.verb & QM_MR_VERB_TYPE_MASK) ==
 				    QM_MR_VERB_FQRL)
 					orl_empty = 1;
 				qm_mr_next(low_p);
diff --git a/drivers/bus/dpaa/include/fsl_qman.h b/drivers/bus/dpaa/include/fsl_qman.h
index 72556dc12..5d00bc73a 100644
--- a/drivers/bus/dpaa/include/fsl_qman.h
+++ b/drivers/bus/dpaa/include/fsl_qman.h
@@ -316,20 +316,20 @@ static inline dma_addr_t qm_sg_addr(const struct qm_sg_entry *sg)
 	} while (0)
 
 /* See 1.5.8.1: "Enqueue Command" */
-struct qm_eqcr_entry {
+struct __rte_aligned(8) qm_eqcr_entry {
 	u8 __dont_write_directly__verb;
 	u8 dca;
 	u16 seqnum;
 	u32 orp;	/* 24-bit */
 	u32 fqid;	/* 24-bit */
 	u32 tag;
-	struct qm_fd fd;
+	struct qm_fd fd; /* this has alignment 8 */
 	u8 __reserved3[32];
 } __packed;
 
 
 /* "Frame Dequeue Response" */
-struct qm_dqrr_entry {
+struct __rte_aligned(8) qm_dqrr_entry {
 	u8 verb;
 	u8 stat;
 	u16 seqnum;	/* 15-bit */
@@ -337,7 +337,7 @@ struct qm_dqrr_entry {
 	u8 __reserved2[3];
 	u32 fqid;	/* 24-bit */
 	u32 contextB;
-	struct qm_fd fd;
+	struct qm_fd fd; /* this has alignment 8 */
 	u8 __reserved4[32];
 };
 
@@ -355,18 +355,19 @@ struct qm_dqrr_entry {
 /* "ERN Message Response" */
 /* "FQ State Change Notification" */
 struct qm_mr_entry {
-	u8 verb;
 	union {
 		struct {
+			u8 verb;
 			u8 dca;
 			u16 seqnum;
 			u8 rc;		/* Rejection Code */
 			u32 orp:24;
 			u32 fqid;	/* 24-bit */
 			u32 tag;
-			struct qm_fd fd;
-		} __packed ern;
+			struct qm_fd fd; /* this has alignment 8 */
+		} __packed __rte_aligned(8) ern;
 		struct {
+			u8 verb;
 #if __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
 			u8 colour:2;	/* See QM_MR_DCERN_COLOUR_* */
 			u8 __reserved1:4;
@@ -381,18 +382,19 @@ struct qm_mr_entry {
 			u32 __reserved3:24;
 			u32 fqid;	/* 24-bit */
 			u32 tag;
-			struct qm_fd fd;
-		} __packed dcern;
+			struct qm_fd fd; /* this has alignment 8 */
+		} __packed __rte_aligned(8) dcern;
 		struct {
+			u8 verb;
 			u8 fqs;		/* Frame Queue Status */
 			u8 __reserved1[6];
 			u32 fqid;	/* 24-bit */
 			u32 contextB;
 			u8 __reserved2[16];
-		} __packed fq;		/* FQRN/FQRNI/FQRL/FQPN */
+		} __packed __rte_aligned(8) fq;	/* FQRN/FQRNI/FQRL/FQPN */
 	};
 	u8 __reserved2[32];
-} __packed;
+} __packed __rte_aligned(8);
 #define QM_MR_VERB_VBIT			0x80
 /*
  * ERNs originating from direct-connect portals ("dcern") use 0x20 as a verb
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:12.646228426 -0800
+++ 0010-bus-dpaa-fix-inconsistent-struct-alignment.patch	2019-01-02 23:59:12.036815000 -0800
@@ -1,4 +1,4 @@
-From dd6f8d712e927397da27f2a3d90a759eeac4f694 Mon Sep 17 00:00:00 2001
+From 84f4ff2891bab8ddca99b73983f7c3108b532528 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Mon, 14 May 2018 13:00:12 +0800
 Subject: [PATCH] bus/dpaa: fix inconsistent struct alignment
@@ -6,6 +6,8 @@
 Content-Type: text/plain; charset=UTF-8
 Content-Transfer-Encoding: 8bit
 
+[ upstream commit dd6f8d712e927397da27f2a3d90a759eeac4f694 ]
+
 The actual descriptor for qm_mr_entry is 64-byte aligned.
 
 But the original code plays a trick, and puts a u8 common
@@ -34,7 +36,6 @@
 
 Fixes: c47ff048b99a ("bus/dpaa: add QMAN driver core routines")
 Fixes: f6fadc3e6310 ("bus/dpaa: add QMAN interface driver")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>
@@ -45,10 +46,10 @@
  2 files changed, 20 insertions(+), 18 deletions(-)
 
 diff --git a/drivers/bus/dpaa/base/qbman/qman.c b/drivers/bus/dpaa/base/qbman/qman.c
-index 2810fdd26..27d98cc10 100644
+index b8511103c..84f0cb0be 100644
 --- a/drivers/bus/dpaa/base/qbman/qman.c
 +++ b/drivers/bus/dpaa/base/qbman/qman.c
-@@ -314,9 +314,9 @@ loop:
+@@ -344,9 +344,9 @@ loop:
  		if (!msg)
  			return 0;
  	}
@@ -60,7 +61,7 @@
  		return -1;
  	}
  	qm_mr_next(p);
-@@ -483,7 +483,7 @@ static inline void qm_mr_pvb_update(struct qm_portal *portal)
+@@ -513,7 +513,7 @@ static inline void qm_mr_pvb_update(struct qm_portal *portal)
  	/* when accessing 'verb', use __raw_readb() to ensure that compiler
  	 * inlining doesn't try to optimise out "excess reads".
  	 */
@@ -69,7 +70,7 @@
  		mr->pi = (mr->pi + 1) & (QM_MR_SIZE - 1);
  		if (!mr->pi)
  			mr->vbit ^= QM_MR_VERB_VBIT;
-@@ -832,7 +832,7 @@ mr_loop:
+@@ -810,7 +810,7 @@ mr_loop:
  			goto mr_done;
  		swapped_msg = *msg;
  		hw_fd_to_cpu(&swapped_msg.ern.fd);
@@ -78,7 +79,7 @@
  		/* The message is a software ERN iff the 0x20 bit is set */
  		if (verb & 0x20) {
  			switch (verb) {
-@@ -1666,7 +1666,7 @@ int qman_retire_fq(struct qman_fq *fq, u32 *flags)
+@@ -1504,7 +1504,7 @@ int qman_retire_fq(struct qman_fq *fq, u32 *flags)
  			 */
  			struct qm_mr_entry msg;
  
@@ -87,7 +88,7 @@
  			msg.fq.fqs = mcr->alterfq.fqs;
  			msg.fq.fqid = fq->fqid;
  #ifdef CONFIG_FSL_QMAN_FQ_LOOKUP
-@@ -2643,7 +2643,7 @@ int qman_shutdown_fq(u32 fqid)
+@@ -2389,7 +2389,7 @@ int qman_shutdown_fq(u32 fqid)
  				qm_mr_pvb_update(low_p);
  				msg = qm_mr_current(low_p);
  				while (msg) {
@@ -96,7 +97,7 @@
  					     QM_MR_VERB_TYPE_MASK)
  					    == QM_MR_VERB_FQRN)
  						found_fqrn = 1;
-@@ -2711,7 +2711,7 @@ int qman_shutdown_fq(u32 fqid)
+@@ -2457,7 +2457,7 @@ int qman_shutdown_fq(u32 fqid)
  			qm_mr_pvb_update(low_p);
  			msg = qm_mr_current(low_p);
  			while (msg) {
@@ -106,10 +107,10 @@
  					orl_empty = 1;
  				qm_mr_next(low_p);
 diff --git a/drivers/bus/dpaa/include/fsl_qman.h b/drivers/bus/dpaa/include/fsl_qman.h
-index e9793f30d..e4ad7ae48 100644
+index 72556dc12..5d00bc73a 100644
 --- a/drivers/bus/dpaa/include/fsl_qman.h
 +++ b/drivers/bus/dpaa/include/fsl_qman.h
-@@ -284,20 +284,20 @@ static inline dma_addr_t qm_sg_addr(const struct qm_sg_entry *sg)
+@@ -316,20 +316,20 @@ static inline dma_addr_t qm_sg_addr(const struct qm_sg_entry *sg)
  	} while (0)
  
  /* See 1.5.8.1: "Enqueue Command" */
@@ -133,7 +134,7 @@
  	u8 verb;
  	u8 stat;
  	u16 seqnum;	/* 15-bit */
-@@ -305,7 +305,7 @@ struct qm_dqrr_entry {
+@@ -337,7 +337,7 @@ struct qm_dqrr_entry {
  	u8 __reserved2[3];
  	u32 fqid;	/* 24-bit */
  	u32 contextB;
@@ -142,7 +143,7 @@
  	u8 __reserved4[32];
  };
  
-@@ -323,18 +323,19 @@ struct qm_dqrr_entry {
+@@ -355,18 +355,19 @@ struct qm_dqrr_entry {
  /* "ERN Message Response" */
  /* "FQ State Change Notification" */
  struct qm_mr_entry {
@@ -165,7 +166,7 @@
  #if __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
  			u8 colour:2;	/* See QM_MR_DCERN_COLOUR_* */
  			u8 __reserved1:4;
-@@ -349,18 +350,19 @@ struct qm_mr_entry {
+@@ -381,18 +382,19 @@ struct qm_mr_entry {
  			u32 __reserved3:24;
  			u32 fqid;	/* 24-bit */
  			u32 tag;

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

* [dpdk-stable] patch 'net/nfp: fix memcpy out of source range' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (8 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'bus/dpaa: fix inconsistent struct alignment' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'net/qede: replace strncpy by strlcpy' " Yongseok Koh
                   ` (25 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Alejandro Lucero, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From 7f2dc097bff7b6d6e72a2c37882974161cfa1e7b Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Mon, 14 May 2018 13:00:32 +0800
Subject: [PATCH] net/nfp: fix memcpy out of source range
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

[ upstream commit 1bcb5ecb179cbca81ff3fe15432326c1c3ca9e9b ]

drivers/net/nfp/nfp_net.c:669:2: error:
‘memcpy’ forming offset [5, 6] is out of the bounds [0, 4]
of object ‘tmp’ with type ‘uint32_t’ {aka ‘unsigned int’}
[-Werror=array-bounds]
memcpy(&hw->mac_addr[0], &tmp, sizeof(struct ether_addr));

Fixes: e6decee38209 ("net/nfp: use random MAC address if not configured")

Signed-off-by: Andy Green <andy@warmcat.com>
Acked-by: Alejandro Lucero <alejandro.lucero@netronome.com>
Tested-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 cf9d345c0..c3958d045 100644
--- a/drivers/net/nfp/nfp_net.c
+++ b/drivers/net/nfp/nfp_net.c
@@ -666,7 +666,7 @@ nfp_net_vf_read_mac(struct nfp_net_hw *hw)
 	uint32_t tmp;
 
 	tmp = rte_be_to_cpu_32(nn_cfg_readl(hw, NFP_NET_CFG_MACADDR));
-	memcpy(&hw->mac_addr[0], &tmp, sizeof(struct ether_addr));
+	memcpy(&hw->mac_addr[0], &tmp, 4);
 
 	tmp = rte_be_to_cpu_32(nn_cfg_readl(hw, NFP_NET_CFG_MACADDR + 4));
 	memcpy(&hw->mac_addr[4], &tmp, 2);
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:12.697148186 -0800
+++ 0011-net-nfp-fix-memcpy-out-of-source-range.patch	2019-01-02 23:59:12.041816000 -0800
@@ -1,4 +1,4 @@
-From 1bcb5ecb179cbca81ff3fe15432326c1c3ca9e9b Mon Sep 17 00:00:00 2001
+From 7f2dc097bff7b6d6e72a2c37882974161cfa1e7b Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Mon, 14 May 2018 13:00:32 +0800
 Subject: [PATCH] net/nfp: fix memcpy out of source range
@@ -6,6 +6,8 @@
 Content-Type: text/plain; charset=UTF-8
 Content-Transfer-Encoding: 8bit
 
+[ upstream commit 1bcb5ecb179cbca81ff3fe15432326c1c3ca9e9b ]
+
 drivers/net/nfp/nfp_net.c:669:2: error:
 ‘memcpy’ forming offset [5, 6] is out of the bounds [0, 4]
 of object ‘tmp’ with type ‘uint32_t’ {aka ‘unsigned int’}
@@ -13,7 +15,6 @@
 memcpy(&hw->mac_addr[0], &tmp, sizeof(struct ether_addr));
 
 Fixes: e6decee38209 ("net/nfp: use random MAC address if not configured")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Acked-by: Alejandro Lucero <alejandro.lucero@netronome.com>
@@ -23,10 +24,10 @@
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/drivers/net/nfp/nfp_net.c b/drivers/net/nfp/nfp_net.c
-index 8a712d696..80dc2731c 100644
+index cf9d345c0..c3958d045 100644
 --- a/drivers/net/nfp/nfp_net.c
 +++ b/drivers/net/nfp/nfp_net.c
-@@ -527,7 +527,7 @@ nfp_net_vf_read_mac(struct nfp_net_hw *hw)
+@@ -666,7 +666,7 @@ nfp_net_vf_read_mac(struct nfp_net_hw *hw)
  	uint32_t tmp;
  
  	tmp = rte_be_to_cpu_32(nn_cfg_readl(hw, NFP_NET_CFG_MACADDR));

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

* [dpdk-stable] patch 'net/qede: replace strncpy by strlcpy' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (9 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'net/nfp: fix memcpy out of source range' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'net/qede: fix strncpy' " Yongseok Koh
                   ` (24 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From 9518fb165c32383debb867c850ea1ee7fdc8adbf Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Mon, 14 May 2018 13:00:37 +0800
Subject: [PATCH] net/qede: replace strncpy by strlcpy

[ upstream commit 0fa4f3eeefb3e76124f5bbc1fccedcf43f4503f3 ]

Fixes: 8427c6647964 ("net/qede/base: add attention formatting string")

Signed-off-by: Andy Green <andy@warmcat.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
 drivers/net/qede/base/ecore_int.c | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/drivers/net/qede/base/ecore_int.c b/drivers/net/qede/base/ecore_int.c
index b2582aacd..367fe5ee8 100644
--- a/drivers/net/qede/base/ecore_int.c
+++ b/drivers/net/qede/base/ecore_int.c
@@ -6,6 +6,8 @@
  * See LICENSE.qede_pmd for copyright and licensing details.
  */
 
+#include <rte_string_fns.h>
+
 #include "bcm_osal.h"
 #include "ecore.h"
 #include "ecore_spq.h"
@@ -1108,9 +1110,9 @@ static enum _ecore_status_t ecore_int_deassertion(struct ecore_hwfn *p_hwfn,
 							      p_aeu->bit_name,
 							      num);
 					else
-						OSAL_STRNCPY(bit_name,
-							     p_aeu->bit_name,
-							     30);
+						strlcpy(bit_name,
+							p_aeu->bit_name,
+							sizeof(bit_name));
 
 					/* We now need to pass bitmask in its
 					 * correct position.
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:12.747294497 -0800
+++ 0012-net-qede-replace-strncpy-by-strlcpy.patch	2019-01-02 23:59:12.045815000 -0800
@@ -1,10 +1,11 @@
-From 0fa4f3eeefb3e76124f5bbc1fccedcf43f4503f3 Mon Sep 17 00:00:00 2001
+From 9518fb165c32383debb867c850ea1ee7fdc8adbf Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Mon, 14 May 2018 13:00:37 +0800
 Subject: [PATCH] net/qede: replace strncpy by strlcpy
 
+[ upstream commit 0fa4f3eeefb3e76124f5bbc1fccedcf43f4503f3 ]
+
 Fixes: 8427c6647964 ("net/qede/base: add attention formatting string")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
@@ -13,7 +14,7 @@
  1 file changed, 5 insertions(+), 3 deletions(-)
 
 diff --git a/drivers/net/qede/base/ecore_int.c b/drivers/net/qede/base/ecore_int.c
-index f43781ba4..d9e22b5ed 100644
+index b2582aacd..367fe5ee8 100644
 --- a/drivers/net/qede/base/ecore_int.c
 +++ b/drivers/net/qede/base/ecore_int.c
 @@ -6,6 +6,8 @@
@@ -25,7 +26,7 @@
  #include "bcm_osal.h"
  #include "ecore.h"
  #include "ecore_spq.h"
-@@ -1104,9 +1106,9 @@ static enum _ecore_status_t ecore_int_deassertion(struct ecore_hwfn *p_hwfn,
+@@ -1108,9 +1110,9 @@ static enum _ecore_status_t ecore_int_deassertion(struct ecore_hwfn *p_hwfn,
  							      p_aeu->bit_name,
  							      num);
  					else

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

* [dpdk-stable] patch 'net/qede: fix strncpy' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (10 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'net/qede: replace strncpy by strlcpy' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'net/sfc: make sure that stats name is nul-terminated' " Yongseok Koh
                   ` (23 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From d0849a4b0f21e280a77952657ce9e9b29356e632 Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Mon, 14 May 2018 13:00:42 +0800
Subject: [PATCH] net/qede: fix strncpy
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

[ upstream commit f28742ba06a83a0bb8f658e12105e975ab7b26d7 ]

drivers/net/qede/qede_main.c: In function ‘qed_slowpath_start’:
drivers/net/qede/qede_main.c:307:3: error:
‘strncpy’ output may be truncated copying 12 bytes from a string of length 127
[-Werror=stringop-truncation]
   strncpy((char *)drv_version.name, (const char *)params->name,
   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    MCP_DRV_VER_STR_SIZE - 4);
    ~~~~~~~~~~~~~~~~~~~~~~~~~

Fixes: 86a2265e59d7 ("qede: add SRIOV support")

Signed-off-by: Andy Green <andy@warmcat.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
 drivers/net/qede/qede_main.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/net/qede/qede_main.c b/drivers/net/qede/qede_main.c
index 95b4cd91b..107f074a9 100644
--- a/drivers/net/qede/qede_main.c
+++ b/drivers/net/qede/qede_main.c
@@ -9,6 +9,7 @@
 #include <limits.h>
 #include <time.h>
 #include <rte_alarm.h>
+#include <rte_string_fns.h>
 
 #include "qede_ethdev.h"
 
@@ -302,9 +303,8 @@ static int qed_slowpath_start(struct ecore_dev *edev,
 		drv_version.version = (params->drv_major << 24) |
 		    (params->drv_minor << 16) |
 		    (params->drv_rev << 8) | (params->drv_eng);
-		/* TBD: strlcpy() */
-		strncpy((char *)drv_version.name, (const char *)params->name,
-			MCP_DRV_VER_STR_SIZE - 4);
+		strlcpy((char *)drv_version.name, (const char *)params->name,
+			sizeof(drv_version.name));
 		rc = ecore_mcp_send_drv_version(hwfn, hwfn->p_main_ptt,
 						&drv_version);
 		if (rc) {
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:12.795178295 -0800
+++ 0013-net-qede-fix-strncpy.patch	2019-01-02 23:59:12.048815000 -0800
@@ -1,4 +1,4 @@
-From f28742ba06a83a0bb8f658e12105e975ab7b26d7 Mon Sep 17 00:00:00 2001
+From d0849a4b0f21e280a77952657ce9e9b29356e632 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Mon, 14 May 2018 13:00:42 +0800
 Subject: [PATCH] net/qede: fix strncpy
@@ -6,6 +6,8 @@
 Content-Type: text/plain; charset=UTF-8
 Content-Transfer-Encoding: 8bit
 
+[ upstream commit f28742ba06a83a0bb8f658e12105e975ab7b26d7 ]
+
 drivers/net/qede/qede_main.c: In function ‘qed_slowpath_start’:
 drivers/net/qede/qede_main.c:307:3: error:
 ‘strncpy’ output may be truncated copying 12 bytes from a string of length 127
@@ -16,7 +18,6 @@
     ~~~~~~~~~~~~~~~~~~~~~~~~~
 
 Fixes: 86a2265e59d7 ("qede: add SRIOV support")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
@@ -25,7 +26,7 @@
  1 file changed, 3 insertions(+), 3 deletions(-)
 
 diff --git a/drivers/net/qede/qede_main.c b/drivers/net/qede/qede_main.c
-index 2333ca073..ee63ac22b 100644
+index 95b4cd91b..107f074a9 100644
 --- a/drivers/net/qede/qede_main.c
 +++ b/drivers/net/qede/qede_main.c
 @@ -9,6 +9,7 @@
@@ -36,7 +37,7 @@
  
  #include "qede_ethdev.h"
  
-@@ -303,9 +304,8 @@ static int qed_slowpath_start(struct ecore_dev *edev,
+@@ -302,9 +303,8 @@ static int qed_slowpath_start(struct ecore_dev *edev,
  		drv_version.version = (params->drv_major << 24) |
  		    (params->drv_minor << 16) |
  		    (params->drv_rev << 8) | (params->drv_eng);

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

* [dpdk-stable] patch 'net/sfc: make sure that stats name is nul-terminated' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (11 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'net/qede: fix strncpy' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'app/procinfo: fix sprintf overrun' " Yongseok Koh
                   ` (22 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Andrew Rybchenko, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From 1e597bca44130414065cc9b7cbbbbb653dbb44c0 Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Mon, 14 May 2018 13:00:47 +0800
Subject: [PATCH] net/sfc: make sure that stats name is nul-terminated

[ upstream commit ed5b98483a30c034ab7ba666af2c26161828323d ]

Fixes: 73280c1e4ff2 ("net/sfc: support xstats retrieval by ID")
Fixes: 7b9891769f4b ("net/sfc: support extended statistics")

Signed-off-by: Andy Green <andy@warmcat.com>
Acked-by: Andrew Rybchenko <arybchenko@solarflare.com>
---
 drivers/net/sfc/sfc_ethdev.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/net/sfc/sfc_ethdev.c b/drivers/net/sfc/sfc_ethdev.c
index 819177a34..005df401d 100644
--- a/drivers/net/sfc/sfc_ethdev.c
+++ b/drivers/net/sfc/sfc_ethdev.c
@@ -35,6 +35,7 @@
 #include <rte_pci.h>
 #include <rte_bus_pci.h>
 #include <rte_errno.h>
+#include <rte_string_fns.h>
 
 #include "efx.h"
 
@@ -661,7 +662,7 @@ sfc_xstats_get_names(struct rte_eth_dev *dev,
 	for (i = 0; i < EFX_MAC_NSTATS; ++i) {
 		if (EFX_MAC_STAT_SUPPORTED(port->mac_stats_mask, i)) {
 			if (xstats_names != NULL && nstats < xstats_count)
-				strncpy(xstats_names[nstats].name,
+				strlcpy(xstats_names[nstats].name,
 					efx_mac_stat_name(sa->nic, i),
 					sizeof(xstats_names[0].name));
 			nstats++;
@@ -739,9 +740,8 @@ sfc_xstats_get_names_by_id(struct rte_eth_dev *dev,
 		if ((ids == NULL) || (ids[nb_written] == nb_supported)) {
 			char *name = xstats_names[nb_written++].name;
 
-			strncpy(name, efx_mac_stat_name(sa->nic, i),
+			strlcpy(name, efx_mac_stat_name(sa->nic, i),
 				sizeof(xstats_names[0].name));
-			name[sizeof(xstats_names[0].name) - 1] = '\0';
 		}
 
 		++nb_supported;
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:12.845742223 -0800
+++ 0014-net-sfc-make-sure-that-stats-name-is-nul-terminated.patch	2019-01-02 23:59:12.051815000 -0800
@@ -1,11 +1,12 @@
-From ed5b98483a30c034ab7ba666af2c26161828323d Mon Sep 17 00:00:00 2001
+From 1e597bca44130414065cc9b7cbbbbb653dbb44c0 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Mon, 14 May 2018 13:00:47 +0800
 Subject: [PATCH] net/sfc: make sure that stats name is nul-terminated
 
+[ upstream commit ed5b98483a30c034ab7ba666af2c26161828323d ]
+
 Fixes: 73280c1e4ff2 ("net/sfc: support xstats retrieval by ID")
 Fixes: 7b9891769f4b ("net/sfc: support extended statistics")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Acked-by: Andrew Rybchenko <arybchenko@solarflare.com>
@@ -14,10 +15,10 @@
  1 file changed, 3 insertions(+), 3 deletions(-)
 
 diff --git a/drivers/net/sfc/sfc_ethdev.c b/drivers/net/sfc/sfc_ethdev.c
-index 578af5489..1b6499f85 100644
+index 819177a34..005df401d 100644
 --- a/drivers/net/sfc/sfc_ethdev.c
 +++ b/drivers/net/sfc/sfc_ethdev.c
-@@ -13,6 +13,7 @@
+@@ -35,6 +35,7 @@
  #include <rte_pci.h>
  #include <rte_bus_pci.h>
  #include <rte_errno.h>
@@ -25,7 +26,7 @@
  
  #include "efx.h"
  
-@@ -648,7 +649,7 @@ sfc_xstats_get_names(struct rte_eth_dev *dev,
+@@ -661,7 +662,7 @@ sfc_xstats_get_names(struct rte_eth_dev *dev,
  	for (i = 0; i < EFX_MAC_NSTATS; ++i) {
  		if (EFX_MAC_STAT_SUPPORTED(port->mac_stats_mask, i)) {
  			if (xstats_names != NULL && nstats < xstats_count)
@@ -34,7 +35,7 @@
  					efx_mac_stat_name(sa->nic, i),
  					sizeof(xstats_names[0].name));
  			nstats++;
-@@ -726,9 +727,8 @@ sfc_xstats_get_names_by_id(struct rte_eth_dev *dev,
+@@ -739,9 +740,8 @@ sfc_xstats_get_names_by_id(struct rte_eth_dev *dev,
  		if ((ids == NULL) || (ids[nb_written] == nb_supported)) {
  			char *name = xstats_names[nb_written++].name;
  

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

* [dpdk-stable] patch 'app/procinfo: fix sprintf overrun' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (12 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'net/sfc: make sure that stats name is nul-terminated' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'devtools: provide more generic grep in git check' " Yongseok Koh
                   ` (21 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From a115124be053c3475e0ee16861c98f00965070a0 Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Mon, 14 May 2018 13:01:02 +0800
Subject: [PATCH] app/procinfo: fix sprintf overrun
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

[ upstream commit 3cef37eb98769935fbc12e01f06d9ac36d430071 ]

app/proc-info/main.c: In function ‘nic_xstats_display’:
app/proc-info/main.c:495:45: error:
‘%s’ directive writing up to 255 bytes into a regioni of size between 165 and 232
[-Werror=format-overflow=]
    sprintf(buf, "PUTVAL %s/dpdkstat-port.%u/%s-%s N:%"
                                             ^~
     PRIu64"\n", host_id, port_id, counter_type,
                                   ~~~~~~~~~~~~
app/proc-info/main.c:495:4: note:
‘sprintf’ output between 31 and 435 bytes into a destination of size 256
    sprintf(buf, "PUTVAL %s/dpdkstat-port.%u/%s-%s N:%"
    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
     PRIu64"\n", host_id, port_id, counter_type,
     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
     xstats_names[i].name, values[i]);

Fixes: 2deb6b5246d7 ("app/procinfo: add collectd format and host id")

Signed-off-by: Andy Green <andy@warmcat.com>
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
 app/proc_info/main.c | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/app/proc_info/main.c b/app/proc_info/main.c
index 875d91ea3..2893bec69 100644
--- a/app/proc_info/main.c
+++ b/app/proc_info/main.c
@@ -517,14 +517,18 @@ nic_xstats_display(uint16_t port_id)
 		if (enable_collectd_format) {
 			char counter_type[MAX_STRING_LEN];
 			char buf[MAX_STRING_LEN];
+			size_t n;
 
 			collectd_resolve_cnt_type(counter_type,
 						  sizeof(counter_type),
 						  xstats_names[i].name);
-			sprintf(buf, "PUTVAL %s/dpdkstat-port.%u/%s-%s N:%"
+			n = snprintf(buf, MAX_STRING_LEN,
+				"PUTVAL %s/dpdkstat-port.%u/%s-%s N:%"
 				PRIu64"\n", host_id, port_id, counter_type,
 				xstats_names[i].name, values[i]);
-			ret = write(stdout_fd, buf, strlen(buf));
+			if (n > sizeof(buf) - 1)
+				n = sizeof(buf) - 1;
+			ret = write(stdout_fd, buf, n);
 			if (ret < 0)
 				goto err;
 		} else {
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:12.900450583 -0800
+++ 0015-app-procinfo-fix-sprintf-overrun.patch	2019-01-02 23:59:12.054816000 -0800
@@ -1,4 +1,4 @@
-From 3cef37eb98769935fbc12e01f06d9ac36d430071 Mon Sep 17 00:00:00 2001
+From a115124be053c3475e0ee16861c98f00965070a0 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Mon, 14 May 2018 13:01:02 +0800
 Subject: [PATCH] app/procinfo: fix sprintf overrun
@@ -6,6 +6,8 @@
 Content-Type: text/plain; charset=UTF-8
 Content-Transfer-Encoding: 8bit
 
+[ upstream commit 3cef37eb98769935fbc12e01f06d9ac36d430071 ]
+
 app/proc-info/main.c: In function ‘nic_xstats_display’:
 app/proc-info/main.c:495:45: error:
 ‘%s’ directive writing up to 255 bytes into a regioni of size between 165 and 232
@@ -23,19 +25,18 @@
      xstats_names[i].name, values[i]);
 
 Fixes: 2deb6b5246d7 ("app/procinfo: add collectd format and host id")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>
 ---
- app/proc-info/main.c | 8 ++++++--
+ app/proc_info/main.c | 8 ++++++--
  1 file changed, 6 insertions(+), 2 deletions(-)
 
-diff --git a/app/proc-info/main.c b/app/proc-info/main.c
-index 539e13243..c20effa4f 100644
---- a/app/proc-info/main.c
-+++ b/app/proc-info/main.c
-@@ -488,14 +488,18 @@ nic_xstats_display(uint16_t port_id)
+diff --git a/app/proc_info/main.c b/app/proc_info/main.c
+index 875d91ea3..2893bec69 100644
+--- a/app/proc_info/main.c
++++ b/app/proc_info/main.c
+@@ -517,14 +517,18 @@ nic_xstats_display(uint16_t port_id)
  		if (enable_collectd_format) {
  			char counter_type[MAX_STRING_LEN];
  			char buf[MAX_STRING_LEN];

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

* [dpdk-stable] patch 'devtools: provide more generic grep in git check' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (13 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'app/procinfo: fix sprintf overrun' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'eal: explicit cast of strlcpy return' " Yongseok Koh
                   ` (20 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Ferruh Yigit, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From fb45c734af4a615a8849802fbb8e62d1748f5df1 Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Mon, 14 May 2018 12:59:56 +0800
Subject: [PATCH] devtools: provide more generic grep in git check

[ upstream commit 5831a2198ade05242535822e480e83692652e02d ]

On Fedora 28, every patch is faulted for
"Wrong headline uppercase", because [A-Z] is not
always case sensitive.

Change to use [[:upper:]]

Signed-off-by: Andy Green <andy@warmcat.com>
Tested-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
 devtools/check-git-log.sh | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/devtools/check-git-log.sh b/devtools/check-git-log.sh
index 910daba42..9014c8241 100755
--- a/devtools/check-git-log.sh
+++ b/devtools/check-git-log.sh
@@ -106,8 +106,8 @@ bad=$(echo "$headlines" | grep --color=always \
 
 # check headline lowercase for first words
 bad=$(echo "$headlines" | grep --color=always \
-	-e '^.*[A-Z].*:' \
-	-e ': *[A-Z]' \
+	-e '^.*[[:upper:]].*:' \
+	-e ': *[[:upper:]]' \
 	| sed 's,^,\t,')
 [ -z "$bad" ] || printf "Wrong headline uppercase:\n$bad\n"
 
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:12.949533738 -0800
+++ 0016-devtools-provide-more-generic-grep-in-git-check.patch	2019-01-02 23:59:12.057815000 -0800
@@ -1,8 +1,10 @@
-From 5831a2198ade05242535822e480e83692652e02d Mon Sep 17 00:00:00 2001
+From fb45c734af4a615a8849802fbb8e62d1748f5df1 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Mon, 14 May 2018 12:59:56 +0800
 Subject: [PATCH] devtools: provide more generic grep in git check
 
+[ upstream commit 5831a2198ade05242535822e480e83692652e02d ]
+
 On Fedora 28, every patch is faulted for
 "Wrong headline uppercase", because [A-Z] is not
 always case sensitive.
@@ -16,7 +18,7 @@
  1 file changed, 2 insertions(+), 2 deletions(-)
 
 diff --git a/devtools/check-git-log.sh b/devtools/check-git-log.sh
-index c601f6ae9..2542d9ee0 100755
+index 910daba42..9014c8241 100755
 --- a/devtools/check-git-log.sh
 +++ b/devtools/check-git-log.sh
 @@ -106,8 +106,8 @@ bad=$(echo "$headlines" | grep --color=always \

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

* [dpdk-stable] patch 'eal: explicit cast of strlcpy return' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (14 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'devtools: provide more generic grep in git check' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'eal: fix casts in random functions' " Yongseok Koh
                   ` (19 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Bruce Richardson, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From 323afa8c5d4166c7591a4f6fad21535b2cede03d Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Thu, 17 May 2018 22:03:48 +0800
Subject: [PATCH] eal: explicit cast of strlcpy return

[ upstream commit 622a7305d1fd1e0150034b82ef92e62250befcd8 ]

GCC 8.1 warns:
rte_string_fns.h: In function 'rte_strlcpy':
rte_string_fns.h:58:9:
warning: conversion to 'size_t' {aka 'long unsigned int'} from
'int' may change the sign of the result [-Wsign-conversion]
  return snprintf(dst, size, "%s", src);
         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Fixes: 5d84a357fe57 ("eal: support strlcpy function")

Signed-off-by: Andy Green <andy@warmcat.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
 lib/librte_eal/common/include/rte_string_fns.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/librte_eal/common/include/rte_string_fns.h b/lib/librte_eal/common/include/rte_string_fns.h
index 7c0ab15a3..7d57bb8ee 100644
--- a/lib/librte_eal/common/include/rte_string_fns.h
+++ b/lib/librte_eal/common/include/rte_string_fns.h
@@ -84,7 +84,7 @@ rte_strsplit(char *string, int stringlen,
 static inline size_t
 rte_strlcpy(char *dst, const char *src, size_t size)
 {
-	return snprintf(dst, size, "%s", src);
+	return (size_t)snprintf(dst, size, "%s", src);
 }
 
 /* pull in a strlcpy function */
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:13.000160826 -0800
+++ 0017-eal-explicit-cast-of-strlcpy-return.patch	2019-01-02 23:59:12.059819000 -0800
@@ -1,8 +1,10 @@
-From 622a7305d1fd1e0150034b82ef92e62250befcd8 Mon Sep 17 00:00:00 2001
+From 323afa8c5d4166c7591a4f6fad21535b2cede03d Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Thu, 17 May 2018 22:03:48 +0800
 Subject: [PATCH] eal: explicit cast of strlcpy return
 
+[ upstream commit 622a7305d1fd1e0150034b82ef92e62250befcd8 ]
+
 GCC 8.1 warns:
 rte_string_fns.h: In function 'rte_strlcpy':
 rte_string_fns.h:58:9:
@@ -11,7 +13,7 @@
   return snprintf(dst, size, "%s", src);
          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
-Fixes: 5364de644a4b ("eal: support strlcpy function")
+Fixes: 5d84a357fe57 ("eal: support strlcpy function")
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Acked-by: Bruce Richardson <bruce.richardson@intel.com>
@@ -20,10 +22,10 @@
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/lib/librte_eal/common/include/rte_string_fns.h b/lib/librte_eal/common/include/rte_string_fns.h
-index fcbb42e00..97597a148 100644
+index 7c0ab15a3..7d57bb8ee 100644
 --- a/lib/librte_eal/common/include/rte_string_fns.h
 +++ b/lib/librte_eal/common/include/rte_string_fns.h
-@@ -55,7 +55,7 @@ rte_strsplit(char *string, int stringlen,
+@@ -84,7 +84,7 @@ rte_strsplit(char *string, int stringlen,
  static inline size_t
  rte_strlcpy(char *dst, const char *src, size_t size)
  {

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

* [dpdk-stable] patch 'eal: fix casts in random functions' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (15 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'eal: explicit cast of strlcpy return' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'eal: explicit cast in constant byte swap' " Yongseok Koh
                   ` (18 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Bruce Richardson, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From 0088eb5cbe18679833d12fc38248d4f16b6d7120 Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Thu, 17 May 2018 21:49:12 +0800
Subject: [PATCH] eal: fix casts in random functions

[ upstream commit d3db77d7d88e1f9227c2847f3355fc3e4bd256e8 ]

GCC 8.1 warns:

In function 'rte_srand':
rte_random.h:34:10:
warning: conversion to 'long int' from 'long unsigned int'
may change the sign of the result [-Wsign-conversion]
  srand48((long unsigned int)seedval);

rte_random.h:51:8:
warning: conversion to 'uint64_t' {aka 'long unsigned int'}
from 'long int' may change the sign of the result
[-Wsign-conversion]
  val = lrand48();
        ^~~~~~~

rte_random.h:53:6:
warning: conversion to 'long unsigned int' from 'long int'
may change the sign of the result [-Wsign-conversion]
  val += lrand48();

Fixes: af75078fece3 ("first public release")

Signed-off-by: Andy Green <andy@warmcat.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
 lib/librte_eal/common/include/rte_random.h | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/lib/librte_eal/common/include/rte_random.h b/lib/librte_eal/common/include/rte_random.h
index aeff1f059..bfbfd13ac 100644
--- a/lib/librte_eal/common/include/rte_random.h
+++ b/lib/librte_eal/common/include/rte_random.h
@@ -60,7 +60,7 @@ extern "C" {
 static inline void
 rte_srand(uint64_t seedval)
 {
-	srand48((long unsigned int)seedval);
+	srand48((long)seedval);
 }
 
 /**
@@ -77,9 +77,9 @@ static inline uint64_t
 rte_rand(void)
 {
 	uint64_t val;
-	val = lrand48();
+	val = (uint64_t)lrand48();
 	val <<= 32;
-	val += lrand48();
+	val += (uint64_t)lrand48();
 	return val;
 }
 
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:13.048995665 -0800
+++ 0018-eal-fix-casts-in-random-functions.patch	2019-01-02 23:59:12.062815000 -0800
@@ -1,8 +1,10 @@
-From d3db77d7d88e1f9227c2847f3355fc3e4bd256e8 Mon Sep 17 00:00:00 2001
+From 0088eb5cbe18679833d12fc38248d4f16b6d7120 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Thu, 17 May 2018 21:49:12 +0800
 Subject: [PATCH] eal: fix casts in random functions
 
+[ upstream commit d3db77d7d88e1f9227c2847f3355fc3e4bd256e8 ]
+
 GCC 8.1 warns:
 
 In function 'rte_srand':
@@ -24,7 +26,6 @@
   val += lrand48();
 
 Fixes: af75078fece3 ("first public release")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Acked-by: Bruce Richardson <bruce.richardson@intel.com>
@@ -33,10 +34,10 @@
  1 file changed, 3 insertions(+), 3 deletions(-)
 
 diff --git a/lib/librte_eal/common/include/rte_random.h b/lib/librte_eal/common/include/rte_random.h
-index 63bb28088..b2ca1c209 100644
+index aeff1f059..bfbfd13ac 100644
 --- a/lib/librte_eal/common/include/rte_random.h
 +++ b/lib/librte_eal/common/include/rte_random.h
-@@ -31,7 +31,7 @@ extern "C" {
+@@ -60,7 +60,7 @@ extern "C" {
  static inline void
  rte_srand(uint64_t seedval)
  {
@@ -45,7 +46,7 @@
  }
  
  /**
-@@ -48,9 +48,9 @@ static inline uint64_t
+@@ -77,9 +77,9 @@ static inline uint64_t
  rte_rand(void)
  {
  	uint64_t val;

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

* [dpdk-stable] patch 'eal: explicit cast in constant byte swap' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (16 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'eal: fix casts in random functions' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'ring: remove useless variables' " Yongseok Koh
                   ` (17 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From bd017fffea36a2cb4a6322c8d5d911397ec4e776 Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Thu, 17 May 2018 21:50:37 +0800
Subject: [PATCH] eal: explicit cast in constant byte swap

[ upstream commit c7bf8093820b0d740e15f166c3fceb1edb2b2a83 ]

GCC 8.1 warns:

rte_byteorder.h: In function 'rte_constant_bswap16':
rte_byteorder.h:54:45: warning: conversion from
'int' to 'uint16_t' {aka 'short unsigned int'}
may change value [-Wconversion]
  ((((uint16_t)(v) & UINT16_C(0x00ff)) << 8) | \
  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~
   (((uint16_t)(v) & UINT16_C(0xff00)) >> 8))
   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
rte_byteorder.h:126:9: note: in expansion of macro
'RTE_STATIC_BSWAP16'
  return RTE_STATIC_BSWAP16(x);
         ^~~~~~~~~~~~~~~~~~

The other two sizes are going to be afflicted the
same, so get the same fix.

Fixes: b75667ef9f7e ("eal: add static endianness conversion macros")

Signed-off-by: Andy Green <andy@warmcat.com>
---
 lib/librte_eal/common/include/generic/rte_byteorder.h | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/lib/librte_eal/common/include/generic/rte_byteorder.h b/lib/librte_eal/common/include/generic/rte_byteorder.h
index 29e70c968..3d7ba5ecc 100644
--- a/lib/librte_eal/common/include/generic/rte_byteorder.h
+++ b/lib/librte_eal/common/include/generic/rte_byteorder.h
@@ -152,7 +152,7 @@ typedef uint64_t rte_le64_t; /**< 64-bit little-endian value. */
 static inline uint16_t
 rte_constant_bswap16(uint16_t x)
 {
-	return RTE_STATIC_BSWAP16(x);
+	return (uint16_t)RTE_STATIC_BSWAP16(x);
 }
 
 /*
@@ -164,7 +164,7 @@ rte_constant_bswap16(uint16_t x)
 static inline uint32_t
 rte_constant_bswap32(uint32_t x)
 {
-	return RTE_STATIC_BSWAP32(x);
+	return (uint32_t)RTE_STATIC_BSWAP32(x);
 }
 
 /*
@@ -176,7 +176,7 @@ rte_constant_bswap32(uint32_t x)
 static inline uint64_t
 rte_constant_bswap64(uint64_t x)
 {
-	return RTE_STATIC_BSWAP64(x);
+	return (uint64_t)RTE_STATIC_BSWAP64(x);
 }
 
 
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:13.099927412 -0800
+++ 0019-eal-explicit-cast-in-constant-byte-swap.patch	2019-01-02 23:59:12.068815000 -0800
@@ -1,8 +1,10 @@
-From c7bf8093820b0d740e15f166c3fceb1edb2b2a83 Mon Sep 17 00:00:00 2001
+From bd017fffea36a2cb4a6322c8d5d911397ec4e776 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Thu, 17 May 2018 21:50:37 +0800
 Subject: [PATCH] eal: explicit cast in constant byte swap
 
+[ upstream commit c7bf8093820b0d740e15f166c3fceb1edb2b2a83 ]
+
 GCC 8.1 warns:
 
 rte_byteorder.h: In function 'rte_constant_bswap16':
@@ -22,7 +24,6 @@
 same, so get the same fix.
 
 Fixes: b75667ef9f7e ("eal: add static endianness conversion macros")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 ---
@@ -30,10 +31,10 @@
  1 file changed, 3 insertions(+), 3 deletions(-)
 
 diff --git a/lib/librte_eal/common/include/generic/rte_byteorder.h b/lib/librte_eal/common/include/generic/rte_byteorder.h
-index 9bed85cca..7d9a1463c 100644
+index 29e70c968..3d7ba5ecc 100644
 --- a/lib/librte_eal/common/include/generic/rte_byteorder.h
 +++ b/lib/librte_eal/common/include/generic/rte_byteorder.h
-@@ -123,7 +123,7 @@ typedef uint64_t rte_le64_t; /**< 64-bit little-endian value. */
+@@ -152,7 +152,7 @@ typedef uint64_t rte_le64_t; /**< 64-bit little-endian value. */
  static inline uint16_t
  rte_constant_bswap16(uint16_t x)
  {
@@ -42,7 +43,7 @@
  }
  
  /*
-@@ -135,7 +135,7 @@ rte_constant_bswap16(uint16_t x)
+@@ -164,7 +164,7 @@ rte_constant_bswap16(uint16_t x)
  static inline uint32_t
  rte_constant_bswap32(uint32_t x)
  {
@@ -51,7 +52,7 @@
  }
  
  /*
-@@ -147,7 +147,7 @@ rte_constant_bswap32(uint32_t x)
+@@ -176,7 +176,7 @@ rte_constant_bswap32(uint32_t x)
  static inline uint64_t
  rte_constant_bswap64(uint64_t x)
  {

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

* [dpdk-stable] patch 'ring: remove useless variables' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (17 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'eal: explicit cast in constant byte swap' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'ring: remove signed type flip-flopping' " Yongseok Koh
                   ` (16 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Olivier Matz, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From cceaf4ae447b26bca6774dc1d3042c78011da798 Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Thu, 17 May 2018 21:49:17 +0800
Subject: [PATCH] ring: remove useless variables

[ backported from upstream commit 712a3db0b5b2c7e6380bdeb84b803bb0e0f97c15 ]

There were warnings with GCC 8.1:

In function '__rte_ring_move_prod_head':
rte_ring_generic.h:76:3:
warning: ISO C90 forbids mixed declarations and code
[-Wdeclaration-after-statement]
   const uint32_t cons_tail = r->cons.tail;
   ^~~~~

In function '__rte_ring_move_cons_head':
rte_ring_generic.h:147:3:
warning: ISO C90 forbids mixed declarations and code
[-Wdeclaration-after-statement]
   const uint32_t prod_tail = r->prod.tail;

Fixes: 0dfc98c507b1 ("ring: separate out head index manipulation")

Signed-off-by: Andy Green <andy@warmcat.com>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
---
 lib/librte_ring/rte_ring.h | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/lib/librte_ring/rte_ring.h b/lib/librte_ring/rte_ring.h
index fc433b050..5b1cb2bfe 100644
--- a/lib/librte_ring/rte_ring.h
+++ b/lib/librte_ring/rte_ring.h
@@ -416,14 +416,13 @@ __rte_ring_move_prod_head(struct rte_ring *r, int is_sp,
 		 */
 		rte_smp_rmb();
 
-		const uint32_t cons_tail = r->cons.tail;
 		/*
 		 *  The subtraction is done between two unsigned 32bits value
 		 * (the result is always modulo 32 bits even if we have
 		 * *old_head > cons_tail). So 'free_entries' is always between 0
 		 * and capacity (which is < size).
 		 */
-		*free_entries = (capacity + cons_tail - *old_head);
+		*free_entries = (capacity + r->cons.tail - *old_head);
 
 		/* check that we have enough room in ring */
 		if (unlikely(n > *free_entries))
@@ -530,12 +529,11 @@ __rte_ring_move_cons_head(struct rte_ring *r, int is_sc,
 		 */
 		rte_smp_rmb();
 
-		const uint32_t prod_tail = r->prod.tail;
 		/* The subtraction is done between two unsigned 32bits value
 		 * (the result is always modulo 32 bits even if we have
 		 * cons_head > prod_tail). So 'entries' is always between 0
 		 * and size(ring)-1. */
-		*entries = (prod_tail - *old_head);
+		*entries = (r->prod.tail - *old_head);
 
 		/* Set the actual entries for dequeue */
 		if (n > *entries)
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:13.159530981 -0800
+++ 0020-ring-remove-useless-variables.patch	2019-01-02 23:59:12.070818000 -0800
@@ -1,8 +1,10 @@
-From 712a3db0b5b2c7e6380bdeb84b803bb0e0f97c15 Mon Sep 17 00:00:00 2001
+From cceaf4ae447b26bca6774dc1d3042c78011da798 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Thu, 17 May 2018 21:49:17 +0800
 Subject: [PATCH] ring: remove useless variables
 
+[ backported from upstream commit 712a3db0b5b2c7e6380bdeb84b803bb0e0f97c15 ]
+
 There were warnings with GCC 8.1:
 
 In function '__rte_ring_move_prod_head':
@@ -19,19 +21,18 @@
    const uint32_t prod_tail = r->prod.tail;
 
 Fixes: 0dfc98c507b1 ("ring: separate out head index manipulation")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Acked-by: Olivier Matz <olivier.matz@6wind.com>
 ---
- lib/librte_ring/rte_ring_generic.h | 6 ++----
+ lib/librte_ring/rte_ring.h | 6 ++----
  1 file changed, 2 insertions(+), 4 deletions(-)
 
-diff --git a/lib/librte_ring/rte_ring_generic.h b/lib/librte_ring/rte_ring_generic.h
-index 5b110425f..c2d482bc9 100644
---- a/lib/librte_ring/rte_ring_generic.h
-+++ b/lib/librte_ring/rte_ring_generic.h
-@@ -73,14 +73,13 @@ __rte_ring_move_prod_head(struct rte_ring *r, int is_sp,
+diff --git a/lib/librte_ring/rte_ring.h b/lib/librte_ring/rte_ring.h
+index fc433b050..5b1cb2bfe 100644
+--- a/lib/librte_ring/rte_ring.h
++++ b/lib/librte_ring/rte_ring.h
+@@ -416,14 +416,13 @@ __rte_ring_move_prod_head(struct rte_ring *r, int is_sp,
  		 */
  		rte_smp_rmb();
  
@@ -47,7 +48,7 @@
  
  		/* check that we have enough room in ring */
  		if (unlikely(n > *free_entries))
-@@ -144,13 +143,12 @@ __rte_ring_move_cons_head(struct rte_ring *r, int is_sc,
+@@ -530,12 +529,11 @@ __rte_ring_move_cons_head(struct rte_ring *r, int is_sc,
  		 */
  		rte_smp_rmb();
  
@@ -55,8 +56,7 @@
  		/* The subtraction is done between two unsigned 32bits value
  		 * (the result is always modulo 32 bits even if we have
  		 * cons_head > prod_tail). So 'entries' is always between 0
- 		 * and size(ring)-1.
- 		 */
+ 		 * and size(ring)-1. */
 -		*entries = (prod_tail - *old_head);
 +		*entries = (r->prod.tail - *old_head);
  

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

* [dpdk-stable] patch 'ring: remove signed type flip-flopping' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (18 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'ring: remove useless variables' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'mbuf: fix reference counter integer promotion' " Yongseok Koh
                   ` (15 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Olivier Matz, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From fd01e7cec2c5b5bc24b75f2ad3ea2ee73dbf2bba Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Thu, 17 May 2018 21:49:22 +0800
Subject: [PATCH] ring: remove signed type flip-flopping

[ backported from upstream commit e8ed5056c8747cd5d95a41749e48987ad44dc9b3 ]

GCC 8.1 warns:

rte_ring.h:350:46:
warning: conversion to 'uint32_t' {aka 'unsigned int'}
from 'int' may change the sign of the result
[-Wsign-conversion]
  update_tail(&r->prod, prod_head, prod_next, is_sp, 1);

The visible apis take unsigned int, then call a private
api taking an int, which finally calls an api taking an
unsigned int.

Convert the private api to take unsigned int removing
5 x warning similar to that shown above.

Fixes: 0dfc98c507b1 ("ring: separate out head index manipulation")

Signed-off-by: Andy Green <andy@warmcat.com>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
---
 lib/librte_ring/rte_ring.h | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/lib/librte_ring/rte_ring.h b/lib/librte_ring/rte_ring.h
index 5b1cb2bfe..978c4dd17 100644
--- a/lib/librte_ring/rte_ring.h
+++ b/lib/librte_ring/rte_ring.h
@@ -396,7 +396,7 @@ update_tail(struct rte_ring_headtail *ht, uint32_t old_val, uint32_t new_val,
  *   If behavior == RTE_RING_QUEUE_FIXED, this will be 0 or n only.
  */
 static __rte_always_inline unsigned int
-__rte_ring_move_prod_head(struct rte_ring *r, int is_sp,
+__rte_ring_move_prod_head(struct rte_ring *r, unsigned int is_sp,
 		unsigned int n, enum rte_ring_queue_behavior behavior,
 		uint32_t *old_head, uint32_t *new_head,
 		uint32_t *free_entries)
@@ -465,7 +465,7 @@ __rte_ring_move_prod_head(struct rte_ring *r, int is_sp,
 static __rte_always_inline unsigned int
 __rte_ring_do_enqueue(struct rte_ring *r, void * const *obj_table,
 		 unsigned int n, enum rte_ring_queue_behavior behavior,
-		 int is_sp, unsigned int *free_space)
+		 unsigned int is_sp, unsigned int *free_space)
 {
 	uint32_t prod_head, prod_next;
 	uint32_t free_entries;
@@ -509,7 +509,7 @@ end:
  *     If behavior == RTE_RING_QUEUE_FIXED, this will be 0 or n only.
  */
 static __rte_always_inline unsigned int
-__rte_ring_move_cons_head(struct rte_ring *r, int is_sc,
+__rte_ring_move_cons_head(struct rte_ring *r, unsigned int is_sc,
 		unsigned int n, enum rte_ring_queue_behavior behavior,
 		uint32_t *old_head, uint32_t *new_head,
 		uint32_t *entries)
@@ -575,7 +575,7 @@ __rte_ring_move_cons_head(struct rte_ring *r, int is_sc,
 static __rte_always_inline unsigned int
 __rte_ring_do_dequeue(struct rte_ring *r, void **obj_table,
 		 unsigned int n, enum rte_ring_queue_behavior behavior,
-		 int is_sc, unsigned int *available)
+		 unsigned int is_sc, unsigned int *available)
 {
 	uint32_t cons_head, cons_next;
 	uint32_t entries;
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:13.209654010 -0800
+++ 0021-ring-remove-signed-type-flip-flopping.patch	2019-01-02 23:59:12.072818000 -0800
@@ -1,8 +1,10 @@
-From e8ed5056c8747cd5d95a41749e48987ad44dc9b3 Mon Sep 17 00:00:00 2001
+From fd01e7cec2c5b5bc24b75f2ad3ea2ee73dbf2bba Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Thu, 17 May 2018 21:49:22 +0800
 Subject: [PATCH] ring: remove signed type flip-flopping
 
+[ backported from upstream commit e8ed5056c8747cd5d95a41749e48987ad44dc9b3 ]
+
 GCC 8.1 warns:
 
 rte_ring.h:350:46:
@@ -19,43 +21,18 @@
 5 x warning similar to that shown above.
 
 Fixes: 0dfc98c507b1 ("ring: separate out head index manipulation")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Acked-by: Olivier Matz <olivier.matz@6wind.com>
 ---
- lib/librte_ring/rte_ring.h         | 4 ++--
- lib/librte_ring/rte_ring_c11_mem.h | 2 +-
- lib/librte_ring/rte_ring_generic.h | 4 ++--
- 3 files changed, 5 insertions(+), 5 deletions(-)
+ lib/librte_ring/rte_ring.h | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
 
 diff --git a/lib/librte_ring/rte_ring.h b/lib/librte_ring/rte_ring.h
-index d3d3f7f97..124582251 100644
+index 5b1cb2bfe..978c4dd17 100644
 --- a/lib/librte_ring/rte_ring.h
 +++ b/lib/librte_ring/rte_ring.h
-@@ -335,7 +335,7 @@ void rte_ring_dump(FILE *f, const struct rte_ring *r);
- static __rte_always_inline unsigned int
- __rte_ring_do_enqueue(struct rte_ring *r, void * const *obj_table,
- 		 unsigned int n, enum rte_ring_queue_behavior behavior,
--		 int is_sp, unsigned int *free_space)
-+		 unsigned int is_sp, unsigned int *free_space)
- {
- 	uint32_t prod_head, prod_next;
- 	uint32_t free_entries;
-@@ -377,7 +377,7 @@ end:
- static __rte_always_inline unsigned int
- __rte_ring_do_dequeue(struct rte_ring *r, void **obj_table,
- 		 unsigned int n, enum rte_ring_queue_behavior behavior,
--		 int is_sc, unsigned int *available)
-+		 unsigned int is_sc, unsigned int *available)
- {
- 	uint32_t cons_head, cons_next;
- 	uint32_t entries;
-diff --git a/lib/librte_ring/rte_ring_c11_mem.h b/lib/librte_ring/rte_ring_c11_mem.h
-index 08825ea5b..cb3f82b1a 100644
---- a/lib/librte_ring/rte_ring_c11_mem.h
-+++ b/lib/librte_ring/rte_ring_c11_mem.h
-@@ -51,7 +51,7 @@ update_tail(struct rte_ring_headtail *ht, uint32_t old_val, uint32_t new_val,
+@@ -396,7 +396,7 @@ update_tail(struct rte_ring_headtail *ht, uint32_t old_val, uint32_t new_val,
   *   If behavior == RTE_RING_QUEUE_FIXED, this will be 0 or n only.
   */
  static __rte_always_inline unsigned int
@@ -64,20 +41,16 @@
  		unsigned int n, enum rte_ring_queue_behavior behavior,
  		uint32_t *old_head, uint32_t *new_head,
  		uint32_t *free_entries)
-diff --git a/lib/librte_ring/rte_ring_generic.h b/lib/librte_ring/rte_ring_generic.h
-index c2d482bc9..ea7dbe5b9 100644
---- a/lib/librte_ring/rte_ring_generic.h
-+++ b/lib/librte_ring/rte_ring_generic.h
-@@ -53,7 +53,7 @@ update_tail(struct rte_ring_headtail *ht, uint32_t old_val, uint32_t new_val,
-  *   If behavior == RTE_RING_QUEUE_FIXED, this will be 0 or n only.
-  */
+@@ -465,7 +465,7 @@ __rte_ring_move_prod_head(struct rte_ring *r, int is_sp,
  static __rte_always_inline unsigned int
--__rte_ring_move_prod_head(struct rte_ring *r, int is_sp,
-+__rte_ring_move_prod_head(struct rte_ring *r, unsigned int is_sp,
- 		unsigned int n, enum rte_ring_queue_behavior behavior,
- 		uint32_t *old_head, uint32_t *new_head,
- 		uint32_t *free_entries)
-@@ -123,7 +123,7 @@ __rte_ring_move_prod_head(struct rte_ring *r, int is_sp,
+ __rte_ring_do_enqueue(struct rte_ring *r, void * const *obj_table,
+ 		 unsigned int n, enum rte_ring_queue_behavior behavior,
+-		 int is_sp, unsigned int *free_space)
++		 unsigned int is_sp, unsigned int *free_space)
+ {
+ 	uint32_t prod_head, prod_next;
+ 	uint32_t free_entries;
+@@ -509,7 +509,7 @@ end:
   *     If behavior == RTE_RING_QUEUE_FIXED, this will be 0 or n only.
   */
  static __rte_always_inline unsigned int
@@ -86,6 +59,15 @@
  		unsigned int n, enum rte_ring_queue_behavior behavior,
  		uint32_t *old_head, uint32_t *new_head,
  		uint32_t *entries)
+@@ -575,7 +575,7 @@ __rte_ring_move_cons_head(struct rte_ring *r, int is_sc,
+ static __rte_always_inline unsigned int
+ __rte_ring_do_dequeue(struct rte_ring *r, void **obj_table,
+ 		 unsigned int n, enum rte_ring_queue_behavior behavior,
+-		 int is_sc, unsigned int *available)
++		 unsigned int is_sc, unsigned int *available)
+ {
+ 	uint32_t cons_head, cons_next;
+ 	uint32_t entries;
 -- 
 2.11.0
 

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

* [dpdk-stable] patch 'mbuf: fix reference counter integer promotion' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (19 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'ring: remove signed type flip-flopping' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'mbuf: explicit casts of reference counter' " Yongseok Koh
                   ` (14 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Olivier Matz, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From c7e94462ba69a778ef76f97dcafbf8de0370883f Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Thu, 17 May 2018 21:49:27 +0800
Subject: [PATCH] mbuf: fix reference counter integer promotion

[ upstream commit ee07d519ceb05e59dd970c48a42cf2f09b3ac4dc ]

GCC 8.1 warned:

"1 + value", where value is an uint16_t causes promotion
to a signed int.  The compiler complained that we are
shoving an int into a uint16_t return type with different
size and sign.

Bumping and returning value directly instead removes the
promotion and the problem.

Fixes: f20b50b946da ("mbuf: optimize refcnt update")

Signed-off-by: Andy Green <andy@warmcat.com>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
---
 lib/librte_mbuf/rte_mbuf.h | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h
index e5697614f..4f6e0f7e3 100644
--- a/lib/librte_mbuf/rte_mbuf.h
+++ b/lib/librte_mbuf/rte_mbuf.h
@@ -789,8 +789,9 @@ rte_mbuf_refcnt_update(struct rte_mbuf *m, int16_t value)
 	 * reference counter can occur.
 	 */
 	if (likely(rte_mbuf_refcnt_read(m) == 1)) {
-		rte_mbuf_refcnt_set(m, 1 + value);
-		return 1 + value;
+		++value;
+		rte_mbuf_refcnt_set(m, value);
+		return value;
 	}
 
 	return __rte_mbuf_refcnt_update(m, value);
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:13.262883446 -0800
+++ 0022-mbuf-fix-reference-counter-integer-promotion.patch	2019-01-02 23:59:12.076816000 -0800
@@ -1,8 +1,10 @@
-From ee07d519ceb05e59dd970c48a42cf2f09b3ac4dc Mon Sep 17 00:00:00 2001
+From c7e94462ba69a778ef76f97dcafbf8de0370883f Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Thu, 17 May 2018 21:49:27 +0800
 Subject: [PATCH] mbuf: fix reference counter integer promotion
 
+[ upstream commit ee07d519ceb05e59dd970c48a42cf2f09b3ac4dc ]
+
 GCC 8.1 warned:
 
 "1 + value", where value is an uint16_t causes promotion
@@ -14,20 +16,18 @@
 promotion and the problem.
 
 Fixes: f20b50b946da ("mbuf: optimize refcnt update")
-Fixes: a53aa2b9f3be ("mbuf: support attaching external buffer")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Acked-by: Olivier Matz <olivier.matz@6wind.com>
 ---
- lib/librte_mbuf/rte_mbuf.h | 10 ++++++----
- 1 file changed, 6 insertions(+), 4 deletions(-)
+ lib/librte_mbuf/rte_mbuf.h | 5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
 
 diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h
-index eab13c6bf..8a2dae23b 100644
+index e5697614f..4f6e0f7e3 100644
 --- a/lib/librte_mbuf/rte_mbuf.h
 +++ b/lib/librte_mbuf/rte_mbuf.h
-@@ -836,8 +836,9 @@ rte_mbuf_refcnt_update(struct rte_mbuf *m, int16_t value)
+@@ -789,8 +789,9 @@ rte_mbuf_refcnt_update(struct rte_mbuf *m, int16_t value)
  	 * reference counter can occur.
  	 */
  	if (likely(rte_mbuf_refcnt_read(m) == 1)) {
@@ -39,18 +39,6 @@
  	}
  
  	return __rte_mbuf_refcnt_update(m, value);
-@@ -927,8 +928,9 @@ rte_mbuf_ext_refcnt_update(struct rte_mbuf_ext_shared_info *shinfo,
- 	int16_t value)
- {
- 	if (likely(rte_mbuf_ext_refcnt_read(shinfo) == 1)) {
--		rte_mbuf_ext_refcnt_set(shinfo, 1 + value);
--		return 1 + value;
-+		++value;
-+		rte_mbuf_ext_refcnt_set(shinfo, value);
-+		return value;
- 	}
- 
- 	return (uint16_t)rte_atomic16_add_return(&shinfo->refcnt_atomic, value);
 -- 
 2.11.0
 

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

* [dpdk-stable] patch 'mbuf: explicit casts of reference counter' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (20 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'mbuf: fix reference counter integer promotion' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'mbuf: explicit cast of headroom on reset' " Yongseok Koh
                   ` (13 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Olivier Matz, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From 6e3304c3b22e94a6c6f655f0f46803da80bf529e Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Thu, 17 May 2018 21:49:32 +0800
Subject: [PATCH] mbuf: explicit casts of reference counter

[ backported from upstream commit f6ffdf1c2c1cfbb2a3cbce246b545560609abeb5 ]

differences to the atomic16 are signed, but the
atomic16 itself is unsigned.  It needs to be
made explicit with casts.

Fixes: af75078fece3 ("first public release")

Signed-off-by: Andy Green <andy@warmcat.com>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
---
 lib/librte_mbuf/rte_mbuf.h | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h
index 4f6e0f7e3..ce1ae55b7 100644
--- a/lib/librte_mbuf/rte_mbuf.h
+++ b/lib/librte_mbuf/rte_mbuf.h
@@ -759,7 +759,7 @@ rte_mbuf_refcnt_read(const struct rte_mbuf *m)
 static inline void
 rte_mbuf_refcnt_set(struct rte_mbuf *m, uint16_t new_value)
 {
-	rte_atomic16_set(&m->refcnt_atomic, new_value);
+	rte_atomic16_set(&m->refcnt_atomic, (int16_t)new_value);
 }
 
 /* internal */
@@ -790,8 +790,8 @@ rte_mbuf_refcnt_update(struct rte_mbuf *m, int16_t value)
 	 */
 	if (likely(rte_mbuf_refcnt_read(m) == 1)) {
 		++value;
-		rte_mbuf_refcnt_set(m, value);
-		return value;
+		rte_mbuf_refcnt_set(m, (uint16_t)value);
+		return (uint16_t)value;
 	}
 
 	return __rte_mbuf_refcnt_update(m, value);
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:13.311112437 -0800
+++ 0023-mbuf-explicit-casts-of-reference-counter.patch	2019-01-02 23:59:12.078820000 -0800
@@ -1,27 +1,27 @@
-From f6ffdf1c2c1cfbb2a3cbce246b545560609abeb5 Mon Sep 17 00:00:00 2001
+From 6e3304c3b22e94a6c6f655f0f46803da80bf529e Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Thu, 17 May 2018 21:49:32 +0800
 Subject: [PATCH] mbuf: explicit casts of reference counter
 
+[ backported from upstream commit f6ffdf1c2c1cfbb2a3cbce246b545560609abeb5 ]
+
 differences to the atomic16 are signed, but the
 atomic16 itself is unsigned.  It needs to be
 made explicit with casts.
 
 Fixes: af75078fece3 ("first public release")
-Fixes: a53aa2b9f3be ("mbuf: support attaching external buffer")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Acked-by: Olivier Matz <olivier.matz@6wind.com>
 ---
- lib/librte_mbuf/rte_mbuf.h | 12 ++++++------
- 1 file changed, 6 insertions(+), 6 deletions(-)
+ lib/librte_mbuf/rte_mbuf.h | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
 
 diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h
-index 8a2dae23b..b776a6f24 100644
+index 4f6e0f7e3..ce1ae55b7 100644
 --- a/lib/librte_mbuf/rte_mbuf.h
 +++ b/lib/librte_mbuf/rte_mbuf.h
-@@ -806,7 +806,7 @@ rte_mbuf_refcnt_read(const struct rte_mbuf *m)
+@@ -759,7 +759,7 @@ rte_mbuf_refcnt_read(const struct rte_mbuf *m)
  static inline void
  rte_mbuf_refcnt_set(struct rte_mbuf *m, uint16_t new_value)
  {
@@ -30,7 +30,7 @@
  }
  
  /* internal */
-@@ -837,8 +837,8 @@ rte_mbuf_refcnt_update(struct rte_mbuf *m, int16_t value)
+@@ -790,8 +790,8 @@ rte_mbuf_refcnt_update(struct rte_mbuf *m, int16_t value)
  	 */
  	if (likely(rte_mbuf_refcnt_read(m) == 1)) {
  		++value;
@@ -41,26 +41,6 @@
  	}
  
  	return __rte_mbuf_refcnt_update(m, value);
-@@ -909,7 +909,7 @@ static inline void
- rte_mbuf_ext_refcnt_set(struct rte_mbuf_ext_shared_info *shinfo,
- 	uint16_t new_value)
- {
--	rte_atomic16_set(&shinfo->refcnt_atomic, new_value);
-+	rte_atomic16_set(&shinfo->refcnt_atomic, (int16_t)new_value);
- }
- 
- /**
-@@ -929,8 +929,8 @@ rte_mbuf_ext_refcnt_update(struct rte_mbuf_ext_shared_info *shinfo,
- {
- 	if (likely(rte_mbuf_ext_refcnt_read(shinfo) == 1)) {
- 		++value;
--		rte_mbuf_ext_refcnt_set(shinfo, value);
--		return value;
-+		rte_mbuf_ext_refcnt_set(shinfo, (uint16_t)value);
-+		return (uint16_t)value;
- 	}
- 
- 	return (uint16_t)rte_atomic16_add_return(&shinfo->refcnt_atomic, value);
 -- 
 2.11.0
 

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

* [dpdk-stable] patch 'mbuf: explicit cast of headroom on reset' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (21 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'mbuf: explicit casts of reference counter' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'mbuf: explicit cast of size on detach' " Yongseok Koh
                   ` (12 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Bruce Richardson, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From 1a5e0f682a80f21a98a0b2c4feb06f824094451e Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Thu, 17 May 2018 21:49:37 +0800
Subject: [PATCH] mbuf: explicit cast of headroom on reset

[ upstream commit 553ff494cb4d7fa9539911d3bbb4d94de5f69f20 ]

GCC 8.1 warned:

rte_common.h:384:2:
warning: conversion from 'int' to 'uint16_t'
{aka 'short unsigned int'} may change value [-Wconversion]
  __extension__ ({ \
  ^~~~~~~~~~~~~
rte_mbuf.h:1204:16:
note: in expansion of macro 'RTE_MIN'
  m->data_off = RTE_MIN(RTE_PKTMBUF_HEADROOM, (uint16_t)m->buf_len);

RTE_PKTMBUF_HEADROOM is typ 128, so it doesn't make trouble.

Fixes: 08b563ffb19d ("mbuf: replace data pointer by an offset")

Signed-off-by: Andy Green <andy@warmcat.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
 lib/librte_mbuf/rte_mbuf.h | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h
index ce1ae55b7..5b9139739 100644
--- a/lib/librte_mbuf/rte_mbuf.h
+++ b/lib/librte_mbuf/rte_mbuf.h
@@ -1144,7 +1144,8 @@ rte_pktmbuf_priv_size(struct rte_mempool *mp)
  */
 static inline void rte_pktmbuf_reset_headroom(struct rte_mbuf *m)
 {
-	m->data_off = RTE_MIN(RTE_PKTMBUF_HEADROOM, (uint16_t)m->buf_len);
+	m->data_off = (uint16_t)RTE_MIN((uint16_t)RTE_PKTMBUF_HEADROOM,
+					(uint16_t)m->buf_len);
 }
 
 /**
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:13.365609496 -0800
+++ 0024-mbuf-explicit-cast-of-headroom-on-reset.patch	2019-01-02 23:59:12.080818000 -0800
@@ -1,8 +1,10 @@
-From 553ff494cb4d7fa9539911d3bbb4d94de5f69f20 Mon Sep 17 00:00:00 2001
+From 1a5e0f682a80f21a98a0b2c4feb06f824094451e Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Thu, 17 May 2018 21:49:37 +0800
 Subject: [PATCH] mbuf: explicit cast of headroom on reset
 
+[ upstream commit 553ff494cb4d7fa9539911d3bbb4d94de5f69f20 ]
+
 GCC 8.1 warned:
 
 rte_common.h:384:2:
@@ -17,7 +19,6 @@
 RTE_PKTMBUF_HEADROOM is typ 128, so it doesn't make trouble.
 
 Fixes: 08b563ffb19d ("mbuf: replace data pointer by an offset")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Acked-by: Bruce Richardson <bruce.richardson@intel.com>
@@ -26,10 +27,10 @@
  1 file changed, 2 insertions(+), 1 deletion(-)
 
 diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h
-index b776a6f24..0a94e3ece 100644
+index ce1ae55b7..5b9139739 100644
 --- a/lib/librte_mbuf/rte_mbuf.h
 +++ b/lib/librte_mbuf/rte_mbuf.h
-@@ -1201,7 +1201,8 @@ rte_pktmbuf_priv_size(struct rte_mempool *mp)
+@@ -1144,7 +1144,8 @@ rte_pktmbuf_priv_size(struct rte_mempool *mp)
   */
  static inline void rte_pktmbuf_reset_headroom(struct rte_mbuf *m)
  {

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

* [dpdk-stable] patch 'mbuf: explicit cast of size on detach' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (22 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'mbuf: explicit cast of headroom on reset' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'net: explicit cast of multicast bit clearing' " Yongseok Koh
                   ` (11 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From 5cdc66f3144650e5f0f6688f11ea00dcc835015b Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Thu, 17 May 2018 21:50:22 +0800
Subject: [PATCH] mbuf: explicit cast of size on detach

[ upstream commit c779ebdca0e4765158bd1eaa6f65c9d714605fae ]

GCC 8.1 warned:

In function 'rte_pktmbuf_detach':
rte_mbuf.h:1580:14: warning: conversion from 'long unsigned int'
to 'uint32_t' {aka 'unsigned int'} may change value [-Wconversion]
  mbuf_size = sizeof(struct rte_mbuf) + priv_size;
              ^~~~~~

Fixes: 355e6735b335 ("mbuf: fix cloning with private mbuf data")

Signed-off-by: Andy Green <andy@warmcat.com>
---
 lib/librte_mbuf/rte_mbuf.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h
index 5b9139739..07687c39b 100644
--- a/lib/librte_mbuf/rte_mbuf.h
+++ b/lib/librte_mbuf/rte_mbuf.h
@@ -1328,7 +1328,7 @@ static inline void rte_pktmbuf_detach(struct rte_mbuf *m)
 	uint32_t mbuf_size, buf_len, priv_size;
 
 	priv_size = rte_pktmbuf_priv_size(mp);
-	mbuf_size = sizeof(struct rte_mbuf) + priv_size;
+	mbuf_size = (uint32_t)(sizeof(struct rte_mbuf) + priv_size);
 	buf_len = rte_pktmbuf_data_room_size(mp);
 
 	m->priv_size = priv_size;
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:13.416888900 -0800
+++ 0025-mbuf-explicit-cast-of-size-on-detach.patch	2019-01-02 23:59:12.082816000 -0800
@@ -1,8 +1,10 @@
-From c779ebdca0e4765158bd1eaa6f65c9d714605fae Mon Sep 17 00:00:00 2001
+From 5cdc66f3144650e5f0f6688f11ea00dcc835015b Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Thu, 17 May 2018 21:50:22 +0800
 Subject: [PATCH] mbuf: explicit cast of size on detach
 
+[ upstream commit c779ebdca0e4765158bd1eaa6f65c9d714605fae ]
+
 GCC 8.1 warned:
 
 In function 'rte_pktmbuf_detach':
@@ -12,7 +14,6 @@
               ^~~~~~
 
 Fixes: 355e6735b335 ("mbuf: fix cloning with private mbuf data")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 ---
@@ -20,11 +21,11 @@
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h
-index ae0fa4d7c..28fd4ad52 100644
+index 5b9139739..07687c39b 100644
 --- a/lib/librte_mbuf/rte_mbuf.h
 +++ b/lib/librte_mbuf/rte_mbuf.h
-@@ -1579,7 +1579,7 @@ static inline void rte_pktmbuf_detach(struct rte_mbuf *m)
- 		__rte_pktmbuf_free_direct(m);
+@@ -1328,7 +1328,7 @@ static inline void rte_pktmbuf_detach(struct rte_mbuf *m)
+ 	uint32_t mbuf_size, buf_len, priv_size;
  
  	priv_size = rte_pktmbuf_priv_size(mp);
 -	mbuf_size = sizeof(struct rte_mbuf) + priv_size;

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

* [dpdk-stable] patch 'net: explicit cast of multicast bit clearing' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (23 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'mbuf: explicit cast of size on detach' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'net: explicit cast of IP checksum to 16-bit' " Yongseok Koh
                   ` (10 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Bruce Richardson, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From 45f354944bcb9e5a670d74b416f867d8e431f1f9 Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Thu, 17 May 2018 21:49:47 +0800
Subject: [PATCH] net: explicit cast of multicast bit clearing

[ upstream commit beb4076567441bb6f936f99f442c2a8de911bb3c ]

GCC 8.1 warned:

rte_ether.h:213:13:
warning: conversion from 'int' to 'uint8_t'
{aka 'unsigned char'} may change value [-Wconversion]
  addr[0] &= ~ETHER_GROUP_ADDR;

Fixes: 7ef007291004 ("ethdev: random MAC address")

Signed-off-by: Andy Green <andy@warmcat.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
 lib/librte_net/rte_ether.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/librte_net/rte_ether.h b/lib/librte_net/rte_ether.h
index 10d906e6f..f7a9a8695 100644
--- a/lib/librte_net/rte_ether.h
+++ b/lib/librte_net/rte_ether.h
@@ -239,7 +239,7 @@ static inline void eth_random_addr(uint8_t *addr)
 	uint8_t *p = (uint8_t *)&rand;
 
 	rte_memcpy(addr, p, ETHER_ADDR_LEN);
-	addr[0] &= ~ETHER_GROUP_ADDR;       /* clear multicast bit */
+	addr[0] &= (uint8_t)~ETHER_GROUP_ADDR;       /* clear multicast bit */
 	addr[0] |= ETHER_LOCAL_ADMIN_ADDR;  /* set local assignment bit */
 }
 
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:13.466990483 -0800
+++ 0026-net-explicit-cast-of-multicast-bit-clearing.patch	2019-01-02 23:59:12.083819000 -0800
@@ -1,8 +1,10 @@
-From beb4076567441bb6f936f99f442c2a8de911bb3c Mon Sep 17 00:00:00 2001
+From 45f354944bcb9e5a670d74b416f867d8e431f1f9 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Thu, 17 May 2018 21:49:47 +0800
 Subject: [PATCH] net: explicit cast of multicast bit clearing
 
+[ upstream commit beb4076567441bb6f936f99f442c2a8de911bb3c ]
+
 GCC 8.1 warned:
 
 rte_ether.h:213:13:
@@ -11,7 +13,6 @@
   addr[0] &= ~ETHER_GROUP_ADDR;
 
 Fixes: 7ef007291004 ("ethdev: random MAC address")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Acked-by: Bruce Richardson <bruce.richardson@intel.com>
@@ -20,10 +21,10 @@
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/lib/librte_net/rte_ether.h b/lib/librte_net/rte_ether.h
-index 27c919594..bee2b34f0 100644
+index 10d906e6f..f7a9a8695 100644
 --- a/lib/librte_net/rte_ether.h
 +++ b/lib/librte_net/rte_ether.h
-@@ -210,7 +210,7 @@ static inline void eth_random_addr(uint8_t *addr)
+@@ -239,7 +239,7 @@ static inline void eth_random_addr(uint8_t *addr)
  	uint8_t *p = (uint8_t *)&rand;
  
  	rte_memcpy(addr, p, ETHER_ADDR_LEN);

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

* [dpdk-stable] patch 'net: explicit cast of IP checksum to 16-bit' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (24 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'net: explicit cast of multicast bit clearing' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'net: explicit cast of protocol in IPv6 checksum' " Yongseok Koh
                   ` (9 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From bdc221571cebe6eda8d9d08f933ad85ae08ab1c2 Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Thu, 17 May 2018 21:49:57 +0800
Subject: [PATCH] net: explicit cast of IP checksum to 16-bit

[ upstream commit 466de6d5d8648f6a2c6cfc90c2d1bf217dd06e90 ]

GCC 8.1 warned:

In function 'rte_raw_cksum_mbuf':
rte_ip.h:225:22: warning: conversion from 'uint32_t'
{aka 'unsigned int'} to 'uint16_t' {aka 'short unsigned int'}
may change value [-Wconversion]
    tmp = rte_bswap16(tmp);
                      ^~~

In function 'rte_ipv4_cksum':
rte_ip.h:256:35: warning: conversion from 'int' to 'uint16_t'
{aka 'short unsigned int'} may change value [-Wconversion]
  return (cksum == 0xffff) ? cksum : ~cksum;
         ~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~

rte_ip.h:332:9: warning: conversion from 'uint32_t'
{aka 'unsigned int'} to 'uint16_t' {aka 'short unsigned int'}
may change value [-Wconversion]
  return cksum;
         ^~~~~

In function 'rte_ipv6_udptcp_cksum':
rte_ip.h:421:9: warning: conversion from 'uint32_t' {aka 'unsigned int'}
to 'uint16_t' {aka 'short unsigned int'} may change value [-Wconversion]
  return cksum;
         ^~~~~

Fixes: 6006818cfb26 ("net: new checksum functions")
Fixes: 4199fdea60c3 ("mbuf: generic support for TCP segmentation offload")

Signed-off-by: Andy Green <andy@warmcat.com>
---
 lib/librte_net/rte_ip.h | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/lib/librte_net/rte_ip.h b/lib/librte_net/rte_ip.h
index 23468cb99..332ac1414 100644
--- a/lib/librte_net/rte_ip.h
+++ b/lib/librte_net/rte_ip.h
@@ -284,7 +284,7 @@ rte_raw_cksum_mbuf(const struct rte_mbuf *m, uint32_t off, uint32_t len,
 	for (;;) {
 		tmp = __rte_raw_cksum(buf, seglen, 0);
 		if (done & 1)
-			tmp = rte_bswap16(tmp);
+			tmp = rte_bswap16((uint16_t)tmp);
 		sum += tmp;
 		done += seglen;
 		if (done == len)
@@ -315,7 +315,7 @@ rte_ipv4_cksum(const struct ipv4_hdr *ipv4_hdr)
 {
 	uint16_t cksum;
 	cksum = rte_raw_cksum(ipv4_hdr, sizeof(struct ipv4_hdr));
-	return (cksum == 0xffff) ? cksum : ~cksum;
+	return (cksum == 0xffff) ? cksum : (uint16_t)~cksum;
 }
 
 /**
@@ -391,7 +391,7 @@ rte_ipv4_udptcp_cksum(const struct ipv4_hdr *ipv4_hdr, const void *l4_hdr)
 	if (cksum == 0)
 		cksum = 0xffff;
 
-	return cksum;
+	return (uint16_t)cksum;
 }
 
 /**
@@ -480,7 +480,7 @@ rte_ipv6_udptcp_cksum(const struct ipv6_hdr *ipv6_hdr, const void *l4_hdr)
 	if (cksum == 0)
 		cksum = 0xffff;
 
-	return cksum;
+	return (uint16_t)cksum;
 }
 
 #ifdef __cplusplus
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:13.516582795 -0800
+++ 0027-net-explicit-cast-of-IP-checksum-to-16-bit.patch	2019-01-02 23:59:12.086815000 -0800
@@ -1,8 +1,10 @@
-From 466de6d5d8648f6a2c6cfc90c2d1bf217dd06e90 Mon Sep 17 00:00:00 2001
+From bdc221571cebe6eda8d9d08f933ad85ae08ab1c2 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Thu, 17 May 2018 21:49:57 +0800
 Subject: [PATCH] net: explicit cast of IP checksum to 16-bit
 
+[ upstream commit 466de6d5d8648f6a2c6cfc90c2d1bf217dd06e90 ]
+
 GCC 8.1 warned:
 
 In function 'rte_raw_cksum_mbuf':
@@ -32,7 +34,6 @@
 
 Fixes: 6006818cfb26 ("net: new checksum functions")
 Fixes: 4199fdea60c3 ("mbuf: generic support for TCP segmentation offload")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 ---
@@ -40,10 +41,10 @@
  1 file changed, 4 insertions(+), 4 deletions(-)
 
 diff --git a/lib/librte_net/rte_ip.h b/lib/librte_net/rte_ip.h
-index f32684c66..edbe4335c 100644
+index 23468cb99..332ac1414 100644
 --- a/lib/librte_net/rte_ip.h
 +++ b/lib/librte_net/rte_ip.h
-@@ -222,7 +222,7 @@ rte_raw_cksum_mbuf(const struct rte_mbuf *m, uint32_t off, uint32_t len,
+@@ -284,7 +284,7 @@ rte_raw_cksum_mbuf(const struct rte_mbuf *m, uint32_t off, uint32_t len,
  	for (;;) {
  		tmp = __rte_raw_cksum(buf, seglen, 0);
  		if (done & 1)
@@ -52,7 +53,7 @@
  		sum += tmp;
  		done += seglen;
  		if (done == len)
-@@ -253,7 +253,7 @@ rte_ipv4_cksum(const struct ipv4_hdr *ipv4_hdr)
+@@ -315,7 +315,7 @@ rte_ipv4_cksum(const struct ipv4_hdr *ipv4_hdr)
  {
  	uint16_t cksum;
  	cksum = rte_raw_cksum(ipv4_hdr, sizeof(struct ipv4_hdr));
@@ -61,7 +62,7 @@
  }
  
  /**
-@@ -329,7 +329,7 @@ rte_ipv4_udptcp_cksum(const struct ipv4_hdr *ipv4_hdr, const void *l4_hdr)
+@@ -391,7 +391,7 @@ rte_ipv4_udptcp_cksum(const struct ipv4_hdr *ipv4_hdr, const void *l4_hdr)
  	if (cksum == 0)
  		cksum = 0xffff;
  
@@ -70,7 +71,7 @@
  }
  
  /**
-@@ -418,7 +418,7 @@ rte_ipv6_udptcp_cksum(const struct ipv6_hdr *ipv6_hdr, const void *l4_hdr)
+@@ -480,7 +480,7 @@ rte_ipv6_udptcp_cksum(const struct ipv6_hdr *ipv6_hdr, const void *l4_hdr)
  	if (cksum == 0)
  		cksum = 0xffff;
  

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

* [dpdk-stable] patch 'net: explicit cast of protocol in IPv6 checksum' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (25 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'net: explicit cast of IP checksum to 16-bit' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'ethdev: explicit cast of queue count return' " Yongseok Koh
                   ` (8 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From cbeceb589abe4faeff3484776e008d466b4edebf Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Thu, 17 May 2018 21:50:17 +0800
Subject: [PATCH] net: explicit cast of protocol in IPv6 checksum

[ upstream commit 8bf255bb3862d8f35496b26bc8c2511239bdc18b ]

GCC 8.1 warned:

In function 'rte_ipv6_phdr_cksum':
rte_ip.h:378:18: warning: conversion to 'uint32_t' {aka 'unsigned int'}
from 'int' may change the sign of the result [-Wsign-conversion]
  psd_hdr.proto = (ipv6_hdr->proto << 24);

Fixes: 6006818cfb26 ("net: new checksum functions")

Signed-off-by: Andy Green <andy@warmcat.com>
---
 lib/librte_net/rte_ip.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/librte_net/rte_ip.h b/lib/librte_net/rte_ip.h
index 332ac1414..6a7426049 100644
--- a/lib/librte_net/rte_ip.h
+++ b/lib/librte_net/rte_ip.h
@@ -437,7 +437,7 @@ rte_ipv6_phdr_cksum(const struct ipv6_hdr *ipv6_hdr, uint64_t ol_flags)
 		uint32_t proto; /* L4 protocol - top 3 bytes must be zero */
 	} psd_hdr;
 
-	psd_hdr.proto = (ipv6_hdr->proto << 24);
+	psd_hdr.proto = (uint32_t)(ipv6_hdr->proto << 24);
 	if (ol_flags & PKT_TX_TCP_SEG) {
 		psd_hdr.len = 0;
 	} else {
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:13.569473284 -0800
+++ 0028-net-explicit-cast-of-protocol-in-IPv6-checksum.patch	2019-01-02 23:59:12.088816000 -0800
@@ -1,8 +1,10 @@
-From 8bf255bb3862d8f35496b26bc8c2511239bdc18b Mon Sep 17 00:00:00 2001
+From cbeceb589abe4faeff3484776e008d466b4edebf Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Thu, 17 May 2018 21:50:17 +0800
 Subject: [PATCH] net: explicit cast of protocol in IPv6 checksum
 
+[ upstream commit 8bf255bb3862d8f35496b26bc8c2511239bdc18b ]
+
 GCC 8.1 warned:
 
 In function 'rte_ipv6_phdr_cksum':
@@ -11,7 +13,6 @@
   psd_hdr.proto = (ipv6_hdr->proto << 24);
 
 Fixes: 6006818cfb26 ("net: new checksum functions")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 ---
@@ -19,10 +20,10 @@
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/lib/librte_net/rte_ip.h b/lib/librte_net/rte_ip.h
-index edbe4335c..c924aca7f 100644
+index 332ac1414..6a7426049 100644
 --- a/lib/librte_net/rte_ip.h
 +++ b/lib/librte_net/rte_ip.h
-@@ -375,7 +375,7 @@ rte_ipv6_phdr_cksum(const struct ipv6_hdr *ipv6_hdr, uint64_t ol_flags)
+@@ -437,7 +437,7 @@ rte_ipv6_phdr_cksum(const struct ipv6_hdr *ipv6_hdr, uint64_t ol_flags)
  		uint32_t proto; /* L4 protocol - top 3 bytes must be zero */
  	} psd_hdr;
  

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

* [dpdk-stable] patch 'ethdev: explicit cast of queue count return' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (26 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'net: explicit cast of protocol in IPv6 checksum' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'eal/x86: fix type of variable in memcpy function' " Yongseok Koh
                   ` (7 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From 2cde5ec07db9287bb077ad2dfc2cc9820056fae2 Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Fri, 18 May 2018 21:02:38 +0800
Subject: [PATCH] ethdev: explicit cast of queue count return

[ upstream commit 45d1be93b9020dfe9c1f3e81822621580312dcc3 ]

GCC 8.1 produces a warning:
rte_ethdev.h: In function 'rte_eth_rx_queue_count':
rte_ethdev.h:3882:10: warning: conversion to 'int' from 'uint32_t'
{aka 'unsigned int'} may change the sign of the result [-Wsign-conversion]
  return (*dev->dev_ops->rx_queue_count)(dev, queue_id);
         ~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Fixes: 33cf6be04d60 ("ethdev: add sanity checks to functions")

Signed-off-by: Andy Green <andy@warmcat.com>
---
 lib/librte_ether/rte_ethdev.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/librte_ether/rte_ethdev.h b/lib/librte_ether/rte_ethdev.h
index bbca590d4..65cb04755 100644
--- a/lib/librte_ether/rte_ethdev.h
+++ b/lib/librte_ether/rte_ethdev.h
@@ -2935,7 +2935,7 @@ rte_eth_rx_queue_count(uint16_t port_id, uint16_t queue_id)
 	if (queue_id >= dev->data->nb_rx_queues)
 		return -EINVAL;
 
-	return (*dev->dev_ops->rx_queue_count)(dev, queue_id);
+	return (int)(*dev->dev_ops->rx_queue_count)(dev, queue_id);
 }
 
 /**
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:13.620667292 -0800
+++ 0029-ethdev-explicit-cast-of-queue-count-return.patch	2019-01-02 23:59:12.091815000 -0800
@@ -1,8 +1,10 @@
-From 45d1be93b9020dfe9c1f3e81822621580312dcc3 Mon Sep 17 00:00:00 2001
+From 2cde5ec07db9287bb077ad2dfc2cc9820056fae2 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Fri, 18 May 2018 21:02:38 +0800
 Subject: [PATCH] ethdev: explicit cast of queue count return
 
+[ upstream commit 45d1be93b9020dfe9c1f3e81822621580312dcc3 ]
+
 GCC 8.1 produces a warning:
 rte_ethdev.h: In function 'rte_eth_rx_queue_count':
 rte_ethdev.h:3882:10: warning: conversion to 'int' from 'uint32_t'
@@ -11,18 +13,17 @@
          ~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
 Fixes: 33cf6be04d60 ("ethdev: add sanity checks to functions")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 ---
- lib/librte_ethdev/rte_ethdev.h | 2 +-
+ lib/librte_ether/rte_ethdev.h | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
-diff --git a/lib/librte_ethdev/rte_ethdev.h b/lib/librte_ethdev/rte_ethdev.h
-index f8815e994..d52c1bed9 100644
---- a/lib/librte_ethdev/rte_ethdev.h
-+++ b/lib/librte_ethdev/rte_ethdev.h
-@@ -3874,7 +3874,7 @@ rte_eth_rx_queue_count(uint16_t port_id, uint16_t queue_id)
+diff --git a/lib/librte_ether/rte_ethdev.h b/lib/librte_ether/rte_ethdev.h
+index bbca590d4..65cb04755 100644
+--- a/lib/librte_ether/rte_ethdev.h
++++ b/lib/librte_ether/rte_ethdev.h
+@@ -2935,7 +2935,7 @@ rte_eth_rx_queue_count(uint16_t port_id, uint16_t queue_id)
  	if (queue_id >= dev->data->nb_rx_queues)
  		return -EINVAL;
  

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

* [dpdk-stable] patch 'eal/x86: fix type of variable in memcpy function' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (27 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'ethdev: explicit cast of queue count return' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'eal: explicit cast in rwlock functions' " Yongseok Koh
                   ` (6 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Bruce Richardson, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From 68a61e636d3fad1eaa5407d8ce34af0cf0586d5c Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Tue, 22 May 2018 09:24:12 +0800
Subject: [PATCH] eal/x86: fix type of variable in memcpy function

[ upstream commit 14035e5fadff19efb17069c6dc463670a8e8b6c1 ]

GCC 8.1 warned:

rte_memcpy.h:793:2: note: in expansion of macro 'MOVEUNALIGNED_LEFT47'
  MOVEUNALIGNED_LEFT47(dst, src, n, srcofs);
  ^~~~~~~~~~~~~~~~~~~~
rte_memcpy.h:649:51: warning: conversion from 'size_t'
{aka 'long unsigned int'} to 'int' may change value [-Wconversion]
     case 0x0B: MOVEUNALIGNED_LEFT47_IMM(dst, src, n, 0x0B); break;
                                                   ^

rte_memcpy.h:616:15: note: in definition of macro 'MOVEUNALIGNED_LEFT47_IMM'
         tmp = len;
               ^~~
rte_memcpy.h:793:2: note: in expansion of macro 'MOVEUNALIGNED_LEFT47'
  MOVEUNALIGNED_LEFT47(dst, src, n, srcofs);
  ^~~~~~~~~~~~~~~~~~~~
rte_memcpy.h:618:13: warning: conversion to 'size_t'
{aka 'long unsigned int'} from 'int'
may change the sign of the result [-Wsign-conversion]
         tmp -= len;
             ^~

rte_memcpy.h:649:16: note: in expansion of macro 'MOVEUNALIGNED_LEFT47_IMM'
     case 0x0B: MOVEUNALIGNED_LEFT47_IMM(dst, src, n, 0x0B); break;
                ^~~~~~~~~~~~~~~~~~~~~~~~
rte_memcpy.h:793:2: note: in expansion of macro 'MOVEUNALIGNED_LEFT47'
  MOVEUNALIGNED_LEFT47(dst, src, n, srcofs);
  ^~~~~~~~~~~~~~~~~~~~
rte_memcpy.h:618:13: warning: conversion to 'size_t'
{aka 'long unsigned int'} from 'int'
may change the sign of the result [-Wsign-conversion]
             tmp -= len;
                 ^~

We can eliminate the problems by setting the type of tmp to
size_t in the first place.

Fixes: d35cc1fe6a ("eal/x86: revert select optimized memcpy at run-time")

Suggested-by: Bruce Richardson <bruce.richardson@intel.com>
Signed-off-by: Andy Green <andy@warmcat.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
 lib/librte_eal/common/include/arch/x86/rte_memcpy.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/librte_eal/common/include/arch/x86/rte_memcpy.h b/lib/librte_eal/common/include/arch/x86/rte_memcpy.h
index 596d77791..3f4a9db83 100644
--- a/lib/librte_eal/common/include/arch/x86/rte_memcpy.h
+++ b/lib/librte_eal/common/include/arch/x86/rte_memcpy.h
@@ -603,7 +603,7 @@ rte_mov256(uint8_t *dst, const uint8_t *src)
  */
 #define MOVEUNALIGNED_LEFT47_IMM(dst, src, len, offset)                                                     \
 __extension__ ({                                                                                            \
-    int tmp;                                                                                                \
+    size_t tmp;                                                                                                \
     while (len >= 128 + 16 - offset) {                                                                      \
         xmm0 = _mm_loadu_si128((const __m128i *)((const uint8_t *)src - offset + 0 * 16));                  \
         len -= 128;                                                                                         \
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:13.674492972 -0800
+++ 0030-eal-x86-fix-type-of-variable-in-memcpy-function.patch	2019-01-02 23:59:12.094816000 -0800
@@ -1,8 +1,10 @@
-From 14035e5fadff19efb17069c6dc463670a8e8b6c1 Mon Sep 17 00:00:00 2001
+From 68a61e636d3fad1eaa5407d8ce34af0cf0586d5c Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Tue, 22 May 2018 09:24:12 +0800
 Subject: [PATCH] eal/x86: fix type of variable in memcpy function
 
+[ upstream commit 14035e5fadff19efb17069c6dc463670a8e8b6c1 ]
+
 GCC 8.1 warned:
 
 rte_memcpy.h:793:2: note: in expansion of macro 'MOVEUNALIGNED_LEFT47'
@@ -41,7 +43,6 @@
 size_t in the first place.
 
 Fixes: d35cc1fe6a ("eal/x86: revert select optimized memcpy at run-time")
-Cc: stable@dpdk.org
 
 Suggested-by: Bruce Richardson <bruce.richardson@intel.com>
 Signed-off-by: Andy Green <andy@warmcat.com>
@@ -51,10 +52,10 @@
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/lib/librte_eal/common/include/arch/x86/rte_memcpy.h b/lib/librte_eal/common/include/arch/x86/rte_memcpy.h
-index 5ead68ab2..7b758094d 100644
+index 596d77791..3f4a9db83 100644
 --- a/lib/librte_eal/common/include/arch/x86/rte_memcpy.h
 +++ b/lib/librte_eal/common/include/arch/x86/rte_memcpy.h
-@@ -574,7 +574,7 @@ rte_mov256(uint8_t *dst, const uint8_t *src)
+@@ -603,7 +603,7 @@ rte_mov256(uint8_t *dst, const uint8_t *src)
   */
  #define MOVEUNALIGNED_LEFT47_IMM(dst, src, len, offset)                                                     \
  __extension__ ({                                                                                            \

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

* [dpdk-stable] patch 'eal: explicit cast in rwlock functions' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (28 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'eal/x86: fix type of variable in memcpy function' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'net: explicit cast in L4 checksum' " Yongseok Koh
                   ` (5 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Bruce Richardson, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From 66ca6b9a6b272cc7d2048f016eb544fa4fb1c8c3 Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Tue, 22 May 2018 09:24:17 +0800
Subject: [PATCH] eal: explicit cast in rwlock functions

[ upstream commit 1587d36e22d0cf0e037a104e1e851acefd6597f0 ]

GCC 8.1 warned:

In function 'rte_rwlock_read_lock':
rte_rwlock.h:74:12: warning: conversion to 'uint32_t'
{aka 'unsigned int'} from 'int32_t' {aka 'int'} may
change the sign of the result [-Wsign-conversion]
            x, x + 1);
            ^
rte_rwlock.h:74:17: warning: conversion to 'uint32_t'
{aka 'unsigned int'} from 'int' may change the sign
of the result [-Wsign-conversion]
            x, x + 1);
               ~~^~~

In function 'rte_rwlock_write_lock':
rte_rwlock.h:110:15: warning: unsigned conversion
from 'int' to 'uint32_t' {aka 'unsigned int'}
changes value from '-1' to '4294967295' [-Wsign-conversion]
            0, -1);
               ^~

Again in this case we are making explicit the exact cast
that was always happening implicitly.  The patch does not
change the generated code.

The int32_t temp "x" is required to be signed to detect
a < 0 error condition from the lock status.  Afterwards,
it has always been implicitly cast to uint32_t when it
is used in the arguments to rte_atomic32_cmpset()...
gcc8.1 objects to the implicit cast now and requires us
to cast it explicitly.

Fixes: af75078fec ("first public release")

Signed-off-by: Andy Green <andy@warmcat.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
 lib/librte_eal/common/include/generic/rte_rwlock.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lib/librte_eal/common/include/generic/rte_rwlock.h b/lib/librte_eal/common/include/generic/rte_rwlock.h
index fdb3113d3..f4ee1aa9b 100644
--- a/lib/librte_eal/common/include/generic/rte_rwlock.h
+++ b/lib/librte_eal/common/include/generic/rte_rwlock.h
@@ -100,7 +100,7 @@ rte_rwlock_read_lock(rte_rwlock_t *rwl)
 			continue;
 		}
 		success = rte_atomic32_cmpset((volatile uint32_t *)&rwl->cnt,
-					      x, x + 1);
+					      (uint32_t)x, (uint32_t)(x + 1));
 	}
 }
 
@@ -136,7 +136,7 @@ rte_rwlock_write_lock(rte_rwlock_t *rwl)
 			continue;
 		}
 		success = rte_atomic32_cmpset((volatile uint32_t *)&rwl->cnt,
-					      0, -1);
+					      0, (uint32_t)-1);
 	}
 }
 
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:13.722428285 -0800
+++ 0031-eal-explicit-cast-in-rwlock-functions.patch	2019-01-02 23:59:12.096815000 -0800
@@ -1,8 +1,10 @@
-From 1587d36e22d0cf0e037a104e1e851acefd6597f0 Mon Sep 17 00:00:00 2001
+From 66ca6b9a6b272cc7d2048f016eb544fa4fb1c8c3 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Tue, 22 May 2018 09:24:17 +0800
 Subject: [PATCH] eal: explicit cast in rwlock functions
 
+[ upstream commit 1587d36e22d0cf0e037a104e1e851acefd6597f0 ]
+
 GCC 8.1 warned:
 
 In function 'rte_rwlock_read_lock':
@@ -36,7 +38,6 @@
 to cast it explicitly.
 
 Fixes: af75078fec ("first public release")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Acked-by: Bruce Richardson <bruce.richardson@intel.com>
@@ -45,10 +46,10 @@
  1 file changed, 2 insertions(+), 2 deletions(-)
 
 diff --git a/lib/librte_eal/common/include/generic/rte_rwlock.h b/lib/librte_eal/common/include/generic/rte_rwlock.h
-index 899e9bc43..5751a0e6d 100644
+index fdb3113d3..f4ee1aa9b 100644
 --- a/lib/librte_eal/common/include/generic/rte_rwlock.h
 +++ b/lib/librte_eal/common/include/generic/rte_rwlock.h
-@@ -71,7 +71,7 @@ rte_rwlock_read_lock(rte_rwlock_t *rwl)
+@@ -100,7 +100,7 @@ rte_rwlock_read_lock(rte_rwlock_t *rwl)
  			continue;
  		}
  		success = rte_atomic32_cmpset((volatile uint32_t *)&rwl->cnt,
@@ -57,7 +58,7 @@
  	}
  }
  
-@@ -107,7 +107,7 @@ rte_rwlock_write_lock(rte_rwlock_t *rwl)
+@@ -136,7 +136,7 @@ rte_rwlock_write_lock(rte_rwlock_t *rwl)
  			continue;
  		}
  		success = rte_atomic32_cmpset((volatile uint32_t *)&rwl->cnt,

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

* [dpdk-stable] patch 'net: explicit cast in L4 checksum' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (29 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'eal: explicit cast in rwlock functions' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'mbuf: fix type of private size in detach' " Yongseok Koh
                   ` (4 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Bruce Richardson, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From 088f43cdcf2114776815930e8ecad2b047d986dc Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Tue, 22 May 2018 09:24:22 +0800
Subject: [PATCH] net: explicit cast in L4 checksum

[ upstream commit f37a2e7c747b0758fcd8390482aeeac490f688b5 ]

GCC 8.1 warned:

In function 'rte_ipv4_udptcp_cksum':
rte_byteorder.h:51:24: warning: conversion from 'long unsigned int' to
'uint32_t' {aka 'unsigned int'} may change value [-Wconversion]
 #define rte_bswap16(x) ((uint16_t) (__builtin_constant_p(x) ?  \
                        ^
rte_byteorder.h:85:29: note: in expansion of macro 'rte_bswap16'
 #define rte_be_to_cpu_16(x) rte_bswap16(x)
                             ^~~~~~~~~~~
rte_ip.h:321:11: note: in expansion of macro 'rte_be_to_cpu_16'
  l4_len = rte_be_to_cpu_16(ipv4_hdr->total_length) -
           ^~~~~~~~~~~~~~~~

Also with this one, it is a cast that always occurred
and is just being done explicitly, with no changes to
the generated code.

The warning stack is misleading, it points to the last
element in the macro that produced the lhs of the subtraction
above.  But the only "unsigned long int" in the expression is
the result of the sizeof() on the rhs, it promotes the
subtraction result to unsigned long.  So the error actually
relates to the result of the outer subtraction.

The actual error is "you are trying to put an unsigned long
into a uint32_t".  We always did so, the fix is just to inform
the compiler it is intentional with an explicit cast.

Fixes: 6006818cfb ("net: new checksum functions")

Signed-off-by: Andy Green <andy@warmcat.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
 lib/librte_net/rte_ip.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lib/librte_net/rte_ip.h b/lib/librte_net/rte_ip.h
index 6a7426049..b22c1f800 100644
--- a/lib/librte_net/rte_ip.h
+++ b/lib/librte_net/rte_ip.h
@@ -380,8 +380,8 @@ rte_ipv4_udptcp_cksum(const struct ipv4_hdr *ipv4_hdr, const void *l4_hdr)
 	uint32_t cksum;
 	uint32_t l4_len;
 
-	l4_len = rte_be_to_cpu_16(ipv4_hdr->total_length) -
-		sizeof(struct ipv4_hdr);
+	l4_len = (uint32_t)(rte_be_to_cpu_16(ipv4_hdr->total_length) -
+		sizeof(struct ipv4_hdr));
 
 	cksum = rte_raw_cksum(l4_hdr, l4_len);
 	cksum += rte_ipv4_phdr_cksum(ipv4_hdr, 0);
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:13.771837365 -0800
+++ 0032-net-explicit-cast-in-L4-checksum.patch	2019-01-02 23:59:12.097819000 -0800
@@ -1,8 +1,10 @@
-From f37a2e7c747b0758fcd8390482aeeac490f688b5 Mon Sep 17 00:00:00 2001
+From 088f43cdcf2114776815930e8ecad2b047d986dc Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Tue, 22 May 2018 09:24:22 +0800
 Subject: [PATCH] net: explicit cast in L4 checksum
 
+[ upstream commit f37a2e7c747b0758fcd8390482aeeac490f688b5 ]
+
 GCC 8.1 warned:
 
 In function 'rte_ipv4_udptcp_cksum':
@@ -33,7 +35,6 @@
 the compiler it is intentional with an explicit cast.
 
 Fixes: 6006818cfb ("net: new checksum functions")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Acked-by: Bruce Richardson <bruce.richardson@intel.com>
@@ -42,10 +43,10 @@
  1 file changed, 2 insertions(+), 2 deletions(-)
 
 diff --git a/lib/librte_net/rte_ip.h b/lib/librte_net/rte_ip.h
-index c924aca7f..72dc2456a 100644
+index 6a7426049..b22c1f800 100644
 --- a/lib/librte_net/rte_ip.h
 +++ b/lib/librte_net/rte_ip.h
-@@ -318,8 +318,8 @@ rte_ipv4_udptcp_cksum(const struct ipv4_hdr *ipv4_hdr, const void *l4_hdr)
+@@ -380,8 +380,8 @@ rte_ipv4_udptcp_cksum(const struct ipv4_hdr *ipv4_hdr, const void *l4_hdr)
  	uint32_t cksum;
  	uint32_t l4_len;
  

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

* [dpdk-stable] patch 'mbuf: fix type of private size in detach' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (30 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'net: explicit cast in L4 checksum' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'mbuf: fix type of variables in linearize function' " Yongseok Koh
                   ` (3 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Bruce Richardson, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From d8f4cfc14f2f7b1b0159d1aaa1b5ee46c8a51045 Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Tue, 22 May 2018 09:24:27 +0800
Subject: [PATCH] mbuf: fix type of private size in detach

[ upstream commit ad3781066261848c163e700c3c5baa16fecc2247 ]

GCC 8.1 warned:

In function 'rte_pktmbuf_detach':
rte_mbuf.h:1583:17: warning: conversion from 'uint32_t'
{aka 'unsigned int'} to 'uint16_t' {aka 'short unsigned int'}
may change value [-Wconversion]
  m->priv_size = priv_size;
                 ^~~~~~~~~

The temp priv_size is declared as a uint32_t.  But it
only deals in uint16_t.  m->priv_size is a uint16_t.
Change it to a uint16_t.

Fixes: 355e6735b3 ("mbuf: fix cloning with private mbuf data")

Signed-off-by: Andy Green <andy@warmcat.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
 lib/librte_mbuf/rte_mbuf.h | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h
index 07687c39b..9dab1d1a8 100644
--- a/lib/librte_mbuf/rte_mbuf.h
+++ b/lib/librte_mbuf/rte_mbuf.h
@@ -1325,7 +1325,8 @@ static inline void rte_pktmbuf_detach(struct rte_mbuf *m)
 {
 	struct rte_mbuf *md = rte_mbuf_from_indirect(m);
 	struct rte_mempool *mp = m->pool;
-	uint32_t mbuf_size, buf_len, priv_size;
+	uint32_t mbuf_size, buf_len;
+	uint16_t priv_size;
 
 	priv_size = rte_pktmbuf_priv_size(mp);
 	mbuf_size = (uint32_t)(sizeof(struct rte_mbuf) + priv_size);
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:13.821551653 -0800
+++ 0033-mbuf-fix-type-of-private-size-in-detach.patch	2019-01-02 23:59:12.099818000 -0800
@@ -1,8 +1,10 @@
-From ad3781066261848c163e700c3c5baa16fecc2247 Mon Sep 17 00:00:00 2001
+From d8f4cfc14f2f7b1b0159d1aaa1b5ee46c8a51045 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Tue, 22 May 2018 09:24:27 +0800
 Subject: [PATCH] mbuf: fix type of private size in detach
 
+[ upstream commit ad3781066261848c163e700c3c5baa16fecc2247 ]
+
 GCC 8.1 warned:
 
 In function 'rte_pktmbuf_detach':
@@ -17,7 +19,6 @@
 Change it to a uint16_t.
 
 Fixes: 355e6735b3 ("mbuf: fix cloning with private mbuf data")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Acked-by: Bruce Richardson <bruce.richardson@intel.com>
@@ -26,19 +27,19 @@
  1 file changed, 2 insertions(+), 1 deletion(-)
 
 diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h
-index 28fd4ad52..76e37a2f8 100644
+index 07687c39b..9dab1d1a8 100644
 --- a/lib/librte_mbuf/rte_mbuf.h
 +++ b/lib/librte_mbuf/rte_mbuf.h
-@@ -1571,7 +1571,8 @@ __rte_pktmbuf_free_direct(struct rte_mbuf *m)
- static inline void rte_pktmbuf_detach(struct rte_mbuf *m)
+@@ -1325,7 +1325,8 @@ static inline void rte_pktmbuf_detach(struct rte_mbuf *m)
  {
+ 	struct rte_mbuf *md = rte_mbuf_from_indirect(m);
  	struct rte_mempool *mp = m->pool;
 -	uint32_t mbuf_size, buf_len, priv_size;
 +	uint32_t mbuf_size, buf_len;
 +	uint16_t priv_size;
  
- 	if (RTE_MBUF_HAS_EXTBUF(m))
- 		__rte_pktmbuf_free_extbuf(m);
+ 	priv_size = rte_pktmbuf_priv_size(mp);
+ 	mbuf_size = (uint32_t)(sizeof(struct rte_mbuf) + priv_size);
 -- 
 2.11.0
 

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

* [dpdk-stable] patch 'mbuf: fix type of variables in linearize function' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (31 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'mbuf: fix type of private size in detach' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'mbuf: avoid implicit demotion in 64-bit arithmetic' " Yongseok Koh
                   ` (2 subsequent siblings)
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Bruce Richardson, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From 783f21125c8e89d7f7bea896686662398beb8a63 Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Tue, 22 May 2018 09:24:37 +0800
Subject: [PATCH] mbuf: fix type of variables in linearize function

[ upstream commit 50f239c9087df9b1a3c14e77f4279c7d5f523138 ]

GCC 8.1 warned:

In function 'rte_pktmbuf_linearize':
rte_mbuf.h:1873:32: warning: conversion to 'int' from 'uint32_t'
{aka 'unsigned int'} may change the sign of the result [-Wsign-conversion]
rte_mbuf.h:2166:13: note: in expansion of macro 'rte_pktmbuf_pkt_len'
   copy_len = rte_pktmbuf_pkt_len(mbuf) - rte_pktmbuf_data_len(mbuf);
rte_mbuf.h:2180:51: warning: conversion to 'size_t'
{aka 'long unsigned int'} from 'int' may change the
sign of the result [-Wsign-conversion]
rte_memcpy(buffer, rte_pktmbuf_mtod(m, char *), seg_len);
                                                ^~~~~~~

The temp is consumed as a size_t.  So let's make it
a size_t in the first place.

Fixes: 1feda4d8fc ("mbuf: add a function to linearize a packet")

Signed-off-by: Andy Green <andy@warmcat.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
 lib/librte_mbuf/rte_mbuf.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h
index 9dab1d1a8..ee94ec6b2 100644
--- a/lib/librte_mbuf/rte_mbuf.h
+++ b/lib/librte_mbuf/rte_mbuf.h
@@ -1915,7 +1915,7 @@ rte_validate_tx_offload(const struct rte_mbuf *m)
 static inline int
 rte_pktmbuf_linearize(struct rte_mbuf *mbuf)
 {
-	int seg_len, copy_len;
+	size_t seg_len, copy_len;
 	struct rte_mbuf *m;
 	struct rte_mbuf *m_next;
 	char *buffer;
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:13.872665213 -0800
+++ 0034-mbuf-fix-type-of-variables-in-linearize-function.patch	2019-01-02 23:59:12.101817000 -0800
@@ -1,8 +1,10 @@
-From 50f239c9087df9b1a3c14e77f4279c7d5f523138 Mon Sep 17 00:00:00 2001
+From 783f21125c8e89d7f7bea896686662398beb8a63 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Tue, 22 May 2018 09:24:37 +0800
 Subject: [PATCH] mbuf: fix type of variables in linearize function
 
+[ upstream commit 50f239c9087df9b1a3c14e77f4279c7d5f523138 ]
+
 GCC 8.1 warned:
 
 In function 'rte_pktmbuf_linearize':
@@ -20,7 +22,6 @@
 a size_t in the first place.
 
 Fixes: 1feda4d8fc ("mbuf: add a function to linearize a packet")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Acked-by: Bruce Richardson <bruce.richardson@intel.com>
@@ -29,10 +30,10 @@
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h
-index 76e37a2f8..715f90ea0 100644
+index 9dab1d1a8..ee94ec6b2 100644
 --- a/lib/librte_mbuf/rte_mbuf.h
 +++ b/lib/librte_mbuf/rte_mbuf.h
-@@ -2157,7 +2157,7 @@ rte_validate_tx_offload(const struct rte_mbuf *m)
+@@ -1915,7 +1915,7 @@ rte_validate_tx_offload(const struct rte_mbuf *m)
  static inline int
  rte_pktmbuf_linearize(struct rte_mbuf *mbuf)
  {

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

* [dpdk-stable] patch 'mbuf: avoid implicit demotion in 64-bit arithmetic' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (32 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'mbuf: fix type of variables in linearize function' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:13 ` [dpdk-stable] patch 'mbuf: avoid integer promotion in prepend/adj/chain' " Yongseok Koh
  2019-01-03  8:14 ` [dpdk-stable] patch 'ethdev: fix type and scope of variables in Rx burst' " Yongseok Koh
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Bruce Richardson, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From cf80647272d6586f2032059361162f0ad2f9f14f Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Tue, 22 May 2018 09:24:32 +0800
Subject: [PATCH] mbuf: avoid implicit demotion in 64-bit arithmetic

[ upstream commit ef5092e16b137fd5e23d19b4b17b32f330d4a4ad ]

GCC 8.1 warned:

In function 'rte_validate_tx_offload':
rte_mbuf.h:2112:19: warning: conversion to 'uint64_t'
{aka 'long unsigned int'} from 'int' may change the
sign of the result [-Wsign-conversion]
  inner_l3_offset += m->outer_l2_len + m->outer_l3_len;
                   ^~

  uint64_t inner_l3_offset...

  /* fields for TX offloading of tunnels */
  uint64_t outer_l3_len:9; /**< Outer L3 (IP) Hdr Length. */
  uint64_t outer_l2_len:7; /**< Outer L2 (MAC) Hdr Length. */

We want to do the arithmetic entirely in uint64_t
space, but with the +=, the rhs type becomes int since the
bitfields will fit in int.

Elaborate the artithmetic to be u64 = u64 + int + int, so
the type of the result is correct to be stored in the u64.

Fixes: 4fb7e803eb ("ethdev: add Tx preparation")

Signed-off-by: Andy Green <andy@warmcat.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
 lib/librte_mbuf/rte_mbuf.h | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h
index ee94ec6b2..8c63a9fdb 100644
--- a/lib/librte_mbuf/rte_mbuf.h
+++ b/lib/librte_mbuf/rte_mbuf.h
@@ -1870,7 +1870,11 @@ rte_validate_tx_offload(const struct rte_mbuf *m)
 		return 0;
 
 	if (ol_flags & PKT_TX_OUTER_IP_CKSUM)
-		inner_l3_offset += m->outer_l2_len + m->outer_l3_len;
+		/* NB: elaborating the addition like this instead of using
+		 *     += gives the result uint64_t type instead of int,
+		 *     avoiding compiler warnings on gcc 8.1 at least */
+		inner_l3_offset = inner_l3_offset + m->outer_l2_len +
+				  m->outer_l3_len;
 
 	/* Headers are fragmented */
 	if (rte_pktmbuf_data_len(m) < inner_l3_offset + m->l3_len + m->l4_len)
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:13.923877201 -0800
+++ 0035-mbuf-avoid-implicit-demotion-in-64-bit-arithmetic.patch	2019-01-02 23:59:12.103815000 -0800
@@ -1,8 +1,10 @@
-From ef5092e16b137fd5e23d19b4b17b32f330d4a4ad Mon Sep 17 00:00:00 2001
+From cf80647272d6586f2032059361162f0ad2f9f14f Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Tue, 22 May 2018 09:24:32 +0800
 Subject: [PATCH] mbuf: avoid implicit demotion in 64-bit arithmetic
 
+[ upstream commit ef5092e16b137fd5e23d19b4b17b32f330d4a4ad ]
+
 GCC 8.1 warned:
 
 In function 'rte_validate_tx_offload':
@@ -26,7 +28,6 @@
 the type of the result is correct to be stored in the u64.
 
 Fixes: 4fb7e803eb ("ethdev: add Tx preparation")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Acked-by: Bruce Richardson <bruce.richardson@intel.com>
@@ -35,10 +36,10 @@
  1 file changed, 5 insertions(+), 1 deletion(-)
 
 diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h
-index 715f90ea0..0e89a6927 100644
+index ee94ec6b2..8c63a9fdb 100644
 --- a/lib/librte_mbuf/rte_mbuf.h
 +++ b/lib/librte_mbuf/rte_mbuf.h
-@@ -2112,7 +2112,11 @@ rte_validate_tx_offload(const struct rte_mbuf *m)
+@@ -1870,7 +1870,11 @@ rte_validate_tx_offload(const struct rte_mbuf *m)
  		return 0;
  
  	if (ol_flags & PKT_TX_OUTER_IP_CKSUM)

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

* [dpdk-stable] patch 'mbuf: avoid integer promotion in prepend/adj/chain' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (33 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'mbuf: avoid implicit demotion in 64-bit arithmetic' " Yongseok Koh
@ 2019-01-03  8:13 ` Yongseok Koh
  2019-01-03  8:14 ` [dpdk-stable] patch 'ethdev: fix type and scope of variables in Rx burst' " Yongseok Koh
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:13 UTC (permalink / raw)
  To: Andy Green; +Cc: Bruce Richardson, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From 91f14efa3ea358957b7292d406fe1cf3627b4c78 Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Tue, 22 May 2018 09:24:42 +0800
Subject: [PATCH] mbuf: avoid integer promotion in prepend/adj/chain

[ upstream commit 9d0b59f84e1170b12a128cdcccab5711f25b5dd8 ]

GCC 8.1 warned:

In function 'rte_pktmbuf_prepend':
rte_mbuf.h:1908:17: warning: conversion from 'int' to 'uint16_t'
{aka 'short unsigned int'} may change value [-Wconversion]
  m->data_off -= len;
                 ^~~
m->data_off is a uint16_t

        uint16_t data_off;

len (a uint16_t) is promoted to an int using -=.  Do the
subtraction explicitly and cast the result to uint16_t.

The below += or -= changes are solving the same thing.

In function 'rte_pktmbuf_adj':
rte_mbuf.h:1969:17: warning: conversion from 'int' to 'uint16_t'
{aka 'short unsigned int'} may change value [-Wconversion]
  m->data_off += len;
                 ^~~

In function 'rte_pktmbuf_chain':
rte_mbuf.h:2082:19: warning: conversion from 'int' to 'uint16_t'
{aka 'short unsigned int'} may change value [-Wconversion]
  head->nb_segs += tail->nb_segs;
                   ^~~~
Also uint16_t

        uint16_t nb_segs;         /**< Number of segments. */

Fixes: 08b563ffb19d ("mbuf: replace data pointer by an offset")
Fixes: 1a60a0daa6e4 ("mbuf: fix segments number type increase")

Signed-off-by: Andy Green <andy@warmcat.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
 lib/librte_mbuf/rte_mbuf.h | 17 +++++++++++++----
 1 file changed, 13 insertions(+), 4 deletions(-)

diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h
index 8c63a9fdb..e6fd86f29 100644
--- a/lib/librte_mbuf/rte_mbuf.h
+++ b/lib/librte_mbuf/rte_mbuf.h
@@ -1666,7 +1666,10 @@ static inline char *rte_pktmbuf_prepend(struct rte_mbuf *m,
 	if (unlikely(len > rte_pktmbuf_headroom(m)))
 		return NULL;
 
-	m->data_off -= len;
+	/* NB: elaborating the subtraction like this instead of using
+	 *     -= allows us to ensure the result type is uint16_t
+	 *     avoiding compiler warnings on gcc 8.1 at least */
+	m->data_off = (uint16_t)(m->data_off - len);
 	m->data_len = (uint16_t)(m->data_len + len);
 	m->pkt_len  = (m->pkt_len + len);
 
@@ -1726,8 +1729,11 @@ static inline char *rte_pktmbuf_adj(struct rte_mbuf *m, uint16_t len)
 	if (unlikely(len > m->data_len))
 		return NULL;
 
+	/* NB: elaborating the addition like this instead of using
+	 *     += allows us to ensure the result type is uint16_t
+	 *     avoiding compiler warnings on gcc 8.1 at least */
 	m->data_len = (uint16_t)(m->data_len - len);
-	m->data_off += len;
+	m->data_off = (uint16_t)(m->data_off + len);
 	m->pkt_len  = (m->pkt_len - len);
 	return (char *)m->buf_addr + m->data_off;
 }
@@ -1839,8 +1845,11 @@ static inline int rte_pktmbuf_chain(struct rte_mbuf *head, struct rte_mbuf *tail
 	cur_tail = rte_pktmbuf_lastseg(head);
 	cur_tail->next = tail;
 
-	/* accumulate number of segments and total length. */
-	head->nb_segs += tail->nb_segs;
+	/* accumulate number of segments and total length.
+	 * NB: elaborating the addition like this instead of using
+	 *     -= allows us to ensure the result type is uint16_t
+	 *     avoiding compiler warnings on gcc 8.1 at least */
+	head->nb_segs = (uint16_t)(head->nb_segs + tail->nb_segs);
 	head->pkt_len += tail->pkt_len;
 
 	/* pkt_len is only set in the head */
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:13.975320321 -0800
+++ 0036-mbuf-avoid-integer-promotion-in-prepend-adj-chain.patch	2019-01-02 23:59:12.105818000 -0800
@@ -1,8 +1,10 @@
-From 9d0b59f84e1170b12a128cdcccab5711f25b5dd8 Mon Sep 17 00:00:00 2001
+From 91f14efa3ea358957b7292d406fe1cf3627b4c78 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Tue, 22 May 2018 09:24:42 +0800
 Subject: [PATCH] mbuf: avoid integer promotion in prepend/adj/chain
 
+[ upstream commit 9d0b59f84e1170b12a128cdcccab5711f25b5dd8 ]
+
 GCC 8.1 warned:
 
 In function 'rte_pktmbuf_prepend':
@@ -36,7 +38,6 @@
 
 Fixes: 08b563ffb19d ("mbuf: replace data pointer by an offset")
 Fixes: 1a60a0daa6e4 ("mbuf: fix segments number type increase")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Acked-by: Bruce Richardson <bruce.richardson@intel.com>
@@ -45,10 +46,10 @@
  1 file changed, 13 insertions(+), 4 deletions(-)
 
 diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h
-index 0e89a6927..e136d12b7 100644
+index 8c63a9fdb..e6fd86f29 100644
 --- a/lib/librte_mbuf/rte_mbuf.h
 +++ b/lib/librte_mbuf/rte_mbuf.h
-@@ -1908,7 +1908,10 @@ static inline char *rte_pktmbuf_prepend(struct rte_mbuf *m,
+@@ -1666,7 +1666,10 @@ static inline char *rte_pktmbuf_prepend(struct rte_mbuf *m,
  	if (unlikely(len > rte_pktmbuf_headroom(m)))
  		return NULL;
  
@@ -60,7 +61,7 @@
  	m->data_len = (uint16_t)(m->data_len + len);
  	m->pkt_len  = (m->pkt_len + len);
  
-@@ -1968,8 +1971,11 @@ static inline char *rte_pktmbuf_adj(struct rte_mbuf *m, uint16_t len)
+@@ -1726,8 +1729,11 @@ static inline char *rte_pktmbuf_adj(struct rte_mbuf *m, uint16_t len)
  	if (unlikely(len > m->data_len))
  		return NULL;
  
@@ -73,7 +74,7 @@
  	m->pkt_len  = (m->pkt_len - len);
  	return (char *)m->buf_addr + m->data_off;
  }
-@@ -2081,8 +2087,11 @@ static inline int rte_pktmbuf_chain(struct rte_mbuf *head, struct rte_mbuf *tail
+@@ -1839,8 +1845,11 @@ static inline int rte_pktmbuf_chain(struct rte_mbuf *head, struct rte_mbuf *tail
  	cur_tail = rte_pktmbuf_lastseg(head);
  	cur_tail->next = tail;
  

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

* [dpdk-stable] patch 'ethdev: fix type and scope of variables in Rx burst' has been queued to LTS release 17.11.5
  2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
                   ` (34 preceding siblings ...)
  2019-01-03  8:13 ` [dpdk-stable] patch 'mbuf: avoid integer promotion in prepend/adj/chain' " Yongseok Koh
@ 2019-01-03  8:14 ` Yongseok Koh
  35 siblings, 0 replies; 37+ messages in thread
From: Yongseok Koh @ 2019-01-03  8:14 UTC (permalink / raw)
  To: Andy Green; +Cc: Bruce Richardson, dpdk stable

Hi,

FYI, your patch has been queued to LTS release 17.11.5

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

Also note that after the patch there's a diff of the upstream commit vs the patch applied
to the branch. If the code is different (ie: not only metadata diffs), due for example to
a change in context or macro names, please double check it.

Thanks.

Yongseok

---
>From 37f7f2fe3d21772880713eb11150152b5ac25757 Mon Sep 17 00:00:00 2001
From: Andy Green <andy@warmcat.com>
Date: Tue, 22 May 2018 09:24:47 +0800
Subject: [PATCH] ethdev: fix type and scope of variables in Rx burst

[ upstream commit 3291abb5a2a5f24c109ab74e6aad0545927333a7 ]

GCC 8.1 warned:

In function 'rte_eth_rx_burst':
rte_ethdev.h:3836:18: warning: conversion to 'int16_t'
{aka 'short int'} from 'uint16_t' {aka 'short unsigned int'}
may change the sign of the result [-Wsign-conversion]
  int16_t nb_rx = (*dev->rx_pkt_burst)(dev->data->rx_queues[queue_id],
                  ^
rte_ethdev.h:3844:50: warning: conversion to 'uint16_t'
{aka 'short unsigned int'} from 'int16_t' {aka 'short int'}
may change the sign of the result [-Wsign-conversion]
    nb_rx = cb->fn.rx(port_id, queue_id, rx_pkts, nb_rx,
                                                  ^~~~~
rte_ethdev.h:3844:12: warning: conversion to 'int16_t'
{aka 'short int'} from 'uint16_t' {aka 'short unsigned int'}
may change the sign of the result [-Wsign-conversion]
    nb_rx = cb->fn.rx(port_id, queue_id, rx_pkts, nb_rx,
            ^~
rte_ethdev.h:3851:9: warning: conversion to 'uint16_t'
{aka 'short unsigned int'} from 'int16_t' {aka 'short int'}
may change the sign of the result [-Wsign-conversion]
  return nb_rx;
         ^~~~~

The second part of the patch is solved by its own basic
block because it is inside a preprocessor conditional.

Bringing the declaration of the var to the top of the
function would require that also being given its own
preprocessor conditional, or a (void)var to avoid an
unused var warning.  The basic block is no worse than
those imho.

Fixes: 467465d86df1 ("ethdev: add packet count parameter to Rx callback")
Fixes: 4dc294158cac ("ethdev: support optional Rx and Tx callbacks")

Signed-off-by: Andy Green <andy@warmcat.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
---
 lib/librte_ether/rte_ethdev.h | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/lib/librte_ether/rte_ethdev.h b/lib/librte_ether/rte_ethdev.h
index 65cb04755..f252e4110 100644
--- a/lib/librte_ether/rte_ethdev.h
+++ b/lib/librte_ether/rte_ethdev.h
@@ -2884,6 +2884,7 @@ rte_eth_rx_burst(uint16_t port_id, uint16_t queue_id,
 		 struct rte_mbuf **rx_pkts, const uint16_t nb_pkts)
 {
 	struct rte_eth_dev *dev = &rte_eth_devices[port_id];
+	uint16_t nb_rx;
 
 #ifdef RTE_LIBRTE_ETHDEV_DEBUG
 	RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, 0);
@@ -2894,13 +2895,14 @@ rte_eth_rx_burst(uint16_t port_id, uint16_t queue_id,
 		return 0;
 	}
 #endif
-	int16_t nb_rx = (*dev->rx_pkt_burst)(dev->data->rx_queues[queue_id],
-			rx_pkts, nb_pkts);
+	nb_rx = (*dev->rx_pkt_burst)(dev->data->rx_queues[queue_id],
+				     rx_pkts, nb_pkts);
 
 #ifdef RTE_ETHDEV_RXTX_CALLBACKS
-	struct rte_eth_rxtx_callback *cb = dev->post_rx_burst_cbs[queue_id];
+	if (unlikely(dev->post_rx_burst_cbs[queue_id] != NULL)) {
+		struct rte_eth_rxtx_callback *cb =
+			dev->post_rx_burst_cbs[queue_id];
 
-	if (unlikely(cb != NULL)) {
 		do {
 			nb_rx = cb->fn.rx(port_id, queue_id, rx_pkts, nb_rx,
 						nb_pkts, cb->param);
-- 
2.11.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-01-02 23:59:14.026358246 -0800
+++ 0037-ethdev-fix-type-and-scope-of-variables-in-Rx-burst.patch	2019-01-02 23:59:12.108815000 -0800
@@ -1,8 +1,10 @@
-From 3291abb5a2a5f24c109ab74e6aad0545927333a7 Mon Sep 17 00:00:00 2001
+From 37f7f2fe3d21772880713eb11150152b5ac25757 Mon Sep 17 00:00:00 2001
 From: Andy Green <andy@warmcat.com>
 Date: Tue, 22 May 2018 09:24:47 +0800
 Subject: [PATCH] ethdev: fix type and scope of variables in Rx burst
 
+[ upstream commit 3291abb5a2a5f24c109ab74e6aad0545927333a7 ]
+
 GCC 8.1 warned:
 
 In function 'rte_eth_rx_burst':
@@ -38,19 +40,18 @@
 
 Fixes: 467465d86df1 ("ethdev: add packet count parameter to Rx callback")
 Fixes: 4dc294158cac ("ethdev: support optional Rx and Tx callbacks")
-Cc: stable@dpdk.org
 
 Signed-off-by: Andy Green <andy@warmcat.com>
 Acked-by: Bruce Richardson <bruce.richardson@intel.com>
 ---
- lib/librte_ethdev/rte_ethdev.h | 10 ++++++----
+ lib/librte_ether/rte_ethdev.h | 10 ++++++----
  1 file changed, 6 insertions(+), 4 deletions(-)
 
-diff --git a/lib/librte_ethdev/rte_ethdev.h b/lib/librte_ethdev/rte_ethdev.h
-index d52c1bed9..584af85ad 100644
---- a/lib/librte_ethdev/rte_ethdev.h
-+++ b/lib/librte_ethdev/rte_ethdev.h
-@@ -3823,6 +3823,7 @@ rte_eth_rx_burst(uint16_t port_id, uint16_t queue_id,
+diff --git a/lib/librte_ether/rte_ethdev.h b/lib/librte_ether/rte_ethdev.h
+index 65cb04755..f252e4110 100644
+--- a/lib/librte_ether/rte_ethdev.h
++++ b/lib/librte_ether/rte_ethdev.h
+@@ -2884,6 +2884,7 @@ rte_eth_rx_burst(uint16_t port_id, uint16_t queue_id,
  		 struct rte_mbuf **rx_pkts, const uint16_t nb_pkts)
  {
  	struct rte_eth_dev *dev = &rte_eth_devices[port_id];
@@ -58,7 +59,7 @@
  
  #ifdef RTE_LIBRTE_ETHDEV_DEBUG
  	RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, 0);
-@@ -3833,13 +3834,14 @@ rte_eth_rx_burst(uint16_t port_id, uint16_t queue_id,
+@@ -2894,13 +2895,14 @@ rte_eth_rx_burst(uint16_t port_id, uint16_t queue_id,
  		return 0;
  	}
  #endif
@@ -71,7 +72,7 @@
 -	struct rte_eth_rxtx_callback *cb = dev->post_rx_burst_cbs[queue_id];
 +	if (unlikely(dev->post_rx_burst_cbs[queue_id] != NULL)) {
 +		struct rte_eth_rxtx_callback *cb =
-+				dev->post_rx_burst_cbs[queue_id];
++			dev->post_rx_burst_cbs[queue_id];
  
 -	if (unlikely(cb != NULL)) {
  		do {

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

end of thread, other threads:[~2019-01-03  8:15 UTC | newest]

Thread overview: 37+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-01-03  8:13 [dpdk-stable] patch 'eal: explicit cast of builtin for bsf32' has been queued to LTS release 17.11.5 Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'eal: explicit cast of core id when getting index' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'eal: declare trace buffer at top of own block' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'spinlock/x86: move stack declaration before code' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'net: move stack variable at top of VLAN strip function' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'ethdev: explicit cast of buffered Tx number' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'hash: move stack declaration at top of CRC32c function' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'hash: explicit casts for truncation in CRC32c' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'bus/pci: replace strncpy by strlcpy' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'bus/dpaa: fix inconsistent struct alignment' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'net/nfp: fix memcpy out of source range' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'net/qede: replace strncpy by strlcpy' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'net/qede: fix strncpy' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'net/sfc: make sure that stats name is nul-terminated' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'app/procinfo: fix sprintf overrun' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'devtools: provide more generic grep in git check' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'eal: explicit cast of strlcpy return' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'eal: fix casts in random functions' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'eal: explicit cast in constant byte swap' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'ring: remove useless variables' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'ring: remove signed type flip-flopping' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'mbuf: fix reference counter integer promotion' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'mbuf: explicit casts of reference counter' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'mbuf: explicit cast of headroom on reset' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'mbuf: explicit cast of size on detach' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'net: explicit cast of multicast bit clearing' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'net: explicit cast of IP checksum to 16-bit' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'net: explicit cast of protocol in IPv6 checksum' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'ethdev: explicit cast of queue count return' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'eal/x86: fix type of variable in memcpy function' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'eal: explicit cast in rwlock functions' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'net: explicit cast in L4 checksum' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'mbuf: fix type of private size in detach' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'mbuf: fix type of variables in linearize function' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'mbuf: avoid implicit demotion in 64-bit arithmetic' " Yongseok Koh
2019-01-03  8:13 ` [dpdk-stable] patch 'mbuf: avoid integer promotion in prepend/adj/chain' " Yongseok Koh
2019-01-03  8:14 ` [dpdk-stable] patch 'ethdev: fix type and scope of variables in Rx burst' " Yongseok Koh

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).