On Tue, Sep 15, 2020 at 07:44:06PM +0300, Vladimir Sementsov-Ogievskiy wrote: > Most of our coroutine wrappers already follow this convention: > > We have 'coroutine_fn bdrv_co_<something>(<normal argument list>)' as > the core function, and a wrapper 'bdrv_<something>(<same argument > list>)' which does parameters packing and call bdrv_run_co(). > > The only outsiders are the bdrv_prwv_co and > bdrv_common_block_status_above wrappers. Let's refactor them to behave > as the others, it simplifies further conversion of coroutine wrappers. > > This patch adds indirection layer, but it will be compensated by > further commit, which will drop bdrv_co_prwv together with is_write > logic, to keep read and write path separate. > > Signed-off-by: Vladimir Sementsov-Ogievskiy <[email protected]> > Reviewed-by: Eric Blake <[email protected]> > --- > block/io.c | 60 +++++++++++++++++++++++++++++------------------------- > 1 file changed, 32 insertions(+), 28 deletions(-)
Reviewed-by: Stefan Hajnoczi <[email protected]>
signature.asc
Description: PGP signature
