From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 22B5FA055F for ; Wed, 26 Feb 2020 09:04:04 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id EF24F1BFC7; Wed, 26 Feb 2020 09:04:03 +0100 (CET) Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by dpdk.org (Postfix) with ESMTP id E030D1F1C; Wed, 26 Feb 2020 09:03:59 +0100 (CET) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by fmsmga104.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 26 Feb 2020 00:03:58 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.70,487,1574150400"; d="scan'208";a="271641437" Received: from intel.sh.intel.com ([10.239.255.136]) by fmsmga002.fm.intel.com with ESMTP; 26 Feb 2020 00:03:56 -0800 From: Junyu Jiang To: dev@dpdk.org Cc: Xiaoyun Li , Junyu Jiang , stable@dpdk.org Date: Wed, 26 Feb 2020 07:57:48 +0000 Message-Id: <20200226075748.67911-1-junyux.jiang@intel.com> X-Mailer: git-send-email 2.17.1 Subject: [dpdk-stable] [PATCH] examples/vmdq: fix the output of pools/queues X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Sender: "stable" To match the pools/queues configuration, the pools/queues output should start from VMDQ base queue. This patch fixed the issue. Fixes: 6bb97df521aa ("examples/vmdq: new app") Cc: stable@dpdk.org Signed-off-by: Junyu Jiang --- examples/vmdq/main.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/examples/vmdq/main.c b/examples/vmdq/main.c index 011110920..592f9bc62 100644 --- a/examples/vmdq/main.c +++ b/examples/vmdq/main.c @@ -441,10 +441,11 @@ update_mac_address(struct rte_mbuf *m, unsigned dst_port) static void sighup_handler(int signum) { - unsigned q; - for (q = 0; q < num_queues; q++) { - if (q % (num_queues/num_pools) == 0) - printf("\nPool %u: ", q/(num_queues/num_pools)); + unsigned q = vmdq_queue_base;; + for (; q < num_queues; q++) { + if (q % (num_vmdq_queues / num_pools) == 0) + printf("\nPool %u: ", (q - vmdq_queue_base) / + (num_vmdq_queues / num_pools)); printf("%lu ", rxPackets[q]); } printf("\nFinished handling signal %d\n", signum); -- 2.17.1