DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH 1/2] net/bonding: free mempool used in mode6
@ 2018-04-11  4:34 xiangxia.m.yue
  2018-04-11  4:34 ` [dpdk-dev] [PATCH 2/2] net/bonding: fix typo in log comment xiangxia.m.yue
  2018-04-13 17:25 ` [dpdk-dev] [dpdk-stable] [PATCH 1/2] net/bonding: free mempool used in mode6 Ferruh Yigit
  0 siblings, 2 replies; 4+ messages in thread
From: xiangxia.m.yue @ 2018-04-11  4:34 UTC (permalink / raw)
  To: declan.doherty; +Cc: dev, Tonghao Zhang, stable

From: Tonghao Zhang <xiangxia.m.yue@gmail.com>

When creating bond device with mode6, dpdk will create
mempool for arp packets. If free the bond device and
create it with same name, there will be an error. Because
the mempool is not freed when destroying bond device.

Fixes: 06fe78b9 ("bond: add mode 6")
Fixes: ea0c20ea ("apps: use helper to create mbuf pools")
Cc: stable@dpdk.org
Signed-off-by: Tonghao Zhang <xiangxia.m.yue@gmail.com>
---
 drivers/net/bonding/rte_eth_bond_pmd.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/drivers/net/bonding/rte_eth_bond_pmd.c b/drivers/net/bonding/rte_eth_bond_pmd.c
index 9b02850..4bc2a01 100644
--- a/drivers/net/bonding/rte_eth_bond_pmd.c
+++ b/drivers/net/bonding/rte_eth_bond_pmd.c
@@ -3127,6 +3127,10 @@ struct bwg_slave {
 	eth_dev->tx_pkt_burst = NULL;
 
 	internals = eth_dev->data->dev_private;
+	/* Try to release mempool used in mode6. If the bond
+	 * device is not mode6, free the NULL is not problem.
+	 */
+	rte_mempool_free(internals->mode6.mempool);
 	rte_bitmap_free(internals->vlan_filter_bmp);
 	rte_free(internals->vlan_filter_bmpmem);
 	rte_free(eth_dev->data->dev_private);
-- 
1.8.3.1

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [dpdk-dev] [PATCH 2/2] net/bonding: fix typo in log comment
  2018-04-11  4:34 [dpdk-dev] [PATCH 1/2] net/bonding: free mempool used in mode6 xiangxia.m.yue
@ 2018-04-11  4:34 ` xiangxia.m.yue
  2018-04-13 17:25 ` [dpdk-dev] [dpdk-stable] [PATCH 1/2] net/bonding: free mempool used in mode6 Ferruh Yigit
  1 sibling, 0 replies; 4+ messages in thread
From: xiangxia.m.yue @ 2018-04-11  4:34 UTC (permalink / raw)
  To: declan.doherty; +Cc: dev, Tonghao Zhang, stable

From: Tonghao Zhang <xiangxia.m.yue@gmail.com>

Fixes: 68451eb6 ("net/bonding: call through EAL on create/free")
Cc: stable@dpdk.org
Signed-off-by: Tonghao Zhang <xiangxia.m.yue@gmail.com>
---
 drivers/net/bonding/rte_eth_bond_pmd.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/bonding/rte_eth_bond_pmd.c b/drivers/net/bonding/rte_eth_bond_pmd.c
index 4bc2a01..73331eb 100644
--- a/drivers/net/bonding/rte_eth_bond_pmd.c
+++ b/drivers/net/bonding/rte_eth_bond_pmd.c
@@ -2957,7 +2957,7 @@ struct bwg_slave {
 	/* Set mode 4 default configuration */
 	bond_mode_8023ad_setup(eth_dev, NULL);
 	if (bond_ethdev_mode_set(eth_dev, mode)) {
-		RTE_BOND_LOG(ERR, "Failed to set bonded device %d mode too %d",
+		RTE_BOND_LOG(ERR, "Failed to set bonded device %d mode to %d\n",
 				 eth_dev->data->port_id, mode);
 		goto err;
 	}
-- 
1.8.3.1

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [dpdk-dev] [dpdk-stable] [PATCH 1/2] net/bonding: free mempool used in mode6
  2018-04-11  4:34 [dpdk-dev] [PATCH 1/2] net/bonding: free mempool used in mode6 xiangxia.m.yue
  2018-04-11  4:34 ` [dpdk-dev] [PATCH 2/2] net/bonding: fix typo in log comment xiangxia.m.yue
@ 2018-04-13 17:25 ` Ferruh Yigit
  2018-04-13 17:26   ` Ferruh Yigit
  1 sibling, 1 reply; 4+ messages in thread
From: Ferruh Yigit @ 2018-04-13 17:25 UTC (permalink / raw)
  To: xiangxia.m.yue, declan.doherty; +Cc: dev, stable

On 4/11/2018 5:34 AM, xiangxia.m.yue@gmail.com wrote:
> From: Tonghao Zhang <xiangxia.m.yue@gmail.com>
> 
> When creating bond device with mode6, dpdk will create
> mempool for arp packets. If free the bond device and
> create it with same name, there will be an error. Because
> the mempool is not freed when destroying bond device.
> 
> Fixes: 06fe78b9 ("bond: add mode 6")
> Fixes: ea0c20ea ("apps: use helper to create mbuf pools")
> Cc: stable@dpdk.org
> Signed-off-by: Tonghao Zhang <xiangxia.m.yue@gmail.com>

For series,
Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [dpdk-dev] [dpdk-stable] [PATCH 1/2] net/bonding: free mempool used in mode6
  2018-04-13 17:25 ` [dpdk-dev] [dpdk-stable] [PATCH 1/2] net/bonding: free mempool used in mode6 Ferruh Yigit
@ 2018-04-13 17:26   ` Ferruh Yigit
  0 siblings, 0 replies; 4+ messages in thread
From: Ferruh Yigit @ 2018-04-13 17:26 UTC (permalink / raw)
  To: xiangxia.m.yue, declan.doherty; +Cc: dev, stable

On 4/13/2018 6:25 PM, Ferruh Yigit wrote:
> On 4/11/2018 5:34 AM, xiangxia.m.yue@gmail.com wrote:
>> From: Tonghao Zhang <xiangxia.m.yue@gmail.com>
>>
>> When creating bond device with mode6, dpdk will create
>> mempool for arp packets. If free the bond device and
>> create it with same name, there will be an error. Because
>> the mempool is not freed when destroying bond device.
>>
>> Fixes: 06fe78b9 ("bond: add mode 6")
>> Fixes: ea0c20ea ("apps: use helper to create mbuf pools")
>> Cc: stable@dpdk.org
>> Signed-off-by: Tonghao Zhang <xiangxia.m.yue@gmail.com>
> 
> For series,
> Reviewed-by: Ferruh Yigit <ferruh.yigit@intel.com>

Series applied to dpdk-next-net/master, thanks.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2018-04-13 17:26 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-04-11  4:34 [dpdk-dev] [PATCH 1/2] net/bonding: free mempool used in mode6 xiangxia.m.yue
2018-04-11  4:34 ` [dpdk-dev] [PATCH 2/2] net/bonding: fix typo in log comment xiangxia.m.yue
2018-04-13 17:25 ` [dpdk-dev] [dpdk-stable] [PATCH 1/2] net/bonding: free mempool used in mode6 Ferruh Yigit
2018-04-13 17:26   ` Ferruh Yigit

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).