]> rtime.felk.cvut.cz Git - lisovros/qemu_apohw.git/commitdiff
coroutine: drop qemu_coroutine_adjust_pool_size
authorPaolo Bonzini <pbonzini@redhat.com>
Tue, 2 Dec 2014 11:05:49 +0000 (12:05 +0100)
committerStefan Hajnoczi <stefanha@redhat.com>
Tue, 13 Jan 2015 13:43:29 +0000 (13:43 +0000)
This is not needed anymore.  The new TLS-based algorithm is adaptive.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Fam Zheng <famz@redhat.com>
Message-id: 1417518350-6167-7-git-send-email-pbonzini@redhat.com
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
block/block-backend.c
include/block/coroutine.h
qemu-coroutine.c

index ef16d7356a87fb433390d2e9f539ebda637782a4..d00c129f15c848febf9f6ac7c54420e763efd3ef 100644 (file)
@@ -260,9 +260,6 @@ int blk_attach_dev(BlockBackend *blk, void *dev)
     blk_ref(blk);
     blk->dev = dev;
     bdrv_iostatus_reset(blk->bs);
-
-    /* We're expecting I/O from the device so bump up coroutine pool size */
-    qemu_coroutine_adjust_pool_size(COROUTINE_POOL_RESERVATION);
     return 0;
 }
 
@@ -290,7 +287,6 @@ void blk_detach_dev(BlockBackend *blk, void *dev)
     blk->dev_ops = NULL;
     blk->dev_opaque = NULL;
     bdrv_set_guest_block_size(blk->bs, 512);
-    qemu_coroutine_adjust_pool_size(-COROUTINE_POOL_RESERVATION);
     blk_unref(blk);
 }
 
index 793df0ef8bdffe20e262df3a3b04f328bfaaac9e..20c027a7fd0f7c60765276a525b417bc133c4ba6 100644 (file)
@@ -216,14 +216,4 @@ void coroutine_fn co_aio_sleep_ns(AioContext *ctx, QEMUClockType type,
  */
 void coroutine_fn yield_until_fd_readable(int fd);
 
-/**
- * Add or subtract from the coroutine pool size
- *
- * The coroutine implementation keeps a pool of coroutines to be reused by
- * qemu_coroutine_create().  This makes coroutine creation cheap.  Heavy
- * coroutine users should call this to reserve pool space.  Call it again with
- * a negative number to release pool space.
- */
-void qemu_coroutine_adjust_pool_size(int n);
-
 #endif /* QEMU_COROUTINE_H */
index 93fddc7dfbdd2d769eb58276206b45cd41a433d6..da1b9615d0ed02afd0116d389db3c948cf9e91b3 100644 (file)
@@ -143,7 +143,3 @@ void coroutine_fn qemu_coroutine_yield(void)
     self->caller = NULL;
     coroutine_swap(self, to);
 }
-
-void qemu_coroutine_adjust_pool_size(int n)
-{
-}