qemu-e2k/block
Stefan Hajnoczi 076682885d block/linux-aio: convert to blk_io_plug_call() API
Stop using the .bdrv_co_io_plug() API because it is not multi-queue
block layer friendly. Use the new blk_io_plug_call() API to batch I/O
submission instead.

Note that a dev_max_batch check is dropped in laio_io_unplug() because
the semantics of unplug_fn() are different from .bdrv_co_unplug():
1. unplug_fn() is only called when the last blk_io_unplug() call occurs,
   not every time blk_io_unplug() is called.
2. unplug_fn() is per-thread, not per-BlockDriverState, so there is no
   way to get per-BlockDriverState fields like dev_max_batch.

Therefore this condition cannot be moved to laio_unplug_fn(). It is not
obvious that this condition affects performance in practice, so I am
removing it instead of trying to come up with a more complex mechanism
to preserve the condition.

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Acked-by: Kevin Wolf <kwolf@redhat.com>
Reviewed-by: Stefano Garzarella <sgarzare@redhat.com>
Message-id: 20230530180959.1108766-6-stefanha@redhat.com
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
2023-06-01 07:34:03 -04:00
..
export aio: remove aio_disable_external() API 2023-05-30 17:37:26 +02:00
monitor block/monitor: Fix crash when executing HMP commit 2023-04-25 15:11:57 +02:00
accounting.c
aio_task.c
amend.c block: Mark BlockDriver callbacks for amend job GRAPH_RDLOCK 2023-05-10 14:16:54 +02:00
backup.c Block layer patches 2023-02-24 15:09:39 +00:00
blkdebug.c blkdebug: add missing coroutine_fn annotation 2023-04-25 13:17:28 +02:00
blkio.c block/blkio: convert to blk_io_plug_call() API 2023-06-01 07:34:03 -04:00
blklogwrites.c block: Mark bdrv_co_refresh_total_sectors() and callers GRAPH_RDLOCK 2023-02-23 19:49:33 +01:00
blkreplay.c block: Mark bdrv_co_refresh_total_sectors() and callers GRAPH_RDLOCK 2023-02-23 19:49:33 +01:00
blkverify.c block: Mark bdrv_recurse_can_replace() and callers GRAPH_RDLOCK 2023-05-10 14:16:54 +02:00
block-backend.c block: add blk_io_plug_call() API 2023-06-01 07:34:03 -04:00
block-copy.c block: Mark bdrv_co_pwrite_zeroes() and callers GRAPH_RDLOCK 2023-02-23 19:49:14 +01:00
block-gen.h
block-ram-registrar.c
bochs.c block: Mark public read/write functions GRAPH_RDLOCK 2023-02-23 19:49:17 +01:00
cloop.c include/block: Untangle inclusion loops 2023-01-20 07:24:28 +01:00
commit.c blockjob: Adhere to rate limit even when reentered early 2023-05-19 19:12:12 +02:00
copy-before-write.c copy-before-write: Fix open with child in iothread 2023-05-30 17:29:35 +02:00
copy-before-write.h
copy-on-read.c block: remove has_variable_length from filters 2023-04-11 16:38:56 +02:00
copy-on-read.h
coroutines.h nbd: Mark nbd_co_do_establish_connection() and callers GRAPH_RDLOCK 2023-05-10 14:16:53 +02:00
create.c block: Call .bdrv_co_create(_opts) unlocked 2023-05-19 19:12:12 +02:00
crypto.c block: Call .bdrv_co_create(_opts) unlocked 2023-05-19 19:12:12 +02:00
crypto.h
curl.c aio: remove aio_disable_external() API 2023-05-30 17:37:26 +02:00
dirty-bitmap.c block: Mark bdrv_*_dirty_bitmap() and callers GRAPH_RDLOCK 2023-02-23 19:49:32 +01:00
dmg-bz2.c
dmg-lzfse.c block/dmg: Ignore C99 prototype declaration mismatch from <lzfse.h> 2023-03-30 15:03:36 +02:00
dmg.c block/dmg: Declare a type definition for DMG uncompress function 2023-04-24 13:53:44 -04:00
dmg.h block/dmg: Declare a type definition for DMG uncompress function 2023-04-24 13:53:44 -04:00
file-posix.c block/linux-aio: convert to blk_io_plug_call() API 2023-06-01 07:34:03 -04:00
file-win32.c thread-pool: avoid passing the pool parameter every time 2023-04-25 13:17:28 +02:00
filter-compress.c block: remove has_variable_length from filters 2023-04-11 16:38:56 +02:00
gluster.c block: Convert bdrv_get_allocated_file_size() to co_wrapper 2023-02-01 16:52:32 +01:00
graph-lock.c graph-lock: Disable locking for now 2023-05-19 19:16:53 +02:00
io_uring.c block/io_uring: convert to blk_io_plug_call() API 2023-06-01 07:34:03 -04:00
io.c aio: remove aio_disable_external() API 2023-05-30 17:37:26 +02:00
iscsi-opts.c
iscsi.c aio: remove aio_disable_external() API 2023-05-30 17:37:26 +02:00
linux-aio.c block/linux-aio: convert to blk_io_plug_call() API 2023-06-01 07:34:03 -04:00
meson.build block: add blk_io_plug_call() API 2023-06-01 07:34:03 -04:00
mirror.c mirror: Hold main AioContext lock for calling bdrv_open_backing_file() 2023-05-30 17:21:23 +02:00
nbd.c nbd: Mark nbd_co_do_establish_connection() and callers GRAPH_RDLOCK 2023-05-10 14:16:53 +02:00
nfs.c aio: remove aio_disable_external() API 2023-05-30 17:37:26 +02:00
null.c block: Convert bdrv_get_allocated_file_size() to co_wrapper 2023-02-01 16:52:32 +01:00
nvme.c block/nvme: convert to blk_io_plug_call() API 2023-06-01 07:34:03 -04:00
parallels-ext.c include/block: Untangle inclusion loops 2023-01-20 07:24:28 +01:00
parallels.c block: Call .bdrv_co_create(_opts) unlocked 2023-05-19 19:12:12 +02:00
parallels.h
plug.c block: add blk_io_plug_call() API 2023-06-01 07:34:03 -04:00
preallocate.c block: remove has_variable_length from filters 2023-04-11 16:38:56 +02:00
progress_meter.c coroutine: Clean up superfluous inclusion of qemu/lockable.h 2023-01-19 10:18:28 +01:00
qapi-sysemu.c block: Take main AioContext lock when calling bdrv_open() 2023-05-30 17:21:23 +02:00
qapi.c block: add accounting for zone append operation 2023-05-15 08:18:10 -04:00
qcow2-bitmap.c qcow2: mark various functions as coroutine_fn and GRAPH_RDLOCK 2023-04-25 13:17:28 +02:00
qcow2-cache.c include/block: Untangle inclusion loops 2023-01-20 07:24:28 +01:00
qcow2-cluster.c qcow2: mark various functions as coroutine_fn and GRAPH_RDLOCK 2023-04-25 13:17:28 +02:00
qcow2-refcount.c qcow2: Don't call bdrv_getlength() in coroutine_fns 2023-05-10 14:16:53 +02:00
qcow2-snapshot.c qcow2: mark various functions as coroutine_fn and GRAPH_RDLOCK 2023-04-25 13:17:28 +02:00
qcow2-threads.c thread-pool: avoid passing the pool parameter every time 2023-04-25 13:17:28 +02:00
qcow2.c qcow2: Fix open with 'file' in iothread 2023-05-30 17:21:23 +02:00
qcow2.h qcow2: Don't call bdrv_getlength() in coroutine_fns 2023-05-10 14:16:53 +02:00
qcow.c block: Call .bdrv_co_create(_opts) unlocked 2023-05-19 19:12:12 +02:00
qed-check.c block: Mark bdrv_co_flush() and callers GRAPH_RDLOCK 2023-02-23 19:49:12 +01:00
qed-cluster.c
qed-l2-cache.c
qed-table.c block: Mark public read/write functions GRAPH_RDLOCK 2023-02-23 19:49:17 +01:00
qed.c block: Call .bdrv_co_create(_opts) unlocked 2023-05-19 19:12:12 +02:00
qed.h block: Mark public read/write functions GRAPH_RDLOCK 2023-02-23 19:49:17 +01:00
quorum.c block: Mark bdrv_recurse_can_replace() and callers GRAPH_RDLOCK 2023-05-10 14:16:54 +02:00
raw-format.c raw-format: Fix open with 'file' in iothread 2023-05-30 17:21:23 +02:00
rbd.c block/rbd: Add support for layered encryption 2023-02-23 19:49:35 +01:00
replication.c block: remove has_variable_length from filters 2023-04-11 16:38:56 +02:00
reqlist.c
snapshot-access.c block: Mark preadv_snapshot/snapshot_block_status GRAPH_RDLOCK 2023-02-23 19:49:21 +01:00
snapshot.c
ssh.c aio: remove aio_disable_external() API 2023-05-30 17:37:26 +02:00
stream.c blockjob: Adhere to rate limit even when reentered early 2023-05-19 19:12:12 +02:00
throttle-groups.c
throttle.c block: Mark bdrv_co_refresh_total_sectors() and callers GRAPH_RDLOCK 2023-02-23 19:49:33 +01:00
trace-events block/io_uring: convert to blk_io_plug_call() API 2023-06-01 07:34:03 -04:00
trace.h
vdi.c block: Call .bdrv_co_create(_opts) unlocked 2023-05-19 19:12:12 +02:00
vhdx-endian.c
vhdx-log.c block/vhdx: fix dynamic VHDX BAT corruption 2023-04-11 13:53:03 +02:00
vhdx.c block: Call .bdrv_co_create(_opts) unlocked 2023-05-19 19:12:12 +02:00
vhdx.h
vmdk.c block: Call .bdrv_co_create(_opts) unlocked 2023-05-19 19:12:12 +02:00
vpc.c block: Call .bdrv_co_create(_opts) unlocked 2023-05-19 19:12:12 +02:00
vvfat.c vvfat: mark various functions as coroutine_fn 2023-04-25 13:17:28 +02:00
win32-aio.c aio: remove aio_disable_external() API 2023-05-30 17:37:26 +02:00
write-threshold.c include/block: Untangle inclusion loops 2023-01-20 07:24:28 +01:00