qemu-block
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 04/13] block: Remove drained_end_counter


From: Hanna Reitz
Subject: Re: [PATCH 04/13] block: Remove drained_end_counter
Date: Mon, 14 Nov 2022 19:19:19 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.11.0

On 08.11.22 13:37, Kevin Wolf wrote:
drained_end_counter is unused now, nobody changes its value any more. It
can be removed.

In cases where we had two almost identical functions that only differed
in whether the caller passes drained_end_counter, or whether they would
poll for a local drained_end_counter to reach 0, these become a single
function.

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
---
  include/block/block-io.h         | 15 -----
  include/block/block_int-common.h |  6 +-
  block.c                          |  5 +-
  block/block-backend.c            |  4 +-
  block/io.c                       | 97 ++++++++------------------------
  blockjob.c                       |  2 +-
  6 files changed, 30 insertions(+), 99 deletions(-)

The comments on bdrv_drained_end() and bdrv_parent_drained_end_single() in include/block/block-io.h still say that they poll some AioContext “which may result in a graph change”.  That’s no longer the case, though, so those paragraphs should be dropped, I think.

Apart from that, looks good.

Hanna




reply via email to

[Prev in Thread] Current Thread [Next in Thread]