From: "Burakov, Anatoly" <anatoly.burakov@intel.com>
To: Stephen Hemminger <stephen@networkplumber.org>,
"dev@dpdk.org" <dev@dpdk.org>
Subject: Re: [dpdk-dev] [PATCH] vfio: eventfd should be non-block and not inherited
Date: Wed, 29 Apr 2015 16:15:48 +0000 [thread overview]
Message-ID: <C6ECDF3AB251BE4894318F4E4512369780C9578A@IRSMSX109.ger.corp.intel.com> (raw)
In-Reply-To: <1430320545-16638-1-git-send-email-stephen@networkplumber.org>
> Set internal event file descriptor to be non-block and not inherited across
> exec. This prevents accidental hangs and passing in anothr thread.
>
> Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
> ---
> lib/librte_eal/linuxapp/eal/eal_pci_vfio.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/lib/librte_eal/linuxapp/eal/eal_pci_vfio.c
> b/lib/librte_eal/linuxapp/eal/eal_pci_vfio.c
> index aea1fb1..426953a 100644
> --- a/lib/librte_eal/linuxapp/eal/eal_pci_vfio.c
> +++ b/lib/librte_eal/linuxapp/eal/eal_pci_vfio.c
> @@ -294,7 +294,7 @@ pci_vfio_setup_interrupts(struct rte_pci_device
> *dev, int vfio_dev_fd)
> }
>
> /* set up an eventfd for interrupts */
> - fd = eventfd(0, 0);
> + fd = eventfd(0, EFD_NONBLOCK | EFD_CLOEXEC);
> if (fd < 0) {
> RTE_LOG(ERR, EAL, " cannot set up eventfd, "
> "error %i (%s)\n", errno,
> strerror(errno));
> --
> 2.1.4
Acked-by: Anatoly Burakov <anatoly.burakov@intel.com>
next prev parent reply other threads:[~2015-04-29 16:15 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-04-29 15:15 Stephen Hemminger
2015-04-29 16:15 ` Burakov, Anatoly [this message]
2015-05-11 15:16 ` Thomas Monjalon
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=C6ECDF3AB251BE4894318F4E4512369780C9578A@IRSMSX109.ger.corp.intel.com \
--to=anatoly.burakov@intel.com \
--cc=dev@dpdk.org \
--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).