On 11/10/2016 00:51, John Snow wrote: >> Clearing the bitmap is a bug because the caller could expect that the >> bitmap is in its original state if the transaction fails. I doubt this >> is a problem in practice, but we should fix it anyway. > > We make a backup to undo the process if it fails. I only mention it to > emphasize that the atomic point appears to be during prepare. In > practice we hold the locks for the whole process, but... I think Paolo > may be actively trying to change that.
Even now, atomicity must be ensured with bdrv_drained_begin/end. The AioContext lock does not promise atomicity. Paolo