From patchwork Mon Oct 23 09:45:00 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?q?N=C3=A9lio_Laranjeiro?= X-Patchwork-Id: 30692 X-Patchwork-Delegate: ferruh.yigit@amd.com Return-Path: X-Original-To: patchwork@dpdk.org Delivered-To: patchwork@dpdk.org Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 8EB881B3DC; Mon, 23 Oct 2017 11:45:26 +0200 (CEST) Received: from mail-wm0-f65.google.com (mail-wm0-f65.google.com [74.125.82.65]) by dpdk.org (Postfix) with ESMTP id 0494D1B3CB for ; Mon, 23 Oct 2017 11:45:19 +0200 (CEST) Received: by mail-wm0-f65.google.com with SMTP id u138so8275303wmu.5 for ; Mon, 23 Oct 2017 02:45:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :in-reply-to:references; bh=4LfEBcFWA3guoTurZrkLBmYUUG9nybW+jTAI2lFQfeY=; b=w29YUtSR746rFAnjH82qE1JuiPj7re5K6oWTuVFqZcoNoENRkSdpBWm/7FF9DBFGvC r26KwjkJqt/fOz40y5wr59hl4qSxed5QWdUVxDccBG1AQEI3cfP3Q7nsZIilZJN5dCMQ IAnZMbXDe+qIDL3t0U5+3TMBe1ND9Lh03mvw7AVq0D6DoklDC8YMe0eWUQdMfr2OOiDR /2aMCw3dWSV//IHPe15TzY8Yx5VyIrQF4cflqDb79wyPJ/8Zp6s6O43ubxYOkEDUSFVX An3xm+5O+Mq4A1POCfu//8jGIUVwQ92tBxVRW0pNMld4xYVWzyIYPu40FH4UfrgBxqkN JiZg== 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:in-reply-to:references; bh=4LfEBcFWA3guoTurZrkLBmYUUG9nybW+jTAI2lFQfeY=; b=Xgf0B8RvAoOsIgKvL7a+csSL4SVkUPF5Wu7sGZ8rGCErU1tP+G7DFifL67yEIK3/bl n/ywKgmBhVVrTSHOEVZo3ZO2wrg9c1mHevnow4vBAU/Y+/J9za7cuR6c6qpl1CKj/xHL KoKXQjD+MVxj+Yu6VDhC47YVUdn/cTqbbS0o9OBwUhrgo/l6wiB6nTXwUuqoF42yqu6G UQefGpuxaGNlypeNp+GnrjVcjYEgAIb19wOSNW18dDdkf+yYjQvGMBAqTEneyNNkNWVA 6Wv3rJIbMhKtBPjIVW3/HByDL1cDPJ8sI9cGLuQAX/2qemivhS6Ry3Hp7c2C/Aluk4kM +DvA== X-Gm-Message-State: AMCzsaUYh/xGWC/hy0Hakplb/Ex6CeTayGlgW5iByPU41Za2PGKlpDb1 e9Yr9GWR412gt1Fx0ECQGGI6bPNTVQ== X-Google-Smtp-Source: ABhQp+QbLvHx8qhSQ4kSgUYbYp+viNc3344VhK/kiZuXrLe5tyPz/FGZYlupQW3PN5vvSjkRjsBV9Q== X-Received: by 10.28.46.16 with SMTP id u16mr4650275wmu.125.1508751919123; Mon, 23 Oct 2017 02:45:19 -0700 (PDT) Received: from laranjeiro-vm.dev.6wind.com. (host.78.145.23.62.rev.coltfrance.com. [62.23.145.78]) by smtp.gmail.com with ESMTPSA id x189sm2829610wmf.10.2017.10.23.02.45.18 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 23 Oct 2017 02:45:18 -0700 (PDT) From: Nelio Laranjeiro To: dev@dpdk.org Cc: Yongseok Koh , Adrien Mazarguil , ivan.boule@6wind.com, stable@dpdk.org Date: Mon, 23 Oct 2017 11:45:00 +0200 Message-Id: <441cee59d3e6f9d1af231ea0a770a2fb316a2e7a.1508750504.git.nelio.laranjeiro@6wind.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: References: In-Reply-To: References: Subject: [dpdk-dev] [PATCH 2/3] app/testpmd: fix RSS structure initialisation X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Struct rss_conf.rss_key_len is not initialised forcing the user to verify the rss_conf.rss_key pointer to know if the key is present or not. rss_conf.rss_key_len should have a valid length according to the size of the rss_key pointed. Fixes: 560e02ee5237 ("app/testpmd: configure RSS without restart") Cc: ivan.boule@6wind.com Cc: stable@dpdk.org Signed-off-by: Nelio Laranjeiro Acked-by: Yongseok Koh --- app/test-pmd/cmdline.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/test-pmd/cmdline.c b/app/test-pmd/cmdline.c index bb01e989a..7002ff2c1 100644 --- a/app/test-pmd/cmdline.c +++ b/app/test-pmd/cmdline.c @@ -1750,7 +1750,7 @@ cmd_config_rss_parsed(void *parsed_result, __attribute__((unused)) void *data) { struct cmd_config_rss *res = parsed_result; - struct rte_eth_rss_conf rss_conf; + struct rte_eth_rss_conf rss_conf = { .rss_key_len = 0, }; int diag; uint8_t i;