diff options
author | Vladimir Sementsov-Ogievskiy | 2020-07-27 20:47:50 +0200 |
---|---|---|
committer | Eric Blake | 2020-07-28 16:54:43 +0200 |
commit | 12c75e20a269ac917f4a76936d7142264e522233 (patch) | |
tree | 3517fc68a10c75bb527a2e9295cef764c00f5fce /scripts | |
parent | block/nbd: on shutdown terminate connection attempt (diff) | |
download | qemu-12c75e20a269ac917f4a76936d7142264e522233.tar.gz qemu-12c75e20a269ac917f4a76936d7142264e522233.tar.xz qemu-12c75e20a269ac917f4a76936d7142264e522233.zip |
block/nbd: nbd_co_reconnect_loop(): don't sleep if drained
We try to go to wakeable sleep, so that, if drain begins it will break
the sleep. But what if nbd_client_co_drain_begin() already called and
s->drained is already true? We'll go to sleep, and drain will have to
wait for the whole timeout. Let's improve it.
Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Message-Id: <20200727184751.15704-5-vsementsov@virtuozzo.com>
Signed-off-by: Eric Blake <eblake@redhat.com>
Diffstat (limited to 'scripts')
0 files changed, 0 insertions, 0 deletions