]> git.proxmox.com Git - pve-qemu.git/blobdiff - debian/patches/extra/0009-coroutine-Rename-qemu_coroutine_inc-dec_pool_size.patch
update submodule and patches to 7.1.0
[pve-qemu.git] / debian / patches / extra / 0009-coroutine-Rename-qemu_coroutine_inc-dec_pool_size.patch
diff --git a/debian/patches/extra/0009-coroutine-Rename-qemu_coroutine_inc-dec_pool_size.patch b/debian/patches/extra/0009-coroutine-Rename-qemu_coroutine_inc-dec_pool_size.patch
deleted file mode 100644 (file)
index 9459471..0000000
+++ /dev/null
@@ -1,90 +0,0 @@
-From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
-From: Kevin Wolf <kwolf@redhat.com>
-Date: Tue, 10 May 2022 17:10:19 +0200
-Subject: [PATCH] coroutine: Rename qemu_coroutine_inc/dec_pool_size()
-
-It's true that these functions currently affect the batch size in which
-coroutines are reused (i.e. moved from the global release pool to the
-allocation pool of a specific thread), but this is a bug and will be
-fixed in a separate patch.
-
-In fact, the comment in the header file already just promises that it
-influences the pool size, so reflect this in the name of the functions.
-As a nice side effect, the shorter function name makes some line
-wrapping unnecessary.
-
-Cc: qemu-stable@nongnu.org
-Signed-off-by: Kevin Wolf <kwolf@redhat.com>
-Message-Id: <20220510151020.105528-2-kwolf@redhat.com>
-Signed-off-by: Kevin Wolf <kwolf@redhat.com>
-(cherry-picked from commit 98e3ab35054b946f7c2aba5408822532b0920b53)
-Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
----
- hw/block/virtio-blk.c    | 6 ++----
- include/qemu/coroutine.h | 6 +++---
- util/qemu-coroutine.c    | 4 ++--
- 3 files changed, 7 insertions(+), 9 deletions(-)
-
-diff --git a/hw/block/virtio-blk.c b/hw/block/virtio-blk.c
-index 540c38f829..6a1cc41877 100644
---- a/hw/block/virtio-blk.c
-+++ b/hw/block/virtio-blk.c
-@@ -1215,8 +1215,7 @@ static void virtio_blk_device_realize(DeviceState *dev, Error **errp)
-     for (i = 0; i < conf->num_queues; i++) {
-         virtio_add_queue(vdev, conf->queue_size, virtio_blk_handle_output);
-     }
--    qemu_coroutine_increase_pool_batch_size(conf->num_queues * conf->queue_size
--                                            / 2);
-+    qemu_coroutine_inc_pool_size(conf->num_queues * conf->queue_size / 2);
-     virtio_blk_data_plane_create(vdev, conf, &s->dataplane, &err);
-     if (err != NULL) {
-         error_propagate(errp, err);
-@@ -1253,8 +1252,7 @@ static void virtio_blk_device_unrealize(DeviceState *dev)
-     for (i = 0; i < conf->num_queues; i++) {
-         virtio_del_queue(vdev, i);
-     }
--    qemu_coroutine_decrease_pool_batch_size(conf->num_queues * conf->queue_size
--                                            / 2);
-+    qemu_coroutine_dec_pool_size(conf->num_queues * conf->queue_size / 2);
-     qemu_del_vm_change_state_handler(s->change);
-     blockdev_mark_auto_del(s->blk);
-     virtio_cleanup(vdev);
-diff --git a/include/qemu/coroutine.h b/include/qemu/coroutine.h
-index c828a95ee0..5b621d1295 100644
---- a/include/qemu/coroutine.h
-+++ b/include/qemu/coroutine.h
-@@ -334,12 +334,12 @@ void coroutine_fn yield_until_fd_readable(int fd);
- /**
-  * Increase coroutine pool size
-  */
--void qemu_coroutine_increase_pool_batch_size(unsigned int additional_pool_size);
-+void qemu_coroutine_inc_pool_size(unsigned int additional_pool_size);
- /**
-- * Devcrease coroutine pool size
-+ * Decrease coroutine pool size
-  */
--void qemu_coroutine_decrease_pool_batch_size(unsigned int additional_pool_size);
-+void qemu_coroutine_dec_pool_size(unsigned int additional_pool_size);
- #include "qemu/lockable.h"
-diff --git a/util/qemu-coroutine.c b/util/qemu-coroutine.c
-index f3e8300c8d..ea23929a74 100644
---- a/util/qemu-coroutine.c
-+++ b/util/qemu-coroutine.c
-@@ -212,12 +212,12 @@ AioContext *coroutine_fn qemu_coroutine_get_aio_context(Coroutine *co)
-     return co->ctx;
- }
--void qemu_coroutine_increase_pool_batch_size(unsigned int additional_pool_size)
-+void qemu_coroutine_inc_pool_size(unsigned int additional_pool_size)
- {
-     qatomic_add(&pool_batch_size, additional_pool_size);
- }
--void qemu_coroutine_decrease_pool_batch_size(unsigned int removing_pool_size)
-+void qemu_coroutine_dec_pool_size(unsigned int removing_pool_size)
- {
-     qatomic_sub(&pool_batch_size, removing_pool_size);
- }