From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <stable-bounces@dpdk.org>
Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124])
	by inbox.dpdk.org (Postfix) with ESMTP id 8CC53A0524
	for <public@inbox.dpdk.org>; Fri,  5 Feb 2021 12:20:06 +0100 (CET)
Received: from [217.70.189.124] (localhost [127.0.0.1])
	by mails.dpdk.org (Postfix) with ESMTP id 86D734067B;
	Fri,  5 Feb 2021 12:20:06 +0100 (CET)
Received: from mail-wr1-f43.google.com (mail-wr1-f43.google.com
 [209.85.221.43])
 by mails.dpdk.org (Postfix) with ESMTP id 76A961606C6
 for <stable@dpdk.org>; Fri,  5 Feb 2021 12:20:05 +0100 (CET)
Received: by mail-wr1-f43.google.com with SMTP id m13so7226313wro.12
 for <stable@dpdk.org>; Fri, 05 Feb 2021 03:20:05 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
 h=from:to:cc:subject:date:message-id:in-reply-to:references
 :mime-version:content-transfer-encoding;
 bh=ZjQKZzOAdOG/a6N5fsLg8RlQ/I2v6az/bl9EmwBZ33I=;
 b=t8rc3PnraG7tQDlAOlI0K+GaltWZziD4eLnQ+VmlRP5Cd+/Jn7cF579RtuoTLOcrRx
 dqZksIQkv3jV+4MUlarrw5/SRxp5t0s8q7dGbByZjPk+b2Zv3CruUZR6BwBPEUPxwCeT
 UT9G8IXb9biWkQbjlkY5ObhUyYmKdhnZBiVEYyle1pHL1E26XOkL+gAjkHwMWH+YYScy
 sCkW8eVDTcHVkP2TuTtX08SJvNVPFZ9aw9RwtWbar+/ZuqsQya6XS4JNa3VhMZCiSjr+
 GwM0oPUwbOgdQvjq59Zi/FLw5Pn/VVOSr2tINirnRegVpnSiLUB/t1JKMcM7FfKqLkX4
 Z9AA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to
 :references:mime-version:content-transfer-encoding;
 bh=ZjQKZzOAdOG/a6N5fsLg8RlQ/I2v6az/bl9EmwBZ33I=;
 b=QEFPH6oXHwjImmoFunrS0We9ZraA2gVh2jKJIMQO0ehSjbUJLZXhRsutBsXtLBas6X
 NdCKc6QvjqFCeOOSqWsU+au7Nq3SnQBRcj2d0J3P0msw2qXN+NobjUVqEQ1PO/fY8jSc
 8PygFg2nTgtYQVoymOWb1V2AJS6QQ1oMz/o8fOtgzzcLoko2KaSm6m+1XccR/3JaV1ie
 qJHenaaBPs5pWxutQ5yG0r/GlhN6IRCHnvG0kkUnF9OQ9XIe+aKBTanyIMLRT6x1rYmg
 7ugPBGh2+gNAfG3yGK9I1eX5k0vGI/XKNO70nydEIBKX3uluLeBkXWWCiQV0J1EBmXJx
 W2fA==
X-Gm-Message-State: AOAM533Ixx5inDew6fvsTvPSWbXFWW3A7p7Wb5hlj0FMpSFZtkZmrkX6
 hMC+ieRQkvcBjgh0rsc/Eak=
X-Google-Smtp-Source: ABdhPJwBVJBUJ9PMts0atsBL3Zl5oXcVA6eVO7H5HWZpa3cgZlDFe0+ECGJjMTuww7UmNCoDrhBUiw==
X-Received: by 2002:adf:ab10:: with SMTP id q16mr4413375wrc.297.1612524005125; 
 Fri, 05 Feb 2021 03:20:05 -0800 (PST)
Received: from localhost ([88.98.246.218])
 by smtp.gmail.com with ESMTPSA id q7sm10880143wro.55.2021.02.05.03.20.04
 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);
 Fri, 05 Feb 2021 03:20:04 -0800 (PST)
