Am 03.02.2025 um 19:25 hat Stefan Hajnoczi geschrieben:
> BLOCK_OP_TYPE_DATAPLANE prevents BlockDriverState from being used by
> virtio-blk/virtio-scsi with IOThread. Commit b112a65c52aa ("block:
> declare blockjobs and dataplane friends!") eliminated the main reason
> for this blocker in 2014.
> 
> Nowadays the block layer supports I/O from multiple AioContexts, so
> there is even less reason to block IOThread users. Any legitimate
> reasons related to interference would probably also apply to
> non-IOThread users.
> 
> The only remaining users are bdrv_op_unblock(BLOCK_OP_TYPE_DATAPLANE)
> calls after bdrv_op_block_all(). If we remove BLOCK_OP_TYPE_DATAPLANE
> their behavior doesn't change.
> 
> Existing bdrv_op_block_all() callers that don't explicitly unblock
> BLOCK_OP_TYPE_DATAPLANE seem to do so simply because no one bothered to
> rather than because it is necessary to keep BLOCK_OP_TYPE_DATAPLANE
> blocked.
> 
> Signed-off-by: Stefan Hajnoczi <stefa...@redhat.com>

Thanks, applied to the block branch.

I've actually had pretty much the same patch lying around for.. *checks*
five years, but never sent it because I intended it to be part of a more
general op blocker removal series. I don't think we actually rely on any
of them any more, but proving it was still hard when I tried.

One additional part my patch had is removing blk_op_is_blocked() because
it's now unused. I'll send this as a separate patch.

Kevin


Reply via email to