From: Gregory Haskins <ghaskins@novell.com>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: davidel@xmailserver.org, linux-kernel@vger.kernel.org
Subject: Re: [patch] epoll - send POLLHUP on ->release
Date: Wed, 03 Jun 2009 15:53:48 -0400 [thread overview]
Message-ID: <4A26D4CC.4040504@novell.com> (raw)
In-Reply-To: <20090603122739.c53b1d1f.akpm@linux-foundation.org>
[-- Attachment #1: Type: text/plain, Size: 2115 bytes --]
Andrew Morton wrote:
> On Wed, 03 Jun 2009 15:20:26 -0400
> Gregory Haskins <ghaskins@novell.com> wrote:
>
>
>> Davide Libenzi wrote:
>>
>>> The following patch allows waiters to be notified about the eventfd file*
>>> going away, and give them a change to unregister from the wait queue.
>>> This is turn allows eventfd users to use the eventfd file* w/out
>>> holding a live reference to it.
>>> After the eventfd user callbacks returns, any usage of the eventfd file*
>>> should be dropped. The eventfd user callback can acquire sleepy locks
>>> since it is invoked lockless.
>>>
>>>
>>>
>>> Signed-off-by: Davide Libenzi <davidel@xmailserver.org>
>>>
>>>
>> Tested-by: Gregory Haskins <ghaskins@novell.com>
>>
>
> Confused. Did you test this with some new kernel patch, or with some
> existing kernel code?
>
>
Hi Andrew,
Davide created this patch in response to a problem we were trying to
solve in kvm.git. I took this patch in question, and combined it with a
proposed patch for KVM and tested it out. You can find the thread here:
http://lkml.org/lkml/2009/6/2/276
I built a test harness and verified that calling close() on an eventfd
does indeed generate a POLLHUP wakeup, and that my code properly cleans
up when it gets the POLLHUP
Acceptance of my kvm optimization is predicated on Davide's patch going
in first, so I asked him to submit it formally. I figured I should
chime in my findings in case it matters for upstream acceptance.
(Apologies if this is not the normal/acceptable "tested-by"
protocol...tested-by tag noob here ;)
> If the latter, what code are we talking about here and what was the test
> case and what went wrong when using the current mainline
> implementation?
>
>
Its not what went wrong per se. Its more of a case of eliminating the
need for an awkward work-around I had to do when eventfd didn't provide
a release notification. You can find the details in my patch 2/2
header, available here for your convenience:
http://lkml.org/lkml/2009/6/2/278
Regards,
-Greg
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 266 bytes --]
prev parent reply other threads:[~2009-06-03 19:54 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-06-03 19:00 [patch] epoll - send POLLHUP on ->release Davide Libenzi
2009-06-03 19:20 ` Gregory Haskins
2009-06-03 19:27 ` Andrew Morton
2009-06-03 19:47 ` Davide Libenzi
2009-06-03 19:53 ` Gregory Haskins [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=4A26D4CC.4040504@novell.com \
--to=ghaskins@novell.com \
--cc=akpm@linux-foundation.org \
--cc=davidel@xmailserver.org \
--cc=linux-kernel@vger.kernel.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