mirror of
https://github.com/izzy2lost/xemu.git
synced 2026-07-06 00:20:22 -07:00
thread-pool: Rename AIO pool functions to *_aio() and data types to *Aio
These names conflict with ones used by future generic thread pool equivalents. Generic names should belong to the generic pool type, not specific (AIO) type. Acked-by: Fabiano Rosas <farosas@suse.de> Reviewed-by: Cédric Le Goater <clg@redhat.com> Reviewed-by: Peter Xu <peterx@redhat.com> Signed-off-by: Maciej S. Szmigiero <maciej.szmigiero@oracle.com> Link: https://lore.kernel.org/qemu-devel/70f9e0fb4b01042258a1a57996c64d19779dc7f0.1741124640.git.maciej.szmigiero@oracle.com Signed-off-by: Cédric Le Goater <clg@redhat.com>
This commit is contained in:
committed by
Cédric Le Goater
parent
03c6468a13
commit
dc67daeed5
+4
-4
@@ -54,7 +54,7 @@ typedef void QEMUBHFunc(void *opaque);
|
||||
typedef bool AioPollFn(void *opaque);
|
||||
typedef void IOHandler(void *opaque);
|
||||
|
||||
struct ThreadPool;
|
||||
struct ThreadPoolAio;
|
||||
struct LinuxAioState;
|
||||
typedef struct LuringState LuringState;
|
||||
|
||||
@@ -207,7 +207,7 @@ struct AioContext {
|
||||
/* Thread pool for performing work and receiving completion callbacks.
|
||||
* Has its own locking.
|
||||
*/
|
||||
struct ThreadPool *thread_pool;
|
||||
struct ThreadPoolAio *thread_pool;
|
||||
|
||||
#ifdef CONFIG_LINUX_AIO
|
||||
struct LinuxAioState *linux_aio;
|
||||
@@ -500,8 +500,8 @@ void aio_set_event_notifier_poll(AioContext *ctx,
|
||||
*/
|
||||
GSource *aio_get_g_source(AioContext *ctx);
|
||||
|
||||
/* Return the ThreadPool bound to this AioContext */
|
||||
struct ThreadPool *aio_get_thread_pool(AioContext *ctx);
|
||||
/* Return the ThreadPoolAio bound to this AioContext */
|
||||
struct ThreadPoolAio *aio_get_thread_pool(AioContext *ctx);
|
||||
|
||||
/* Setup the LinuxAioState bound to this AioContext */
|
||||
struct LinuxAioState *aio_setup_linux_aio(AioContext *ctx, Error **errp);
|
||||
|
||||
@@ -24,10 +24,10 @@
|
||||
|
||||
typedef int ThreadPoolFunc(void *opaque);
|
||||
|
||||
typedef struct ThreadPool ThreadPool;
|
||||
typedef struct ThreadPoolAio ThreadPoolAio;
|
||||
|
||||
ThreadPool *thread_pool_new(struct AioContext *ctx);
|
||||
void thread_pool_free(ThreadPool *pool);
|
||||
ThreadPoolAio *thread_pool_new_aio(struct AioContext *ctx);
|
||||
void thread_pool_free_aio(ThreadPoolAio *pool);
|
||||
|
||||
/*
|
||||
* thread_pool_submit_{aio,co} API: submit I/O requests in the thread's
|
||||
@@ -36,7 +36,7 @@ void thread_pool_free(ThreadPool *pool);
|
||||
BlockAIOCB *thread_pool_submit_aio(ThreadPoolFunc *func, void *arg,
|
||||
BlockCompletionFunc *cb, void *opaque);
|
||||
int coroutine_fn thread_pool_submit_co(ThreadPoolFunc *func, void *arg);
|
||||
void thread_pool_update_params(ThreadPoolAio *pool, struct AioContext *ctx);
|
||||
|
||||
void thread_pool_update_params(ThreadPool *pool, struct AioContext *ctx);
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user