public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: "Michael S. Tsirkin" <mst@redhat.com>
To: Gregory Haskins <ghaskins@novell.com>
Cc: kvm@vger.kernel.org, linux-kernel@vger.kernel.org,
	avi@redhat.com, davidel@xmailserver.org,
	paulmck@linux.vnet.ibm.com
Subject: Re: [KVM-RFC PATCH 0/2] irqfd: use POLLHUP notification for close()
Date: Tue, 2 Jun 2009 19:20:21 +0300	[thread overview]
Message-ID: <20090602162021.GB6827@redhat.com> (raw)
In-Reply-To: <4A254FD7.5090302@novell.com>

On Tue, Jun 02, 2009 at 12:14:15PM -0400, Gregory Haskins wrote:
> Michael S. Tsirkin wrote:
> > On Tue, Jun 02, 2009 at 11:15:28AM -0400, Gregory Haskins wrote:
> >   
> >> (Applies to kvm.git/master:25deed73)
> >>
> >> Please see the header for 2/2 for a description.  This patch series has
> >> been fully tested and appears to be working correctly.  I have it as an RFC
> >> for now because it needs Davide's official submission/SOB for patch 1/2, and
> >> it should get some eyeballs/acks on my SRCU usage before going in.
> >>
> >> I will submit the updated irqfd userspace which eschews the deassign() verb
> >> since we can now just use the close(fd) method alone.  I will also address
> >> the userspace review comments from Avi.
> >>     
> >
> >
> > We are not killing the deassign though, do we?
> >   
> 
> Yes, it is not needed any more now that we have proper
> release-notification from eventfd.
> 
> > It's good to have that option e.g. for when we pass
> > the fd to another process.
> >   
> 
> Passing the fd to another app should up the underlying file reference
> count.  If the producer app wants to "deassign" it simply calls
> close(fd) (as opposed to today where it calls DEASSIGN+close), but the
> reference count will allow the consuming app to leave the eventfd's file
> open.  Or am I misunderstanding you?
> 
> -Greg
> 
> 

I think we want to keep supporting the deassign ioctl. This, even though
close overlaps with it functionally somewhat.

This allows qemu to pass eventfd to another process/device, and then
block/unblock interrupts as seen by that process by
assigning/deassigning irq to it. This is much easier and lightweight
than asking another process to close the fd and passing another fd
later.

-- 
MST

  reply	other threads:[~2009-06-02 16:21 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-06-02 15:15 [KVM-RFC PATCH 0/2] irqfd: use POLLHUP notification for close() Gregory Haskins
2009-06-02 15:15 ` [KVM-RFC PATCH 1/2] eventfd: send POLLHUP on f_ops->release Gregory Haskins
2009-06-02 15:15 ` [KVM-RFC PATCH 2/2] kvm: use POLLHUP to close an irqfd instead of an explicit ioctl Gregory Haskins
2009-06-02 17:16   ` Davide Libenzi
2009-06-02 17:42     ` Gregory Haskins
2009-06-02 18:02   ` Paul E. McKenney
2009-06-02 18:23     ` Gregory Haskins
2009-06-02 22:01       ` Paul E. McKenney
2009-06-03  1:53         ` Gregory Haskins
2009-06-03 15:04           ` Paul E. McKenney
2009-06-03 17:27             ` Gregory Haskins
2009-06-03 17:24               ` Davide Libenzi
2009-06-02 16:04 ` [KVM-RFC PATCH 0/2] irqfd: use POLLHUP notification for close() Michael S. Tsirkin
2009-06-02 16:14   ` Gregory Haskins
2009-06-02 16:20     ` Michael S. Tsirkin [this message]
2009-06-02 16:34       ` Gregory Haskins
2009-06-02 16:59         ` Michael S. Tsirkin
2009-06-02 17:02           ` Michael S. Tsirkin
2009-06-02 17:41           ` Gregory Haskins
2009-06-03  6:39             ` Michael S. Tsirkin
2009-06-03 11:34               ` Gregory Haskins
2009-06-04 10:25               ` Avi Kivity
2009-06-04 11:43                 ` Gregory Haskins
2009-06-04 11:50                   ` Avi Kivity
2009-06-04 11:52                     ` Gregory Haskins
2009-06-04 12:02                       ` Avi Kivity

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=20090602162021.GB6827@redhat.com \
    --to=mst@redhat.com \
    --cc=avi@redhat.com \
    --cc=davidel@xmailserver.org \
    --cc=ghaskins@novell.com \
    --cc=kvm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=paulmck@linux.vnet.ibm.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox