block: add BDS field to count in-flight requests
commit99723548561978da8ef44cf804fb7912698f5d88
authorPaolo Bonzini <pbonzini@redhat.com>
Thu, 27 Oct 2016 10:48:52 +0000 (27 12:48 +0200)
committerFam Zheng <famz@redhat.com>
Fri, 28 Oct 2016 13:50:18 +0000 (28 21:50 +0800)
treeacb3c6db77507a77a8f275747e12abc2494d6295
parent9a0cec664eefed475a5954006e29f2fd7cd29d2a
block: add BDS field to count in-flight requests

Unlike tracked_requests, this field also counts throttled requests,
and remains non-zero if an AIO operation needs a BH to be "really"
completed.

With this change, it is no longer necessary to have a dummy
BdrvTrackedRequest for requests that are never serialising, and
it is no longer necessary to poll the AioContext once after
bdrv_requests_pending(bs) returns false.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Fam Zheng <famz@redhat.com>
Message-Id: <1477565348-5458-5-git-send-email-pbonzini@redhat.com>
Signed-off-by: Fam Zheng <famz@redhat.com>
block/block-backend.c
block/io.c
include/block/block_int.h