[dpdk-stable] patch 'net/ice: fix VSI array out of bounds access' has been queued to stable release 20.11.2

Xueming Li xuemingl at nvidia.com
Sat Jun 12 01:03:48 CEST 2021


Hi,

FYI, your patch has been queued to stable release 20.11.2

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/14/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/steevenlee/dpdk

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

Thanks.

Xueming Li <xuemingl at nvidia.com>

---
>From 2e077407fee708a0f6052ed44b33e7abcea598b7 Mon Sep 17 00:00:00 2001
From: Jie Wang <jie1x.wang at intel.com>
Date: Wed, 12 May 2021 03:14:07 +0000
Subject: [PATCH] net/ice: fix VSI array out of bounds access
Cc: Luca Boccassi <bluca at debian.org>

[ 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 <jie1x.wang at intel.com>
Acked-by: Qi Zhang <qi.z.zhang at intel.com>
---
 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 2d265fbaa6..40498f038a 100644
--- a/drivers/net/ice/ice_ethdev.c
+++ b/drivers/net/ice/ice_ethdev.c
@@ -3227,7 +3227,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.25.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2021-06-12 06:54:00.018108600 +0800
+++ 0134-net-ice-fix-VSI-array-out-of-bounds-access.patch	2021-06-12 06:53:56.580000000 +0800
@@ -1 +1 @@
-From d7ea27d065ebe3206c0739c67bf66510c0ac79a1 Mon Sep 17 00:00:00 2001
+From 2e077407fee708a0f6052ed44b33e7abcea598b7 Mon Sep 17 00:00:00 2001
@@ -4,0 +5,3 @@
+Cc: Luca Boccassi <bluca at debian.org>
+
+[ upstream commit d7ea27d065ebe3206c0739c67bf66510c0ac79a1 ]
@@ -10 +12,0 @@
-Cc: stable at dpdk.org
@@ -19 +21 @@
-index f742d07fc2..5fd5f99b6f 100644
+index 2d265fbaa6..40498f038a 100644
@@ -22 +24 @@
-@@ -3040,7 +3040,7 @@ static int ice_init_rss(struct ice_pf *pf)
+@@ -3227,7 +3227,7 @@ static int ice_init_rss(struct ice_pf *pf)


More information about the stable mailing list