DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev]  [PATCH 0/2] fixes for bnxt driver
@ 2020-09-05  9:36 wangyunjian
  2020-09-05  9:36 ` [dpdk-dev] [PATCH 1/2] net/bnxt: remove logically dead code wangyunjian
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: wangyunjian @ 2020-09-05  9:36 UTC (permalink / raw)
  To: dev; +Cc: ajit.khaparde, somnath.kotur, jerry.lilijun, xudingke, Yunjian Wang

From: Yunjian Wang <wangyunjian@huawei.com>

This series include two fixes patches for bnxt driver.

Yunjian Wang (2):
  net/bnxt: remove logically dead code
  net/bnxt: fix a wrong use of rte_free when freeing mbuf

 drivers/net/bnxt/bnxt_reps.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

-- 
2.18.1



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

* [dpdk-dev]  [PATCH 1/2] net/bnxt: remove logically dead code
  2020-09-05  9:36 [dpdk-dev] [PATCH 0/2] fixes for bnxt driver wangyunjian
@ 2020-09-05  9:36 ` wangyunjian
  2020-09-05  9:36 ` [dpdk-dev] [PATCH 2/2] net/bnxt: fix a wrong use of rte_free when freeing mbuf wangyunjian
  2020-09-11  3:22 ` [dpdk-dev] [PATCH 0/2] fixes for bnxt driver Ajit Khaparde
  2 siblings, 0 replies; 8+ messages in thread
From: wangyunjian @ 2020-09-05  9:36 UTC (permalink / raw)
  To: dev
  Cc: ajit.khaparde, somnath.kotur, jerry.lilijun, xudingke,
	Yunjian Wang, stable

From: Yunjian Wang <wangyunjian@huawei.com>

This patch removes logically dead code reported by coverity.

Coverity issue: 360824
Fixes: 6dc83230b43b ("net/bnxt: support port representor data path")
Cc: stable@dpdk.org

Signed-off-by: Yunjian Wang <wangyunjian@huawei.com>
---
 drivers/net/bnxt/bnxt_reps.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/net/bnxt/bnxt_reps.c b/drivers/net/bnxt/bnxt_reps.c
index 6fa9a30d2..e924025cf 100644
--- a/drivers/net/bnxt/bnxt_reps.c
+++ b/drivers/net/bnxt/bnxt_reps.c
@@ -44,8 +44,6 @@ bnxt_vfr_recv(uint16_t port_id, uint16_t queue_id, struct rte_mbuf *mbuf)
 	uint8_t que;
 
 	vfr_eth_dev = &rte_eth_devices[port_id];
-	if (!vfr_eth_dev)
-		return 1;
 	vfr_bp = vfr_eth_dev->data->dev_private;
 	/* If rxq_id happens to be > max rep_queue, use rxq0 */
 	que = queue_id < BNXT_MAX_VF_REP_RINGS ? queue_id : 0;
-- 
2.18.1



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

* [dpdk-dev] [PATCH 2/2] net/bnxt: fix a wrong use of rte_free when freeing mbuf
  2020-09-05  9:36 [dpdk-dev] [PATCH 0/2] fixes for bnxt driver wangyunjian
  2020-09-05  9:36 ` [dpdk-dev] [PATCH 1/2] net/bnxt: remove logically dead code wangyunjian
@ 2020-09-05  9:36 ` wangyunjian
  2020-09-11  3:22 ` [dpdk-dev] [PATCH 0/2] fixes for bnxt driver Ajit Khaparde
  2 siblings, 0 replies; 8+ messages in thread
From: wangyunjian @ 2020-09-05  9:36 UTC (permalink / raw)
  To: dev
  Cc: ajit.khaparde, somnath.kotur, jerry.lilijun, xudingke,
	Yunjian Wang, stable

From: Yunjian Wang <wangyunjian@huawei.com>

We should use rte_pktmbuf_free() instead of rte_free() to free the mbuf.

Fixes: 6dc83230b43b ("net/bnxt: support port representor data path")
Cc: stable@dpdk.org

Signed-off-by: Yunjian Wang <wangyunjian@huawei.com>
---
 drivers/net/bnxt/bnxt_reps.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/bnxt/bnxt_reps.c b/drivers/net/bnxt/bnxt_reps.c
index e924025cf..26bd0f626 100644
--- a/drivers/net/bnxt/bnxt_reps.c
+++ b/drivers/net/bnxt/bnxt_reps.c
@@ -61,7 +61,7 @@ bnxt_vfr_recv(uint16_t port_id, uint16_t queue_id, struct rte_mbuf *mbuf)
 	} else {
 		vfr_bp->rx_drop_bytes[que] += mbuf->pkt_len;
 		vfr_bp->rx_drop_pkts[que]++;
-		rte_free(mbuf); /* Representor Rx ring full, drop pkt */
+		rte_pktmbuf_free(mbuf); /* Representor Rx ring full, drop pkt */
 	}
 
 	return 0;
-- 
2.18.1



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

* Re: [dpdk-dev] [PATCH 0/2] fixes for bnxt driver
  2020-09-05  9:36 [dpdk-dev] [PATCH 0/2] fixes for bnxt driver wangyunjian
  2020-09-05  9:36 ` [dpdk-dev] [PATCH 1/2] net/bnxt: remove logically dead code wangyunjian
  2020-09-05  9:36 ` [dpdk-dev] [PATCH 2/2] net/bnxt: fix a wrong use of rte_free when freeing mbuf wangyunjian
@ 2020-09-11  3:22 ` Ajit Khaparde
  2 siblings, 0 replies; 8+ messages in thread
