From: Rusty Russell <rusty@rustcorp.com.au>
To: "Michael S. Tsirkin" <mst@redhat.com>
Cc: virtualization@lists.linux-foundation.org, kvm@vger.kernel.org
Subject: Re: virtio: imply disable_cb on callbacks
Date: Wed, 19 May 2010 14:07:34 +0930 [thread overview]
Message-ID: <201005191407.34607.rusty@rustcorp.com.au> (raw)
In-Reply-To: <20100518113316.GA26757@redhat.com>
On Tue, 18 May 2010 09:03:17 pm Michael S. Tsirkin wrote:
> Rusty, the patch "virtio: imply disable_cb on callbacks" is on your tree.
> I'd like to figure out how it works: for example:
>
> diff --git a/drivers/block/virtio_blk.c b/drivers/block/virtio_blk.c
> --- a/drivers/block/virtio_blk.c
> +++ b/drivers/block/virtio_blk.c
> @@ -69,6 +69,8 @@ static void blk_done(struct virtqueue *v
> /* In case queue is stopped waiting for more buffers. */
> blk_start_queue(vblk->disk->queue);
> spin_unlock_irqrestore(&vblk->lock, flags);
> +
> + vq->vq_ops->enable_cb(vq);
> }
>
> static bool do_req(struct request_queue *q, struct virtio_blk *vblk,
>
>
> Since this does not check the return status from enable_cb,
> it seems we could loose an interrupt if it arrives
> between poll and callback enable?
It's been quite a while since I wrote this patch, and never really liked it
enough to polish it.
We would need to enable this *before* reading the queue, AFAICT.
I'll remove it from my series; it's in the wilderness area already :)
Thanks!
Rusty.
next prev parent reply other threads:[~2010-05-19 4:37 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-05-18 11:33 virtio: imply disable_cb on callbacks Michael S. Tsirkin
2010-05-19 4:37 ` Rusty Russell
2010-05-19 4:37 ` Rusty Russell [this message]
-- strict thread matches above, loose matches on Subject: below --
2010-05-18 11:33 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=201005191407.34607.rusty@rustcorp.com.au \
--to=rusty@rustcorp.com.au \
--cc=kvm@vger.kernel.org \
--cc=mst@redhat.com \
--cc=virtualization@lists.linux-foundation.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.