[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 6/8] test-bdrv-drain: Call bdrv_co_unref() in coroutine context
From: |
Kevin Wolf |
Subject: |
[PATCH 6/8] test-bdrv-drain: Call bdrv_co_unref() in coroutine context |
Date: |
Wed, 10 May 2023 22:35:59 +0200 |
bdrv_unref() is a no_coroutine_fn, so calling it from coroutine context
is invalid. Use bdrv_co_unref() instead.
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
---
tests/unit/test-bdrv-drain.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tests/unit/test-bdrv-drain.c b/tests/unit/test-bdrv-drain.c
index ae4299ccfa..08bb0f9984 100644
--- a/tests/unit/test-bdrv-drain.c
+++ b/tests/unit/test-bdrv-drain.c
@@ -1019,7 +1019,7 @@ static void coroutine_fn test_co_delete_by_drain(void
*opaque)
g_assert_cmpint(bs->refcnt, ==, 1);
if (!dbdd->detach_instead_of_delete) {
- blk_unref(blk);
+ blk_co_unref(blk);
} else {
BdrvChild *c, *next_c;
QLIST_FOREACH_SAFE(c, &bs->children, next, next_c) {
--
2.40.1
- Re: [PATCH 1/8] block: Call .bdrv_co_create(_opts) unlocked, (continued)
[PATCH 2/8] block/export: Fix null pointer dereference in error path, Kevin Wolf, 2023/05/10
[PATCH 3/8] qcow2: Unlock the graph in qcow2_do_open() where necessary, Kevin Wolf, 2023/05/10
[PATCH 4/8] qemu-img: Take graph lock more selectively, Kevin Wolf, 2023/05/10
[PATCH 6/8] test-bdrv-drain: Call bdrv_co_unref() in coroutine context,
Kevin Wolf <=
[PATCH 5/8] test-bdrv-drain: Take graph lock more selectively, Kevin Wolf, 2023/05/10
[PATCH 7/8] blockjob: Adhere to rate limit even when reentered early, Kevin Wolf, 2023/05/10
[PATCH 8/8] graph-lock: Honour read locks even in the main thread, Kevin Wolf, 2023/05/10