From: luca.boccassi@gmail.com
To: Ferruh Yigit <ferruh.yigit@intel.com>
Cc: David Marchand <david.marchand@redhat.com>, dpdk stable <stable@dpdk.org>
Date: Fri,  5 Feb 2021 11:14:59 +0000
Message-Id: <20210205111920.1272063-13-luca.boccassi@gmail.com>
X-Mailer: git-send-email 2.29.2
In-Reply-To: <20210205111920.1272063-1-luca.boccassi@gmail.com>
References: <20210205111920.1272063-1-luca.boccassi@gmail.com>
MIME-Version: 1.0
Content-Transfer-Encoding: 8bit
Subject: [dpdk-stable] patch 'app/procinfo: fix check on xstats-ids' has
 been queued to stable release 20.11.1
X-BeenThere: stable@dpdk.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: patches for DPDK stable branches <stable.dpdk.org>
List-Unsubscribe: <https://mails.dpdk.org/options/stable>,
 <mailto:stable-request@dpdk.org?subject=unsubscribe>
List-Archive: <http://mails.dpdk.org/archives/stable/>
List-Post: <mailto:stable@dpdk.org>
List-Help: <mailto:stable-request@dpdk.org?subject=help>
List-Subscribe: <https://mails.dpdk.org/listinfo/stable>,
 <mailto:stable-request@dpdk.org?subject=subscribe>
Errors-To: stable-bounces@dpdk.org
Sender: "stable" <stable-bounces@dpdk.org>

Hi,

FYI, your patch has been queued to stable release 20.11.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 02/07/21. 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/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/02cd8d2c11761f7c8955f93c9c0a55e35254e857

Thanks.

Luca Boccassi

---
>From 02cd8d2c11761f7c8955f93c9c0a55e35254e857 Mon Sep 17 00:00:00 2001
From: Ferruh Yigit <ferruh.yigit@intel.com>
Date: Thu, 19 Nov 2020 11:58:52 +0000
Subject: [PATCH] app/procinfo: fix check on xstats-ids

[ upstream commit 59b981c6f69cb1c705bfb93890ce8cc2a8bcdfb5 ]

'parse_xstats_ids()' return 'int'. The return value is assigned to
'nb_xstats_ids' unsigned value, later negative check on this variable is
wrong.

Adding interim 'int' variable for negative check.

Fixes: 7ac16a3660c0 ("app/proc-info: support xstats by ID and by name")

Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
Reviewed-by: David Marchand <david.marchand@redhat.com>
---
 app/proc-info/main.c | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/app/proc-info/main.c b/app/proc-info/main.c
index 35e5b596eb..8ee30ddb71 100644
--- a/app/proc-info/main.c
+++ b/app/proc-info/main.c
@@ -301,14 +301,13 @@ proc_info_parse_args(int argc, char **argv)
 			} else if (!strncmp(long_option[option_index].name,
 					"xstats-ids",
 					MAX_LONG_OPT_SZ))	{
-				nb_xstats_ids = parse_xstats_ids(optarg,
+				int ret = parse_xstats_ids(optarg,
 						xstats_ids, MAX_NB_XSTATS_IDS);
-
-				if (nb_xstats_ids <= 0) {
+				if (ret <= 0) {
 					printf("xstats-id list parse error.\n");
 					return -1;
 				}
-
+				nb_xstats_ids = ret;
 			}
 			break;
 		default:
-- 
2.29.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2021-02-05 11:18:29.911670553 +0000
+++ 0013-app-procinfo-fix-check-on-xstats-ids.patch	2021-02-05 11:18:28.594687075 +0000
@@ -1 +1 @@
-From 59b981c6f69cb1c705bfb93890ce8cc2a8bcdfb5 Mon Sep 17 00:00:00 2001
+From 02cd8d2c11761f7c8955f93c9c0a55e35254e857 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit 59b981c6f69cb1c705bfb93890ce8cc2a8bcdfb5 ]
+
@@ -13 +14,0 @@
-Cc: stable@dpdk.org