On 27.09.2016 08:37, Fam Zheng wrote:
> The idiom of "blk_new() + blk_insert_bs()" is common. Use a new
> BB interface that does both things to make the coming transition that
> adds AioContext to BB easier.

Indeed. It was called blk_new_with_bs() before and I dropped it. :-)

(The difference and the reason why I dropped it was that
blk_new_with_bs() created the BDS, too.)

((And as a side note, this pattern does not come from me dropping
blk_new_with_bs(). As far as I remember, I replaced most places where it
was used by blk_new_open().))

> The added blk_new_with_ctx doesn't handle the passed ctx and is purely
> here to avoid a small code churn.

Maybe add a "yet" in there, i.e. "does not handle the passed ctx yet"?

> 
> Signed-off-by: Fam Zheng <f...@redhat.com>
> ---
>  block/backup.c                   |  3 +--
>  block/block-backend.c            | 24 ++++++++++++++++++------
>  block/commit.c                   | 12 ++++--------
>  block/mirror.c                   |  3 +--
>  blockjob.c                       |  3 +--
>  hmp.c                            |  3 +--
>  hw/core/qdev-properties-system.c |  3 +--
>  include/sysemu/block-backend.h   |  1 +
>  nbd/server.c                     |  3 +--
>  tests/test-blockjob.c            |  3 +--
>  10 files changed, 30 insertions(+), 28 deletions(-)

Reviewed-by: Max Reitz <mre...@redhat.com>

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to