Stefan Hajnoczi
ab61335025
block: drain from main loop thread in bdrv_co_yield_to_drain()
...
For simplicity, always run BlockDevOps .drained_begin/end/poll()
callbacks in the main loop thread. This makes it easier to implement the
callbacks and avoids extra locks.
Move the function pointer declarations from the I/O Code section to the
Global State section for BlockDevOps, BdrvChildClass, and BlockDriver.
Narrow IO_OR_GS_CODE() to GLOBAL_STATE_CODE() where appropriate.
The test-bdrv-drain test case calls bdrv_drain() from an IOThread. This
is now only allowed from coroutine context, so update the test case to
run in a coroutine.
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Reviewed-by: Kevin Wolf <kwolf@redhat.com>
Message-Id: <20230516190238.8401-11-stefanha@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
2023-05-30 17:32:02 +02:00
..
2022-09-18 09:17:41 +02:00
2022-04-06 14:31:55 +02:00
2022-04-06 14:31:55 +02:00
2022-04-06 14:31:55 +02:00
2022-04-21 17:03:51 +04:00
2022-04-21 17:03:51 +04:00
2022-04-06 14:31:55 +02:00
2022-10-27 11:55:41 +01:00
2022-05-16 11:46:04 +01:00
2022-05-16 11:46:04 +01:00
2022-05-16 11:46:04 +01:00
2022-10-12 19:22:01 +04:00
2021-06-18 10:59:52 -05:00
2023-05-19 19:12:12 +02:00
2021-06-25 10:53:46 +02:00
2023-04-28 11:31:07 +02:00
2022-07-18 20:24:36 +02:00
2023-02-27 09:15:39 +01:00
2023-03-13 15:39:31 +04:00
2022-09-02 15:54:47 +04:00
2023-05-08 11:10:48 +02:00
2023-01-20 07:21:46 +01:00
2023-05-30 17:32:02 +02:00
2022-10-27 20:14:11 +02:00
2023-05-30 17:21:23 +02:00
2022-10-07 12:11:41 +02:00
2023-03-20 12:43:50 +01:00
2022-12-14 20:04:47 +01:00
2022-04-06 14:31:55 +02:00
2023-01-19 10:18:28 +01:00
2022-05-26 11:41:56 +01:00
2022-12-14 20:04:47 +01:00
2021-07-14 14:15:52 +01:00
2022-11-02 06:56:32 -04:00
2021-07-14 14:15:52 +01:00
2021-07-14 14:15:52 +01:00
2021-07-14 14:15:52 +01:00
2021-07-14 14:15:52 +01:00
2023-04-20 06:50:11 +02:00
2022-08-25 15:24:09 +02:00
2023-01-16 17:42:17 +01:00
2023-02-08 07:28:05 +01:00
2021-10-27 17:10:00 -07:00
2023-03-13 15:23:37 +04:00
2022-01-12 17:09:39 +00:00
2022-04-21 17:03:51 +04:00
2022-03-21 15:44:44 +01:00
2022-10-12 12:48:53 +02:00
2022-04-20 18:00:30 -03:00
2022-12-20 17:09:41 -08:00
2023-03-13 15:39:31 +04:00
2022-05-03 15:46:08 +04:00
2022-06-22 18:11:21 +01:00
2023-02-06 19:22:56 +01:00
2023-01-16 17:42:17 +01:00
2022-07-18 20:24:36 +02:00
2022-04-21 17:03:51 +04:00
2022-04-20 10:51:11 -07:00
2023-05-19 19:12:12 +02:00
2021-07-06 08:33:51 +02:00
2023-05-04 09:12:48 +00:00
2021-09-01 11:08:15 +01:00
2023-01-11 10:44:34 +01:00
2022-12-13 18:31:37 +01:00
2023-04-26 07:52:45 +02:00
2023-04-26 07:52:45 +02:00
2023-03-28 15:23:10 -07:00
2023-03-20 12:43:50 +01:00
2021-05-26 14:49:46 +02:00
2023-02-08 07:28:05 +01:00
2021-12-31 13:42:48 +01:00
2022-04-06 14:31:55 +02:00
2022-04-06 14:31:55 +02:00
2023-04-25 13:17:28 +02:00
2022-04-06 14:31:55 +02:00
2022-12-13 18:31:37 +01:00
2023-03-02 17:06:27 +01:00
2021-05-14 16:14:10 +02:00
2023-05-23 16:51:18 -07:00
2023-03-07 17:04:30 +00:00
2021-09-27 08:23:25 +02:00