From: Ajit Khaparde @ 2020-09-11  3:22 UTC (permalink / raw)
  To: wangyunjian; +Cc: dpdk-dev, Lilijun (Jerry), xudingke

On Sat, Sep 5, 2020 at 2:37 AM wangyunjian <wangyunjian@huawei.com> wrote:

> From: Yunjian Wang <wangyunjian@huawei.com>
>
> This series include two fixes patches for bnxt driver.
>
Patchset applied to dpdk-next-net-brcm. Thanks


>
> Yunjian Wang (2):
>   net/bnxt: remove logically dead code
>   net/bnxt: fix a wrong use of rte_free when freeing mbuf
>
>  drivers/net/bnxt/bnxt_reps.c | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)
>
> --
> 2.18.1
>
>
>

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

* Re: [dpdk-dev] [PATCH 0/2] fixes for bnxt driver
  2020-07-31 12:08 wangyunjian
  2020-09-01  0:57 ` wangyunjian
@ 2020-09-02  3:38 ` Ajit Khaparde
  1 sibling, 0 replies; 8+ messages in thread
From: Ajit Khaparde @ 2020-09-02  3:38 UTC (permalink / raw)
  To: wangyunjian; +Cc: dpdk-dev, Somnath Kotur, Lilijun (Jerry), xudingke

On Fri, Jul 31, 2020 at 5:09 AM wangyunjian <wangyunjian@huawei.com> wrote:

> From: Yunjian Wang <wangyunjian@huawei.com>
>
> This series include two fixes patches for bnxt driver.
>
> Yunjian Wang (2):
>   net/bnxt: fix memory leak when freeing vf_info
>   net/bnxt: add memory allocation check in vf_info init
>
Patchset applied to dpdk-next-net-brcm. Thanks


>
>  drivers/net/bnxt/bnxt_ethdev.c |  3 +--
>  drivers/net/bnxt/bnxt_hwrm.c   | 22 ++++++++++++++++++++--
>  drivers/net/bnxt/bnxt_hwrm.h   |  1 +
>  3 files changed, 22 insertions(+), 4 deletions(-)
>
> --
> 2.23.0
>
>
>

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

* Re: [dpdk-dev] [PATCH 0/2] fixes for bnxt driver
  2020-09-01  0:57 ` wangyunjian
@ 2020-09-01  1:00   ` Ajit Khaparde
  0 siblings, 0 replies; 8+ messages in thread
From: Ajit Khaparde @ 2020-09-01  1:00 UTC (permalink / raw)
  To: wangyunjian; +Cc: Lilijun (Jerry), dev, somnath.kotur, xudingke

On Mon, Aug 31, 2020 at 5:58 PM wangyunjian <wangyunjian@huawei.com> wrote:

>
>
> Ping for review, please.

yes. It’s in the pipeline and will be applied in a day or two.

Thanks
Ajit


>
>
>
> > -----Original Message-----
>
> > From: wangyunjian
>
> > Sent: Friday, July 31, 2020 8:09 PM
>
> > To: dev@dpdk.org
>
> > Cc: ajit.khaparde@broadcom.com; somnath.kotur@broadcom.com; Lilijun
>
> > (Jerry) <jerry.lilijun@huawei.com>; xudingke <xudingke@huawei.com>;
>
> > wangyunjian <wangyunjian@huawei.com>
>
> > Subject: [dpdk-dev] [PATCH 0/2] fixes for bnxt driver
>
> >
>
> > From: Yunjian Wang <wangyunjian@huawei.com>
>
> >
>
> > This series include two fixes patches for bnxt driver.
>
> >
>
> > Yunjian Wang (2):
>
> >   net/bnxt: fix memory leak when freeing vf_info
>
> >   net/bnxt: add memory allocation check in vf_info init
>
> >
>
> >  drivers/net/bnxt/bnxt_ethdev.c |  3 +--
>
> >  drivers/net/bnxt/bnxt_hwrm.c   | 22 ++++++++++++++++++++--
>
> >  drivers/net/bnxt/bnxt_hwrm.h   |  1 +
>
> >  3 files changed, 22 insertions(+), 4 deletions(-)
>
> >
>
> > --
>
> > 2.23.0
>
> >
>
>
>
>

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

