qemu-block
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 1/3] block: eliminate BDRV_REQ_NO_SERIALISING


From: Kevin Wolf
Subject: Re: [PATCH 1/3] block: eliminate BDRV_REQ_NO_SERIALISING
Date: Wed, 18 Dec 2019 17:51:15 +0100
User-agent: Mutt/1.12.1 (2019-06-15)

Am 18.12.2019 um 17:43 hat Paolo Bonzini geschrieben:
> On 18/12/19 17:37, Kevin Wolf wrote:
> >>       * passthrough flags.  */
> >> -    assert(!(flags & ~(BDRV_REQ_NO_SERIALISING | BDRV_REQ_COPY_ON_READ |
> >> -                       BDRV_REQ_PREFETCH)));
> >> +    assert(!(flags & ~(BDRV_REQ_COPY_ON_READ | BDRV_REQ_PREFETCH)));
> >>  
> >>      /* Handle Copy on Read and associated serialisation */
> >>      if (flags & BDRV_REQ_COPY_ON_READ) {
> >> @@ -1458,12 +1457,7 @@ static int coroutine_fn 
> >> bdrv_aligned_preadv(BdrvChild *child,
> >>          bdrv_mark_request_serialising(req, bdrv_get_cluster_size(bs));
> >>      }
> >>  
> >> -    /* BDRV_REQ_SERIALISING is only for write operation */
> >> -    assert(!(flags & BDRV_REQ_SERIALISING));
> > I think we shoud still keep this assertion as long as read requests
> > don't mark themselves as serialising when BDRV_REQ_SERIALISING is given.
> > Otherwise, someone might add the flag to a read request and will later
> > be surprised that it didn't work.
> 
> I'm removing it because it's anyway tested by the earlier
> 
>     assert(!(flags & ~(BDRV_REQ_COPY_ON_READ | BDRV_REQ_PREFETCH)));

Ah, right. Never mind then.

Kevin




reply via email to

[Prev in Thread] Current Thread [Next in Thread]