[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-block] [PATCH v3 17/19] test-bdrv-drain: Fix outdated comments
From: |
Kevin Wolf |
Subject: |
[Qemu-block] [PATCH v3 17/19] test-bdrv-drain: Fix outdated comments |
Date: |
Thu, 20 Sep 2018 18:19:56 +0200 |
Commit 89bd030533e changed the test case from using job_sleep_ns() to
using qemu_co_sleep_ns() instead. Also, block_job_sleep_ns() became
job_sleep_ns() in commit 5d43e86e11f.
In both cases, some comments in the test case were not updated. Do that
now.
Reported-by: Max Reitz <address@hidden>
Signed-off-by: Kevin Wolf <address@hidden>
---
tests/test-bdrv-drain.c | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/tests/test-bdrv-drain.c b/tests/test-bdrv-drain.c
index bbc56a055f..526978a8ac 100644
--- a/tests/test-bdrv-drain.c
+++ b/tests/test-bdrv-drain.c
@@ -820,9 +820,9 @@ static int coroutine_fn test_job_run(Job *job, Error **errp)
job_transition_to_ready(&s->common.job);
while (!s->should_complete) {
- /* Avoid block_job_sleep_ns() because it marks the job as !busy. We
- * want to emulate some actual activity (probably some I/O) here so
- * that drain has to wait for this acitivity to stop. */
+ /* Avoid job_sleep_ns() because it marks the job as !busy. We want to
+ * emulate some actual activity (probably some I/O) here so that drain
+ * has to wait for this acitivity to stop. */
qemu_co_sleep_ns(QEMU_CLOCK_REALTIME, 100000);
job_pause_point(&s->common.job);
}
@@ -908,7 +908,7 @@ static void test_blockjob_common(enum drain_type
drain_type, bool use_iothread,
g_assert_cmpint(job->job.pause_count, ==, 0);
g_assert_false(job->job.paused);
- g_assert_true(job->job.busy); /* We're in job_sleep_ns() */
+ g_assert_true(job->job.busy); /* We're in qemu_co_sleep_ns() */
do_drain_begin_unlocked(drain_type, src);
@@ -956,7 +956,7 @@ static void test_blockjob_common(enum drain_type
drain_type, bool use_iothread,
g_assert_cmpint(job->job.pause_count, ==, 0);
g_assert_false(job->job.paused);
- g_assert_true(job->job.busy); /* We're in job_sleep_ns() */
+ g_assert_true(job->job.busy); /* We're in qemu_co_sleep_ns() */
aio_context_acquire(ctx);
ret = job_complete_sync(&job->job, &error_abort);
--
2.13.6
- Re: [Qemu-block] [PATCH v3 11/19] block-backend: Decrease in_flight only after callback, (continued)
- [Qemu-block] [PATCH v3 12/19] blockjob: Lie better in child_job_drained_poll(), Kevin Wolf, 2018/09/20
- [Qemu-block] [PATCH v3 06/19] job: Use AIO_WAIT_WHILE() in job_finish_sync(), Kevin Wolf, 2018/09/20
- [Qemu-block] [PATCH v3 09/19] block-backend: Add .drained_poll callback, Kevin Wolf, 2018/09/20
- [Qemu-block] [PATCH v3 13/19] block: Remove aio_poll() in bdrv_drain_poll variants, Kevin Wolf, 2018/09/20
- [Qemu-block] [PATCH v3 10/19] block-backend: Fix potential double blk_delete(), Kevin Wolf, 2018/09/20
- [Qemu-block] [PATCH v3 07/19] test-bdrv-drain: Test AIO_WAIT_WHILE() in completion callback, Kevin Wolf, 2018/09/20
- [Qemu-block] [PATCH v3 14/19] test-bdrv-drain: Test nested poll in bdrv_drain_poll_top_level(), Kevin Wolf, 2018/09/20
- [Qemu-block] [PATCH v3 16/19] test-bdrv-drain: AIO_WAIT_WHILE() in job .commit/.abort, Kevin Wolf, 2018/09/20
- [Qemu-block] [PATCH v3 15/19] job: Avoid deadlocks in job_completed_txn_abort(), Kevin Wolf, 2018/09/20
- [Qemu-block] [PATCH v3 17/19] test-bdrv-drain: Fix outdated comments,
Kevin Wolf <=
- [Qemu-block] [PATCH v3 19/19] test-bdrv-drain: Test draining job source child and parent, Kevin Wolf, 2018/09/20
- [Qemu-block] [PATCH v3 18/19] block: Use a single global AioWait, Kevin Wolf, 2018/09/20