Re: [PATCH 1/6] block: don't acquire AioContext lock in bdrv_drain_all()

2023-03-09 Thread Stefan Hajnoczi
On Wed, Mar 08, 2023 at 06:25:43PM +0100, Kevin Wolf wrote: > Am 08.03.2023 um 15:26 hat Stefan Hajnoczi geschrieben: > > On Wed, Mar 08, 2023 at 09:48:17AM +0100, Kevin Wolf wrote: > > > Am 07.03.2023 um 20:20 hat Stefan Hajnoczi geschrieben: > > > > On Tue, Mar 07, 2023 at 06:17:22PM +0100, Kevin

Re: [PATCH 1/6] block: don't acquire AioContext lock in bdrv_drain_all()

2023-03-08 Thread Kevin Wolf
Am 08.03.2023 um 15:26 hat Stefan Hajnoczi geschrieben: > On Wed, Mar 08, 2023 at 09:48:17AM +0100, Kevin Wolf wrote: > > Am 07.03.2023 um 20:20 hat Stefan Hajnoczi geschrieben: > > > On Tue, Mar 07, 2023 at 06:17:22PM +0100, Kevin Wolf wrote: > > > > Am 01.03.2023 um 21:57 hat Stefan Hajnoczi gesc

Re: [PATCH 1/6] block: don't acquire AioContext lock in bdrv_drain_all()

2023-03-08 Thread Stefan Hajnoczi
On Wed, Mar 08, 2023 at 09:48:17AM +0100, Kevin Wolf wrote: > Am 07.03.2023 um 20:20 hat Stefan Hajnoczi geschrieben: > > On Tue, Mar 07, 2023 at 06:17:22PM +0100, Kevin Wolf wrote: > > > Am 01.03.2023 um 21:57 hat Stefan Hajnoczi geschrieben: > > > > There is no need for the AioContext lock in bdr

Re: [PATCH 1/6] block: don't acquire AioContext lock in bdrv_drain_all()

2023-03-08 Thread Kevin Wolf
Am 07.03.2023 um 20:20 hat Stefan Hajnoczi geschrieben: > On Tue, Mar 07, 2023 at 06:17:22PM +0100, Kevin Wolf wrote: > > Am 01.03.2023 um 21:57 hat Stefan Hajnoczi geschrieben: > > > There is no need for the AioContext lock in bdrv_drain_all() because > > > nothing in AIO_WAIT_WHILE() needs the lo

Re: [PATCH 1/6] block: don't acquire AioContext lock in bdrv_drain_all()

2023-03-07 Thread Stefan Hajnoczi
On Tue, Mar 07, 2023 at 06:17:22PM +0100, Kevin Wolf wrote: > Am 01.03.2023 um 21:57 hat Stefan Hajnoczi geschrieben: > > There is no need for the AioContext lock in bdrv_drain_all() because > > nothing in AIO_WAIT_WHILE() needs the lock and the condition is atomic. > > > > Note that the NULL AioC

Re: [PATCH 1/6] block: don't acquire AioContext lock in bdrv_drain_all()

2023-03-07 Thread Kevin Wolf
Am 01.03.2023 um 21:57 hat Stefan Hajnoczi geschrieben: > There is no need for the AioContext lock in bdrv_drain_all() because > nothing in AIO_WAIT_WHILE() needs the lock and the condition is atomic. > > Note that the NULL AioContext argument to AIO_WAIT_WHILE() is odd. In > the future it can be

[PATCH 1/6] block: don't acquire AioContext lock in bdrv_drain_all()

2023-03-01 Thread Stefan Hajnoczi
There is no need for the AioContext lock in bdrv_drain_all() because nothing in AIO_WAIT_WHILE() needs the lock and the condition is atomic. Note that the NULL AioContext argument to AIO_WAIT_WHILE() is odd. In the future it can be removed. There is an assertion in AIO_WAIT_WHILE() that checks tha