[dpdk-stable] patch 'net/bonding: fix slave id types' has been queued to LTS release 18.11.6

Kevin Traynor ktraynor at redhat.com
Tue Dec 3 19:26:31 CET 2019


Hi,

FYI, your patch has been queued to LTS release 18.11.6

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 12/10/19. 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/kevintraynor/dpdk-stable-queue

This queued commit can be viewed at:
https://github.com/kevintraynor/dpdk-stable-queue/commit/ca538e25f0c02f47a39949f7dc41c8411483b914

Thanks.

Kevin.

---
>From ca538e25f0c02f47a39949f7dc41c8411483b914 Mon Sep 17 00:00:00 2001
From: Hui Zhao <zhaohui8 at huawei.com>
Date: Thu, 21 Mar 2019 21:28:13 +0100
Subject: [PATCH] net/bonding: fix slave id types

[ upstream commit c28aff1e41eedd9d44c480264efbd7f4dd5cf31e ]

mode_bond_id and mode_band_id are slave ids, stored on 16bits.

Fixes: f8244c6399d9 ("ethdev: increase port id range")

Signed-off-by: Hui Zhao <zhaohui8 at huawei.com>
Signed-off-by: David Marchand <david.marchand at redhat.com>
Reviewed-by: Maxime Coquelin <maxime.coquelin at redhat.com>
---
 drivers/net/bonding/rte_eth_bond_8023ad.c | 11 +++++------
 1 file changed, 5 insertions(+), 6 deletions(-)

diff --git a/drivers/net/bonding/rte_eth_bond_8023ad.c b/drivers/net/bonding/rte_eth_bond_8023ad.c
index 1e6a3fc7c..3943ec139 100644
--- a/drivers/net/bonding/rte_eth_bond_8023ad.c
+++ b/drivers/net/bonding/rte_eth_bond_8023ad.c
@@ -639,5 +639,5 @@ tx_machine(struct bond_dev_private *internals, uint16_t slave_id)
 }
 
-static uint8_t
+static uint16_t
 max_index(uint64_t *a, int n)
 {
@@ -673,5 +673,6 @@ selection_logic(struct bond_dev_private *internals, uint16_t slave_id)
 	uint64_t agg_count[8] = {0};
 	uint16_t default_slave = 0;
-	uint8_t mode_count_id, mode_band_id;
+	uint16_t mode_count_id;
+	uint16_t mode_band_id;
 	struct rte_eth_link link_info;
 
@@ -709,11 +710,9 @@ selection_logic(struct bond_dev_private *internals, uint16_t slave_id)
 	switch (internals->mode4.agg_selection) {
 	case AGG_COUNT:
-		mode_count_id = max_index(
-				(uint64_t *)agg_count, slaves_count);
+		mode_count_id = max_index(agg_count, slaves_count);
 		new_agg_id = mode_count_id;
 		break;
 	case AGG_BANDWIDTH:
-		mode_band_id = max_index(
-				(uint64_t *)agg_bandwidth, slaves_count);
+		mode_band_id = max_index(agg_bandwidth, slaves_count);
 		new_agg_id = mode_band_id;
 		break;
-- 
2.21.0

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-12-03 17:29:53.118919055 +0000
+++ 0022-net-bonding-fix-slave-id-types.patch	2019-12-03 17:29:51.739750182 +0000
@@ -1 +1 @@
-From c28aff1e41eedd9d44c480264efbd7f4dd5cf31e Mon Sep 17 00:00:00 2001
+From ca538e25f0c02f47a39949f7dc41c8411483b914 Mon Sep 17 00:00:00 2001
@@ -5,0 +6,2 @@
+[ upstream commit c28aff1e41eedd9d44c480264efbd7f4dd5cf31e ]
+
@@ -9 +10,0 @@
-Cc: stable at dpdk.org
@@ -19 +20 @@
-index e50d946eb..c6a645a65 100644
+index 1e6a3fc7c..3943ec139 100644
@@ -22 +23 @@
-@@ -640,5 +640,5 @@ tx_machine(struct bond_dev_private *internals, uint16_t slave_id)
+@@ -639,5 +639,5 @@ tx_machine(struct bond_dev_private *internals, uint16_t slave_id)
@@ -29 +30 @@
-@@ -674,5 +674,6 @@ selection_logic(struct bond_dev_private *internals, uint16_t slave_id)
+@@ -673,5 +673,6 @@ selection_logic(struct bond_dev_private *internals, uint16_t slave_id)
@@ -36,2 +37,2 @@
- 	int ret;
-@@ -718,11 +719,9 @@ selection_logic(struct bond_dev_private *internals, uint16_t slave_id)
+ 
+@@ -709,11 +710,9 @@ selection_logic(struct bond_dev_private *internals, uint16_t slave_id)



More information about the stable mailing list