Use qemu-io command instead.
Reviewed-by: Denis V. Lunev <[email protected]>
Reviewed-by: Daniel P. Berrangé <[email protected]>
Signed-off-by: Marc-André Lureau <[email protected]>
---
tests/qtest/ahci-test.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/tests/qtest/ahci-test.c b/tests/qtest/ahci-test.c
index 3406ca884fb4..eb8d23999738 100644
--- a/tests/qtest/ahci-test.c
+++ b/tests/qtest/ahci-test.c
@@ -1900,8 +1900,7 @@ static void test_write_engine_stop_in_flight(void)
ahci_io(ahci, port, CMD_WRITE_DMA, rx, AHCI_SECTOR_SIZE, 1);
/* Suspend the backend write so the first sector stays in flight. */
- g_free(qtest_hmp(ahci->parent->qts,
- "qemu-io drive0 \"break write_aio wr\""));
+ qtest_qemu_io(ahci->parent->qts, "drive0", "break write_aio wr");
cmd = ahci_command_create(CMD_WRITE_PIO);
ahci_command_adjust(cmd, 0, ptr, bufsize, 0);
@@ -1911,7 +1910,7 @@ static void test_write_engine_stop_in_flight(void)
/* Drop the command list while the write is still outstanding. */
ahci_px_clr(ahci, port, AHCI_PX_CMD, AHCI_PX_CMD_ST);
- g_free(qtest_hmp(ahci->parent->qts, "qemu-io drive0 \"resume wr\""));
+ qtest_qemu_io(ahci->parent->qts, "drive0", "resume wr");
/* Round-trip through the device to confirm qemu is still alive. */
ahci_px_rreg(ahci, port, AHCI_PX_TFD);
--
2.55.0.543.g5ebe2ebe4ea8