[dpdk-stable] patch 'net/bnx2x: fix dynamic logging' has been queued to stable release 18.08.1

Kevin Traynor ktraynor at redhat.com
Thu Nov 29 14:20:17 CET 2018


Hi,

FYI, your patch has been queued to stable release 18.08.1

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 12/08/18. 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.

Kevin Traynor

---
>From 416f760dbfe770be9207c9f25385c6b8bb77a2f6 Mon Sep 17 00:00:00 2001
From: Rasesh Mody <rasesh.mody at cavium.com>
Date: Thu, 8 Nov 2018 21:19:26 +0000
Subject: [PATCH] net/bnx2x: fix dynamic logging

[ upstream commit 853c782496534446f60189be2516c4bb933f11df ]

Use rte_log() rather than RTE_LOG() for dynamic logging. Rearrange
dynamic log types to the top and configurable log types to bottom.
Remove unused RTE_LIBRTE_BNX2X_DEBUG_TX_FREE

Fixes: ba7eeb035a5f ("net/bnx2x: fix logging to include device name")

Signed-off-by: Rasesh Mody <rasesh.mody at cavium.com>
Acked-by: Stephen Hemminger <stephen at networkplumber.org>
---
 drivers/net/bnx2x/bnx2x_logs.h | 35 ++++++++++++++++------------------
 1 file changed, 16 insertions(+), 19 deletions(-)

diff --git a/drivers/net/bnx2x/bnx2x_logs.h b/drivers/net/bnx2x/bnx2x_logs.h
index 753bccdf4..f0cf69c16 100644
--- a/drivers/net/bnx2x/bnx2x_logs.h
+++ b/drivers/net/bnx2x/bnx2x_logs.h
@@ -11,12 +11,22 @@
 extern int bnx2x_logtype_init;
 #define PMD_INIT_LOG(level, sc, fmt, args...) \
-	RTE_LOG(level, PMD, \
+	rte_log(RTE_LOG_ ## level, bnx2x_logtype_init, \
 	"[bnx2x_pmd: %s] %s() " fmt "\n", (sc)->devinfo.name, __func__, ##args)
 
 #define PMD_INIT_FUNC_TRACE(sc) PMD_INIT_LOG(DEBUG, sc, " >>")
 
+extern int bnx2x_logtype_driver;
+#define PMD_DRV_LOG_RAW(level, sc, fmt, args...) \
+	rte_log(RTE_LOG_ ## level, bnx2x_logtype_driver, \
+		"[%s:%d(%s)] " fmt,	__func__, __LINE__, \
+		(sc)->devinfo.name ? (sc)->devinfo.name : "", ## args)
+
+#define PMD_DRV_LOG(level, sc, fmt, args...) \
+	PMD_DRV_LOG_RAW(level, sc, fmt "\n", ## args)
+
 #ifdef RTE_LIBRTE_BNX2X_DEBUG_RX
 #define PMD_RX_LOG(level, fmt, args...) \
-	RTE_LOG(level, PMD, "%s(): " fmt "\n", __func__, ## args)
+	rte_log(RTE_LOG_ ## level, bnx2x_logtype_driver, \
+	"%s(): " fmt "\n", __func__, ## args)
 #else
 #define PMD_RX_LOG(level, fmt, args...) do { } while(0)
@@ -25,27 +35,14 @@ extern int bnx2x_logtype_init;
 #ifdef RTE_LIBRTE_BNX2X_DEBUG_TX
 #define PMD_TX_LOG(level, fmt, args...) \
-	RTE_LOG(level, PMD, "%s(): " fmt "\n", __func__, ## args)
+	rte_log(RTE_LOG_ ## level, bnx2x_logtype_driver, \
+		"%s(): " fmt "\n", __func__, ## args)
 #else
 #define PMD_TX_LOG(level, fmt, args...) do { } while(0)
 #endif
 
-#ifdef RTE_LIBRTE_BNX2X_DEBUG_TX_FREE
-#define PMD_TX_FREE_LOG(level, fmt, args...) \
-	RTE_LOG(level, PMD, "%s(): " fmt "\n", __func__, ## args)
-#else
-#define PMD_TX_FREE_LOG(level, fmt, args...) do { } while(0)
-#endif
-
-extern int bnx2x_logtype_driver;
-#define PMD_DRV_LOG_RAW(level, sc, fmt, args...) \
-	RTE_LOG(level, PMD, "[%s:%d(%s)] " fmt,	__func__, __LINE__, \
-		(sc)->devinfo.name ? (sc)->devinfo.name : "", ## args)
-
-#define PMD_DRV_LOG(level, sc, fmt, args...) \
-	PMD_DRV_LOG_RAW(level, sc, fmt "\n", ## args)
-
 #ifdef RTE_LIBRTE_BNX2X_DEBUG_PERIODIC
 #define PMD_DEBUG_PERIODIC_LOG(level, sc, fmt, args...) \
-	RTE_LOG(level, PMD, "%s(%s): " fmt "\n", __func__, \
+	rte_log(RTE_LOG_ ## level, bnx2x_logtype_driver, \
+		"%s(%s): " fmt "\n", __func__, \
 		(sc)->devinfo.name ? (sc)->devinfo.name : "", ## args)
 #else
-- 
2.19.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2018-11-29 13:11:35.443701579 +0000
+++ 0016-net-bnx2x-fix-dynamic-logging.patch	2018-11-29 13:11:34.000000000 +0000
@@ -1,14 +1,15 @@
-From 853c782496534446f60189be2516c4bb933f11df Mon Sep 17 00:00:00 2001
+From 416f760dbfe770be9207c9f25385c6b8bb77a2f6 Mon Sep 17 00:00:00 2001
 From: Rasesh Mody <rasesh.mody at cavium.com>
 Date: Thu, 8 Nov 2018 21:19:26 +0000
 Subject: [PATCH] net/bnx2x: fix dynamic logging
 
+[ upstream commit 853c782496534446f60189be2516c4bb933f11df ]
+
 Use rte_log() rather than RTE_LOG() for dynamic logging. Rearrange
 dynamic log types to the top and configurable log types to bottom.
 Remove unused RTE_LIBRTE_BNX2X_DEBUG_TX_FREE
 
 Fixes: ba7eeb035a5f ("net/bnx2x: fix logging to include device name")
-Cc: stable at dpdk.org
 
 Signed-off-by: Rasesh Mody <rasesh.mody at cavium.com>
 Acked-by: Stephen Hemminger <stephen at networkplumber.org>


More information about the stable mailing list