[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-block] [Qemu-devel] [PATCH] blk: fix aio context loss on media
From: |
Fam Zheng |
Subject: |
Re: [Qemu-block] [Qemu-devel] [PATCH] blk: fix aio context loss on media change |
Date: |
Wed, 15 Mar 2017 22:42:59 +0800 |
User-agent: |
Mutt/1.7.1 (2016-10-04) |
On Wed, 03/15 17:04, Vladimir Sementsov-Ogievskiy wrote:
> 15.03.2017 16:13, Fam Zheng wrote:
> > On Wed, 03/15 13:06, Kevin Wolf wrote:
> > > > > Stefan, Paolo, do you remember the details why we didn't even do a
> > > > > simple fix like the one below? I think there were some patches on the
> > > > > list, no?
> > > > ISTM the concern was mostly "what about other BB in the graph?"
> > > >
> > > > Should the new op blocker API be used in this one (a new type of perm)?
> > > If we know what operation to block, that's an option. Would "change the
> > > node's AioContext" work for it?
>
> we can start with empty cdrom, so there is no context at start
Practically, I agree this patch is fine for now because callers don't
arbitrarily move BDS from one context to another, only a small set of operations
exists - start/stop data plane, block job callbacks. The problem is that new
code in the future can cause trouble if different BBs in the same graph don't
agree on what context they can run on, especially with dynamical
reconfiguration. So the previous discussions were more about an API that works
generally.
>
> > >
> > > I think it would effectively mean that you need to attach the device
> > > first and then jobs etc. respect the AioContext, whereas the opposite
> > > order breaks because they don't have callbacks to adjust the AioContext
> > > after the fact.
> > >
> > > This seems to match what's actually safe, so it might really be as easy
> > > as this.
> > Yes, this sounds good to me.
> >
> > Vladimir, would you like to implement this? It would be good to have this
> > fixed
> > in 2.9.
>
> I don't sure about how to do it, so, I don't mind someone else to implement
> this..
OK, I can take a look at this tomorrow.
Fam
Re: [Qemu-block] [PATCH] blk: fix aio context loss on media change, Paolo Bonzini, 2017/03/15
- Re: [Qemu-block] [PATCH] blk: fix aio context loss on media change, Kevin Wolf, 2017/03/15
- Re: [Qemu-block] [PATCH] blk: fix aio context loss on media change, Paolo Bonzini, 2017/03/15
- Re: [Qemu-block] [PATCH] blk: fix aio context loss on media change, Kevin Wolf, 2017/03/15
- Re: [Qemu-block] [PATCH] blk: fix aio context loss on media change, Paolo Bonzini, 2017/03/15
- Re: [Qemu-block] [PATCH] blk: fix aio context loss on media change, Kevin Wolf, 2017/03/15