All of lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Monjalon <thomas@monjalon.net>
To: "lihuisong (C)" <lihuisong@huawei.com>
Cc: dev@dpdk.org, ferruh.yigit@intel.com, david.marchand@redhat.com
Subject: Re: [dpdk-dev] [RFC V1] examples/l3fwd-power: fix memory leak for rte_pci_device
Date: Fri, 08 Oct 2021 08:29:18 +0200	[thread overview]
Message-ID: <1954053.uMmENRcsHf@thomas> (raw)
In-Reply-To: <19202698-59ac-d920-2635-851e2e89694e@huawei.com>

08/10/2021 08:26, lihuisong (C):
> As you mentioned, if we do not want the user to free rte_pci_device and 
> we want rte_pci_device
> to be freed in time. Can we add a code logic calculating the number of 
> ports under a PCI address
> and calling rte_dev_remove() in rte_eth_dev_close() to free 
> rte_pci_device and delete it from rte_pci_bus?

Yes that's the idea.
But it cannot be done in ethdev lib,
it should be the responsibility of the driver.
Only the driver knows exactly what to free.



      reply	other threads:[~2021-10-08  6:29 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-07  3:41 [dpdk-dev] [RFC V1] examples/l3fwd-power: fix memory leak for rte_pci_device Huisong Li
2021-09-07  8:53 ` Thomas Monjalon
2021-09-08  2:01   ` Huisong Li
2021-09-08  7:20     ` Thomas Monjalon
2021-09-16  8:01       ` Huisong Li
2021-09-16 10:36         ` Thomas Monjalon
2021-09-17  2:13           ` Huisong Li
2021-09-17 12:50             ` Thomas Monjalon
2021-09-18  3:24               ` Huisong Li
2021-09-18  8:46                 ` Thomas Monjalon
2021-09-26 12:20                   ` Huisong Li
2021-09-26 19:16                     ` Thomas Monjalon
2021-09-27  1:44                       ` Huisong Li
2021-09-30  6:28                         ` Huisong Li
2021-09-30  7:50                           ` Thomas Monjalon
2021-10-08  6:26                             ` lihuisong (C)
2021-10-08  6:29                               ` Thomas Monjalon [this message]

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=1954053.uMmENRcsHf@thomas \
    --to=thomas@monjalon.net \
    --cc=david.marchand@redhat.com \
    --cc=dev@dpdk.org \
    --cc=ferruh.yigit@intel.com \
    --cc=lihuisong@huawei.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.