DPDK usage discussions
 help / color / mirror / Atom feed
From: Alejandro Lucero <alejandro.lucero@netronome.com>
To: Ferruh Yigit <ferruh.yigit@intel.com>
Cc: Gregory Etelson <gregory@weka.io>, dev <dev@dpdk.org>, users@dpdk.org
Subject: Re: [dpdk-users] [dpdk-dev]  IGB_UIO: PCI Resources Management
Date: Thu, 12 Jan 2017 12:58:06 +0000	[thread overview]
Message-ID: <CAD+H992QT_dH5QrxZao9XgMEo7S9YNFgPEwc9U_LUbhHg_J89A@mail.gmail.com> (raw)
In-Reply-To: <e1507eab-1604-b300-8f86-5d5ac2c98ee5@intel.com>

On Thu, Jan 12, 2017 at 12:22 PM, Ferruh Yigit <ferruh.yigit@intel.com>
wrote:

> On 1/12/2017 12:12 PM, Alejandro Lucero wrote:
> >
> >
> > On Thu, Jan 12, 2017 at 11:55 AM, Ferruh Yigit <ferruh.yigit@intel.com
> > <mailto:ferruh.yigit@intel.com>> wrote:
> >
> >     On 12/9/2016 8:54 AM, Gregory Etelson wrote:
> >     > Hello,
> >     >
> >     > IGB_UIO driver does not close port PCI activities after DPDK
> process exits.
> >     > DPDK API provides rte_eth_dev_close() to manage port PCI,
> >     > but it can be skipped if process receives SIGKILL signal
> >
> >     I guess I understand the problem.
> >
> >
> > This is a known problem, but it is not just a UIO problem, and this
> > patch does not solve it, maybe it just solves part of it.
> >
> > In fact, a DPDK program crashing could imply the NIC DMAing after that
> > and after that memory was assigned to another program.
>
> Yes.
> Can there be a way to stop NIC DMA, (or prevent it access to mem
> anymore) when app crashes?
> I think that is what this patch is looking for.
>
>
But with the patch, it just happens when igb_uio module is removed. I guess
this is good for then loading or binding the device to another module, but
that does not solve the problem about stopping the NIC asap.

As I see it, the EAL should catch signals forcing always to close ports,
even when no signal, because it could be just the app exiting without error
but the port/NIC able to receive packets. But for SIGKILL, that would not
be enough. So we need something else for always calling a destructor before
fully exiting.



> >
> >
> >
> >
> >     > The patches below provide IGB_UIO release callback and IXGBEVF
> release function
> >
> >     But adding ixgbe specific code into igb_uio may not be good idea.
> >     Can be anything done one upper layer, pci layer, generic to all
> drivers?
> >
> >
> > This  module is not just being used for Intel cards, so this addition
> > will break, at least, the NFP PMD support.
> >
> > I was told to use igb_uio instead of adding a new NFP uio driver, so I
> > guess that implies this igb_uio driver should be considered not only a
> > igb driver.
>
> No it is generic, I think names has igb_ just for historical reasons.
>

Great.


>
> >
> >
> >     > With the patches, each time DPDK process terminates,
> >     > UIO release callback will trigger port PCI close.
> >     > On the down side, patched IGB_UIO can be bound to a single adapter
> type
> >     >
> >     > Regards,
> >     > Gregory
> >
> >     <...>
> >
> >
>
>

  reply	other threads:[~2017-01-12 12:58 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-12-09  8:54 [dpdk-users] " Gregory Etelson
2017-01-12 11:55 ` Ferruh Yigit
2017-01-12 12:12   ` [dpdk-users] [dpdk-dev] " Alejandro Lucero
2017-01-12 12:22     ` Ferruh Yigit
2017-01-12 12:58       ` Alejandro Lucero [this message]
2017-01-13  1:51       ` Tan, Jianfeng
2017-01-13  2:04         ` Ferruh Yigit
2017-01-13  5:33           ` Tan, Jianfeng
2017-01-13 11:10             ` Alejandro Lucero
2017-01-19 16:36               ` Ferruh Yigit
2017-01-19 20:33                 ` Alejandro Lucero
2017-01-19 15:59             ` Ferruh Yigit
2017-01-19 16:09               ` George Prekas
2017-01-20  5:09               ` Tan, Jianfeng

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=CAD+H992QT_dH5QrxZao9XgMEo7S9YNFgPEwc9U_LUbhHg_J89A@mail.gmail.com \
    --to=alejandro.lucero@netronome.com \
    --cc=dev@dpdk.org \
    --cc=ferruh.yigit@intel.com \
    --cc=gregory@weka.io \
    --cc=users@dpdk.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).