kvm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Michael S. Tsirkin" <mst@redhat.com>
To: Avi Kivity <avi@redhat.com>
Cc: Jan Kiszka <jan.kiszka@siemens.com>,
	Marcelo Tosatti <mtosatti@redhat.com>, kvm <kvm@vger.kernel.org>,
	Michael Tokarev <mjt@tls.msk.ru>,
	"qemu-devel@nongnu.org" <qemu-devel@nongnu.org>
Subject: Re: plan for device assignment upstream
Date: Wed, 4 Jul 2012 13:42:24 +0300	[thread overview]
Message-ID: <20120704104224.GA21704@redhat.com> (raw)
In-Reply-To: <4FF16D54.3020801@redhat.com>

On Mon, Jul 02, 2012 at 12:43:48PM +0300, Avi Kivity wrote:
> On 07/02/2012 12:30 PM, Jan Kiszka wrote:
> > On 2012-07-02 11:18, Michael S. Tsirkin wrote:
> >> I've been thinking hard about Jan's patches for device
> >> assignment. Basically while I thought it makes sense
> >> to make all devices: assignment and not - behave the
> >> same and use same APIs for injecting irqs, Anthony thinks there is huge
> >> value in making irq propagation hierarchical and device assignment
> >> should be special cased.
> > 
> > On the long term, we will need direct injection, ie. caching, to allow
> > making it lock-less. Stepping through all intermediate layers will cause
> > troubles, at least performance-wise, when having to take and drop a lock
> > at each stop.
> 
> So we precalculate everything beforehand.  Instead of each qemu_irq
> triggering a callback, calculating the next hop and firing the next
> qemu_irq, configure each qemu_irq array with a function that describes
> how to take the next hop.  Whenever the configuration changes,
> recalculate all routes.
> 
> For device assignment or vhost, we can have a qemu_irq_irqfd() which
> converts a qemu_irq to an eventfd.  If the route calculations determine
> that it can be serviced via a real irqfd, they also configure it as an
> irqfd.  Otherwise qemu configures a poll on this eventfd and calls the
> callback when needed.

This is more or less what I had in mind and what Anthony objects to.

> -- 
> error compiling committee.c: too many arguments to function
> 

  parent reply	other threads:[~2012-07-04 10:42 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-02  9:18 plan for device assignment upstream Michael S. Tsirkin
2012-07-02  9:29 ` Avi Kivity
2012-07-02  9:30 ` Jan Kiszka
2012-07-02  9:43   ` Avi Kivity
2012-07-03 19:06     ` [Qemu-devel] " Blue Swirl
2012-07-04  8:05       ` Avi Kivity
2012-07-05 18:23         ` [Qemu-devel] " Blue Swirl
2012-07-04 10:42     ` Michael S. Tsirkin [this message]
2012-07-04 11:24       ` Avi Kivity
2012-07-04 12:54         ` Michael S. Tsirkin

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=20120704104224.GA21704@redhat.com \
    --to=mst@redhat.com \
    --cc=avi@redhat.com \
    --cc=jan.kiszka@siemens.com \
    --cc=kvm@vger.kernel.org \
    --cc=mjt@tls.msk.ru \
    --cc=mtosatti@redhat.com \
    --cc=qemu-devel@nongnu.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).