[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-block] [PATCH 4/4] virtio-blk: Clean up start/stop with mutex
From: |
Cornelia Huck |
Subject: |
Re: [Qemu-block] [PATCH 4/4] virtio-blk: Clean up start/stop with mutex and BH |
Date: |
Thu, 24 Mar 2016 09:32:30 +0100 |
On Thu, 24 Mar 2016 16:19:41 +0800
tu bo <address@hidden> wrote:
> Hi Christian:
>
> On 03/23/2016 05:12 PM, Christian Borntraeger wrote:
> > On 03/23/2016 10:08 AM, Paolo Bonzini wrote:
> >>
> >>
> >> On 23/03/2016 09:10, Cornelia Huck wrote:
> >>>> - /* Kick right away to begin processing requests already in vring */
> >>>> - event_notifier_set(virtio_queue_get_host_notifier(s->vq));
> >>>> + vblk->dataplane_started = true;
> >>>>
> >>>> - /* Get this show started by hooking up our callbacks */
> >>>> + /* Get this show started by hooking up our callbacks. */
> >>>> aio_context_acquire(s->ctx);
> >>>> virtio_queue_aio_set_host_notifier_handler(s->vq, s->ctx, true,
> >>>> true);
> >>>> aio_context_release(s->ctx);
> >>>> + atomic_dec(&s->starting);
> >>>> +
> >>>> + /* Kick right away to begin processing requests already in vring */
> >>>> + event_notifier_set(virtio_queue_get_host_notifier(s->vq));
> >>>
> >>> I'm wondering whether moving this event_notifier_set() masks something?
> >>> IOW, may we run into trouble if the event notifier is set from some
> >>> other path before the callbacks are set up properly?
> >>
> >> The reentrancy check should catch that... But:
> >>
> >> 1) the patch really makes no difference, your fix is enough for me
> >
> >
> > Tu Bo, can you test with master + Cornelias 6 refactoring patches and
> > nothing on top?
>
> With qemu master + Cornelia's 6 refactoring patches and nothing on top,
> I did NOT see crash so far.
Cool, thanks for testing!
I'll re-send my patches with some added interface doc in patch 1. Stay
tuned.
- [Qemu-block] [PATCH 2/4] block-backend: Introduce blk_drained_begin/end, (continued)
- [Qemu-block] [PATCH 2/4] block-backend: Introduce blk_drained_begin/end, Fam Zheng, 2016/03/16
- [Qemu-block] [PATCH 4/4] virtio-blk: Clean up start/stop with mutex and BH, Fam Zheng, 2016/03/16
- Re: [Qemu-block] [PATCH 4/4] virtio-blk: Clean up start/stop with mutex and BH, Stefan Hajnoczi, 2016/03/17
- Re: [Qemu-block] [PATCH 4/4] virtio-blk: Clean up start/stop with mutex and BH, Paolo Bonzini, 2016/03/17
- Re: [Qemu-block] [PATCH 4/4] virtio-blk: Clean up start/stop with mutex and BH, Fam Zheng, 2016/03/22
- Re: [Qemu-block] [PATCH 4/4] virtio-blk: Clean up start/stop with mutex and BH, Paolo Bonzini, 2016/03/22
- Re: [Qemu-block] [PATCH 4/4] virtio-blk: Clean up start/stop with mutex and BH, Cornelia Huck, 2016/03/23
- Re: [Qemu-block] [PATCH 4/4] virtio-blk: Clean up start/stop with mutex and BH, Paolo Bonzini, 2016/03/23
- Re: [Qemu-block] [PATCH 4/4] virtio-blk: Clean up start/stop with mutex and BH, Christian Borntraeger, 2016/03/23
- Re: [Qemu-block] [PATCH 4/4] virtio-blk: Clean up start/stop with mutex and BH, tu bo, 2016/03/24
- Re: [Qemu-block] [PATCH 4/4] virtio-blk: Clean up start/stop with mutex and BH,
Cornelia Huck <=
- Re: [Qemu-block] [PATCH 4/4] virtio-blk: Clean up start/stop with mutex and BH, Cornelia Huck, 2016/03/24
- Re: [Qemu-block] [PATCH 4/4] virtio-blk: Clean up start/stop with mutex and BH, Cornelia Huck, 2016/03/24
Re: [Qemu-block] [PATCH 0/4] Tweaks around virtio-blk start/stop, Paolo Bonzini, 2016/03/16
- Re: [Qemu-block] [PATCH 0/4] Tweaks around virtio-blk start/stop, Christian Borntraeger, 2016/03/16
- Re: [Qemu-block] [PATCH 0/4] Tweaks around virtio-blk start/stop, Paolo Bonzini, 2016/03/16
- Re: [Qemu-block] [PATCH 0/4] Tweaks around virtio-blk start/stop, Christian Borntraeger, 2016/03/16
- Re: [Qemu-block] [PATCH 0/4] Tweaks around virtio-blk start/stop, Paolo Bonzini, 2016/03/16
- Re: [Qemu-block] [PATCH 0/4] Tweaks around virtio-blk start/stop, Christian Borntraeger, 2016/03/16
- Re: [Qemu-block] [PATCH 0/4] Tweaks around virtio-blk start/stop, Paolo Bonzini, 2016/03/16
- Re: [Qemu-block] [PATCH 0/4] Tweaks around virtio-blk start/stop, Fam Zheng, 2016/03/16