patch 'app/testpmd: remove useless pointer checks' has been queued to stable release 20.11.6

Xueming Li xuemingl at nvidia.com
Tue Jun 21 10:02:15 CEST 2022


Hi,

FYI, your patch has been queued to stable release 20.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/23/22. 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. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/steevenlee/dpdk

This queued commit can be viewed at:
https://github.com/steevenlee/dpdk/commit/cf28773c938acfdf13f181649facbad24efea7d1

Thanks.

Xueming Li <xuemingl at nvidia.com>

---
>From cf28773c938acfdf13f181649facbad24efea7d1 Mon Sep 17 00:00:00 2001
From: David Marchand <david.marchand at redhat.com>
Date: Thu, 24 Mar 2022 17:15:03 +0100
Subject: [PATCH] app/testpmd: remove useless pointer checks
Cc: Xueming Li <xuemingl at nvidia.com>

[ upstream commit 2d8699ebb2a0638e8ae18fc0a83c56f984d0b270 ]

Parameters to this static helper can't be NULL.
str has already been dereferenced in caller.
dst and size point to variable in stack.

Fixes: 169a9fed1f4c ("app/testpmd: fix hex string parser support for flow API")

Signed-off-by: David Marchand <david.marchand at redhat.com>
---
 app/test-pmd/cmdline_flow.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/app/test-pmd/cmdline_flow.c b/app/test-pmd/cmdline_flow.c
index c80be57bfe..de0db3994b 100644
--- a/app/test-pmd/cmdline_flow.c
+++ b/app/test-pmd/cmdline_flow.c
@@ -6414,11 +6414,7 @@ parse_hex_string(const char *src, uint8_t *dst, uint32_t *size)
 	const uint8_t *head = dst;
 	uint32_t left;
 
-	/* Check input parameters */
-	if ((src == NULL) ||
-		(dst == NULL) ||
-		(size == NULL) ||
-		(*size == 0))
+	if (*size == 0)
 		return -1;
 
 	left = *size;
-- 
2.35.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2022-06-21 15:37:52.420196937 +0800
+++ 0069-app-testpmd-remove-useless-pointer-checks.patch	2022-06-21 15:37:49.101118143 +0800
@@ -1 +1 @@
-From 2d8699ebb2a0638e8ae18fc0a83c56f984d0b270 Mon Sep 17 00:00:00 2001
+From cf28773c938acfdf13f181649facbad24efea7d1 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Xueming Li <xuemingl at nvidia.com>
+
+[ upstream commit 2d8699ebb2a0638e8ae18fc0a83c56f984d0b270 ]
@@ -11 +13,0 @@
-Cc: stable at dpdk.org
@@ -19 +21 @@
-index fc4a6d9cca..e3269e278d 100644
+index c80be57bfe..de0db3994b 100644
@@ -22 +24 @@
-@@ -9338,11 +9338,7 @@ parse_hex_string(const char *src, uint8_t *dst, uint32_t *size)
+@@ -6414,11 +6414,7 @@ parse_hex_string(const char *src, uint8_t *dst, uint32_t *size)


More information about the stable mailing list