* Re: [dpdk-dev] [PATCH 0/2] fixes for bnxt driver
  2020-07-31 12:08 wangyunjian
@ 2020-09-01  0:57 ` wangyunjian
  2020-09-01  1:00   ` Ajit Khaparde
  2020-09-02  3:38 ` Ajit Khaparde
  1 sibling, 1 reply; 8+ messages in thread
From: wangyunjian @ 2020-09-01  0:57 UTC (permalink / raw)
  To: dev, ajit.khaparde, somnath.kotur; +Cc: Lilijun (Jerry), xudingke


Ping for review, please.

> -----Original Message-----
> From: wangyunjian
> Sent: Friday, July 31, 2020 8:09 PM
> To: dev@dpdk.org
> Cc: ajit.khaparde@broadcom.com; somnath.kotur@broadcom.com; Lilijun
> (Jerry) <jerry.lilijun@huawei.com>; xudingke <xudingke@huawei.com>;
> wangyunjian <wangyunjian@huawei.com>
> Subject: [dpdk-dev] [PATCH 0/2] fixes for bnxt driver
> 
> From: Yunjian Wang <wangyunjian@huawei.com>
> 
> This series include two fixes patches for bnxt driver.
> 
> Yunjian Wang (2):
>   net/bnxt: fix memory leak when freeing vf_info
>   net/bnxt: add memory allocation check in vf_info init
> 
>  drivers/net/bnxt/bnxt_ethdev.c |  3 +--
>  drivers/net/bnxt/bnxt_hwrm.c   | 22 ++++++++++++++++++++--
>  drivers/net/bnxt/bnxt_hwrm.h   |  1 +
>  3 files changed, 22 insertions(+), 4 deletions(-)
> 
> --
> 2.23.0
> 


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

* [dpdk-dev]  [PATCH 0/2] fixes for bnxt driver
@ 2020-07-31 12:08 wangyunjian
  2020-09-01  0:57 ` wangyunjian
  2020-09-02  3:38 ` Ajit Khaparde
  0 siblings, 2 replies; 8+ messages in thread
From: wangyunjian @ 2020-07-31 12:08 UTC (permalink / raw)
  To: dev; +Cc: ajit.khaparde, somnath.kotur, jerry.lilijun, xudingke, Yunjian Wang

From: Yunjian Wang <wangyunjian@huawei.com>

This series include two fixes patches for bnxt driver.

Yunjian Wang (2):
  net/bnxt: fix memory leak when freeing vf_info
  net/bnxt: add memory allocation check in vf_info init

 drivers/net/bnxt/bnxt_ethdev.c |  3 +--
 drivers/net/bnxt/bnxt_hwrm.c   | 22 ++++++++++++++++++++--
 drivers/net/bnxt/bnxt_hwrm.h   |  1 +
 3 files changed, 22 insertions(+), 4 deletions(-)

-- 
2.23.0



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

end of thread, other threads:[~2020-09-11  3:23 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-05  9:36 [dpdk-dev] [PATCH 0/2] fixes for bnxt driver wangyunjian
2020-09-05  9:36 ` [dpdk-dev] [PATCH 1/2] net/bnxt: remove logically dead code wangyunjian
2020-09-05  9:36 ` [dpdk-dev] [PATCH 2/2] net/bnxt: fix a wrong use of rte_free when freeing mbuf wangyunjian
2020-09-11  3:22 ` [dpdk-dev] [PATCH 0/2] fixes for bnxt driver Ajit Khaparde
  -- strict thread matches above, loose matches on Subject: below --
2020-07-31 12:08 wangyunjian
2020-09-01  0:57 ` wangyunjian
2020-09-01  1:00   ` Ajit Khaparde
2020-09-02  3:38 ` Ajit Khaparde

DPDK patches and discussions

This inbox may be cloned and mirrored by anyone:

	git clone --mirror https://inbox.dpdk.org/dev/0 dev/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 dev dev/ https://inbox.dpdk.org/dev \
		dev@dpdk.org
	public-inbox-index dev

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://inbox.dpdk.org/inbox.dpdk.dev


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git