From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) by dpdk.org (Postfix) with ESMTP id 8C465C79C for ; Fri, 26 Jun 2015 09:33:04 +0200 (CEST) Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by orsmga103.jf.intel.com with ESMTP; 26 Jun 2015 00:33:04 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.13,683,1427785200"; d="scan'208";a="514532102" Received: from irsmsx151.ger.corp.intel.com ([163.33.192.59]) by FMSMGA003.fm.intel.com with ESMTP; 26 Jun 2015 00:33:03 -0700 Received: from irsmsx155.ger.corp.intel.com (163.33.192.3) by IRSMSX151.ger.corp.intel.com (163.33.192.59) with Microsoft SMTP Server (TLS) id 14.3.224.2; Fri, 26 Jun 2015 08:33:02 +0100 Received: from irsmsx105.ger.corp.intel.com ([169.254.7.245]) by irsmsx155.ger.corp.intel.com ([169.254.14.239]) with mapi id 14.03.0224.002; Fri, 26 Jun 2015 08:33:02 +0100 From: "Doherty, Declan" To: Jan Blunck , "dev@dpdk.org" Thread-Topic: [dpdk-dev] [PATCH] Make bond_ethdev_stop iterate only over active slaves Thread-Index: AQHQrsEWHz732VOrBUGh9nP8R17SP52+ZRsA Date: Fri, 26 Jun 2015 07:33:02 +0000 Message-ID: <345C63BAECC1AD42A2EC8C63AFFC3ADC27F26409@irsmsx105.ger.corp.intel.com> References: <1435179683-10180-1-git-send-email-jblunck@infradead.org> In-Reply-To: <1435179683-10180-1-git-send-email-jblunck@infradead.org> Accept-Language: en-IE, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [163.33.239.180] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH] Make bond_ethdev_stop iterate only over active slaves X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 26 Jun 2015 07:33:05 -0000 > -----Original Message----- > From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Jan Blunck > Sent: Wednesday, June 24, 2015 2:01 PM > To: dev@dpdk.org > Subject: [dpdk-dev] [PATCH] Make bond_ethdev_stop iterate only over activ= e > slaves >=20 > When stopping the bond device we don't need to try and free up the LACPDU= 's > from deactivated devices since this is covered by > bond_mode_8023ad_deactivate_slave(). >=20 > This fixes the following: > [ 0.100569] PANIC in bond_ethdev_stop(): > [ 0.100589] line 1172 assert "port->rx_ring !=3D NULL" failed >=20 > Signed-off-by: Jan Blunck > --- > drivers/net/bonding/rte_eth_bond_pmd.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) >=20 > diff --git a/drivers/net/bonding/rte_eth_bond_pmd.c > b/drivers/net/bonding/rte_eth_bond_pmd.c > index 5a2fbef..1fd1321 100644 > --- a/drivers/net/bonding/rte_eth_bond_pmd.c > +++ b/drivers/net/bonding/rte_eth_bond_pmd.c > @@ -1520,8 +1520,8 @@ bond_ethdev_stop(struct rte_eth_dev *eth_dev) > bond_mode_8023ad_stop(eth_dev); >=20 > /* Discard all messages to/from mode 4 state machines */ > - for (i =3D 0; i < internals->slave_count; i++) { > - port =3D &mode_8023ad_ports[internals->slaves[i].port_id]; > + for (i =3D 0; i < internals->active_slave_count; i++) { > + port =3D &mode_8023ad_ports[internals->active_slaves[i]]; >=20 > RTE_VERIFY(port->rx_ring !=3D NULL); > while (rte_ring_dequeue(port->rx_ring, &pkt) !=3D - > ENOENT) > -- > 2.1.4 Acked-by : Declan Doherty