From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 85855A0C45 for ; Thu, 10 Jun 2021 14:07:34 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 7A94C40E64; Thu, 10 Jun 2021 14:07:34 +0200 (CEST) Received: from youngberry.canonical.com (youngberry.canonical.com [91.189.89.112]) by mails.dpdk.org (Postfix) with ESMTP id 92A714003C for ; Thu, 10 Jun 2021 14:07:33 +0200 (CEST) Received: from 2.general.paelzer.uk.vpn ([10.172.196.173] helo=localhost.localdomain) by youngberry.canonical.com with esmtpsa (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.93) (envelope-from ) id 1lrJTB-00006q-DL; Thu, 10 Jun 2021 12:07:33 +0000 From: Christian Ehrhardt To: Jie Wang Cc: Qi Zhang , dpdk stable Date: Thu, 10 Jun 2021 14:06:10 +0200 Message-Id: <20210610120641.885862-22-christian.ehrhardt@canonical.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210610120641.885862-1-christian.ehrhardt@canonical.com> References: <20210610120641.885862-1-christian.ehrhardt@canonical.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-stable] patch 'net/ice: fix VSI array out of bounds access' has been queued to stable release 19.11.9 X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 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" Hi, FYI, your patch has been queued to stable release 19.11.9 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/12/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/cpaelzer/dpdk-stable-queue This queued commit can be viewed at: https://github.com/cpaelzer/dpdk-stable-queue/commit/950f65a5a7edb65cc5106db8a03d16add786b578 Thanks. Christian Ehrhardt --- >From 950f65a5a7edb65cc5106db8a03d16add786b578 Mon Sep 17 00:00:00 2001 From: Jie Wang Date: Wed, 12 May 2021 03:14:07 +0000 Subject: [PATCH] net/ice: fix VSI array out of bounds access [ upstream commit d7ea27d065ebe3206c0739c67bf66510c0ac79a1 ] In the loop, when the index of array "vsi->rss_key" is equal to "vsi->rss_key_size", the array will be accessed out of bounds. Fixes: 50370662b727 ("net/ice: support device and queue ops") Signed-off-by: Jie Wang Acked-by: Qi Zhang --- drivers/net/ice/ice_ethdev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ice/ice_ethdev.c b/drivers/net/ice/ice_ethdev.c index c9c096ad81..4e15ed54bf 100644 --- a/drivers/net/ice/ice_ethdev.c +++ b/drivers/net/ice/ice_ethdev.c @@ -2507,7 +2507,7 @@ static int ice_init_rss(struct ice_pf *pf) /* configure RSS key */ if (!rss_conf->rss_key) { /* Calculate the default hash key */ - for (i = 0; i <= vsi->rss_key_size; i++) + for (i = 0; i < vsi->rss_key_size; i++) vsi->rss_key[i] = (uint8_t)rte_rand(); } else { rte_memcpy(vsi->rss_key, rss_conf->rss_key, -- 2.31.1 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2021-06-10 14:04:59.101216090 +0200 +++ 0022-net-ice-fix-VSI-array-out-of-bounds-access.patch 2021-06-10 14:04:58.050024525 +0200 @@ -1 +1 @@ -From d7ea27d065ebe3206c0739c67bf66510c0ac79a1 Mon Sep 17 00:00:00 2001 +From 950f65a5a7edb65cc5106db8a03d16add786b578 Mon Sep 17 00:00:00 2001 @@ -5,0 +6,2 @@ +[ upstream commit d7ea27d065ebe3206c0739c67bf66510c0ac79a1 ] + @@ -10 +11,0 @@ -Cc: stable@dpdk.org @@ -19 +20 @@ -index f742d07fc2..5fd5f99b6f 100644 +index c9c096ad81..4e15ed54bf 100644 @@ -22 +23 @@ -@@ -3040,7 +3040,7 @@ static int ice_init_rss(struct ice_pf *pf) +@@ -2507,7 +2507,7 @@ static int ice_init_rss(struct ice_pf *pf)