提交 01859874 编写于 作者: K Kevin Wolf

qed: Remove recursion in qed_aio_next_io()

Instead of calling itself recursively as the last thing, just convert
qed_aio_next_io() into a loop.

This patch is best reviewed with 'git show -w' because most of it is
just whitespace changes.
Signed-off-by: NKevin Wolf <kwolf@redhat.com>
Reviewed-by: NStefan Hajnoczi <stefanha@redhat.com>
上级 dddf8db1
......@@ -1280,6 +1280,7 @@ static void qed_aio_next_io(QEDAIOCB *acb)
size_t len;
int ret;
while (1) {
trace_qed_aio_next_io(s, acb, 0, acb->cur_pos + acb->cur_qiov.size);
if (acb->backing_qiov) {
......@@ -1318,7 +1319,7 @@ static void qed_aio_next_io(QEDAIOCB *acb)
}
return;
}
qed_aio_next_io(acb);
}
}
static BlockAIOCB *qed_aio_setup(BlockDriverState *bs,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册