DPDK patches and discussions
 help / color / mirror / Atom feed
From: Chaoyong He <chaoyong.he@corigine.com>
To: Stephen Hemminger <stephen@networkplumber.org>
Cc: "dev@dpdk.org" <dev@dpdk.org>,
	oss-drivers <oss-drivers@corigine.com>,
	Long Wu <Long.Wu@nephogine.com>,
	Nole Zhang <peng.zhang@corigine.com>
Subject: RE: [PATCH 04/10] net/nfp: improve the logic readability
Date: Fri, 11 Oct 2024 02:36:44 +0000	[thread overview]
Message-ID: <SJ0PR13MB5545405329CC597B4D2894E49E792@SJ0PR13MB5545.namprd13.prod.outlook.com> (raw)
In-Reply-To: <20241010081044.2acd3bd9@hermes.local>

> On Thu, 10 Oct 2024 17:17:10 +0800
> Chaoyong He <chaoyong.he@corigine.com> wrote:
> 
> > +
> > +port_cleanup:
> > +	for (uint32_t j = 0; j < i; j++) {
> > +		struct rte_eth_dev *eth_dev;
> > +
> > +		nfp_port_name_generate(port_name, sizeof(port_name), j,
> pf_dev);
> > +		eth_dev = rte_eth_dev_get_by_name(port_name);
> > +		if (eth_dev != NULL)
> > +			rte_eth_dev_destroy(eth_dev, NULL);
> > +	}
> > +
> 
> You could skip the lookup if you kept an array of eth_dev's that were created?

Yes, it does make sense and sounds a good idea.
Maybe we can do it in a future patch rather than in this one?

Anyway, thanks for your review.

  reply	other threads:[~2024-10-11  2:36 UTC|newest]

Thread overview: 38+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-10  9:17 [PATCH 00/10] modify some logic of NFP PMD Chaoyong He
2024-10-10  9:17 ` [PATCH 01/10] net/nfp: use strlcpy for copying string Chaoyong He
2024-10-10 15:08   ` Stephen Hemminger
2024-10-10  9:17 ` [PATCH 02/10] net/nfp: fix malloc name problem in secondary process Chaoyong He
2024-10-10 15:07   ` Stephen Hemminger
2024-10-11  2:31     ` Chaoyong He
2024-10-10  9:17 ` [PATCH 03/10] net/nfp: simplify some function parameters Chaoyong He
2024-10-10 15:08   ` Stephen Hemminger
2024-10-10  9:17 ` [PATCH 04/10] net/nfp: improve the logic readability Chaoyong He
2024-10-10 15:10   ` Stephen Hemminger
2024-10-11  2:36     ` Chaoyong He [this message]
2024-10-10  9:17 ` [PATCH 05/10] net/nfp: fix problem caused by configure function Chaoyong He
2024-10-10 15:13   ` Stephen Hemminger
2024-10-10  9:17 ` [PATCH 06/10] net/nfp: add check logic for port up/down function Chaoyong He
2024-10-10 15:14   ` Stephen Hemminger
2024-10-10  9:17 ` [PATCH 07/10] net/nfp: fix problem caused by commit end function Chaoyong He
2024-10-10 15:15   ` Stephen Hemminger
2024-10-10  9:17 ` [PATCH 08/10] net/nfp: fix problem caused by FEC set Chaoyong He
2024-10-10 15:15   ` Stephen Hemminger
2024-10-10  9:17 ` [PATCH 09/10] net/nfp: modify the comment of some control messages Chaoyong He
2024-10-10 15:15   ` Stephen Hemminger
2024-10-10  9:17 ` [PATCH 10/10] net/nfp: fix memory leak in VF initialization logic Chaoyong He
2024-10-10 15:19   ` Stephen Hemminger
2024-10-11  2:38     ` Chaoyong He
2024-10-12  2:40 ` [PATCH v2 00/10] modify some logic of NFP PMD Chaoyong He
2024-10-12  2:40   ` [PATCH v2 01/10] net/nfp: use strlcpy for copying string Chaoyong He
2024-10-12  2:40   ` [PATCH v2 02/10] net/nfp: fix malloc name problem in secondary process Chaoyong He
2024-10-12  2:45     ` Stephen Hemminger
2024-10-12  2:47       ` Chaoyong He
2024-10-12  2:41   ` [PATCH v2 03/10] net/nfp: simplify some function parameters Chaoyong He
2024-10-12  2:41   ` [PATCH v2 04/10] net/nfp: improve the logic readability Chaoyong He
2024-10-12  2:41   ` [PATCH v2 05/10] net/nfp: fix problem caused by configure function Chaoyong He
2024-10-12  2:41   ` [PATCH v2 06/10] net/nfp: add check logic for port up/down function Chaoyong He
2024-10-12  2:41   ` [PATCH v2 07/10] net/nfp: fix problem caused by commit end function Chaoyong He
2024-10-12  2:41   ` [PATCH v2 08/10] net/nfp: fix problem caused by FEC set Chaoyong He
2024-10-12  2:41   ` [PATCH v2 09/10] net/nfp: modify the comment of some control messages Chaoyong He
2024-10-12  2:41   ` [PATCH v2 10/10] net/nfp: fix memory leak in VF initialization logic Chaoyong He
2024-10-13  2:49   ` [PATCH v2 00/10] modify some logic of NFP PMD Ferruh Yigit

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=SJ0PR13MB5545405329CC597B4D2894E49E792@SJ0PR13MB5545.namprd13.prod.outlook.com \
    --to=chaoyong.he@corigine.com \
    --cc=Long.Wu@nephogine.com \
    --cc=dev@dpdk.org \
    --cc=oss-drivers@corigine.com \
    --cc=peng.zhang@corigine.com \
    --cc=stephen@networkplumber.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).