From: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
To: qemu-block@nongnu.org, qemu-devel@nongnu.org
Cc: vsementsov@virtuozzo.com, stefanha@redhat.com, famz@redhat.com,
mreitz@redhat.com, jcody@redhat.com, eblake@redhat.com,
pbonzini@redhat.com, den@openvz.org, kwolf@redhat.com
Subject: [Qemu-devel] [PATCH 1/2] mirror: finish earlier on error
Date: Wed, 3 Aug 2016 15:56:44 +0300 [thread overview]
Message-ID: <1470229005-152704-2-git-send-email-vsementsov@virtuozzo.com> (raw)
In-Reply-To: <1470229005-152704-1-git-send-email-vsementsov@virtuozzo.com>
Stop to produce new async copy requests from mirror_iteration if
critical error (error action = BLOCK_ERROR_ACTION_REPORT) detected.
Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
---
block/mirror.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/block/mirror.c b/block/mirror.c
index d6034f5..e0b3f41 100644
--- a/block/mirror.c
+++ b/block/mirror.c
@@ -419,6 +419,10 @@ static uint64_t coroutine_fn mirror_iteration(MirrorBlockJob *s)
mirror_wait_for_io(s);
}
+ if (s->ret < 0) {
+ return 0;
+ }
+
mirror_clip_sectors(s, sector_num, &io_sectors);
switch (mirror_method) {
case MIRROR_METHOD_COPY:
--
1.8.3.1
next prev parent reply other threads:[~2016-08-03 12:57 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-08-03 12:56 [Qemu-devel] [PATCH 0/2] fix [mirror: double performance...] Vladimir Sementsov-Ogievskiy
2016-08-03 12:56 ` Vladimir Sementsov-Ogievskiy [this message]
2016-08-03 12:56 ` [Qemu-devel] [PATCH 2/2] iotests: fix 109 Vladimir Sementsov-Ogievskiy
2016-08-03 15:22 ` Sascha Silbe
2016-08-03 16:18 ` Max Reitz
2016-08-04 9:02 ` Sascha Silbe
2016-08-08 9:07 ` [Qemu-devel] [PATCH 0/2] fix [mirror: double performance...] Kevin Wolf
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1470229005-152704-2-git-send-email-vsementsov@virtuozzo.com \
--to=vsementsov@virtuozzo.com \
--cc=den@openvz.org \
--cc=eblake@redhat.com \
--cc=famz@redhat.com \
--cc=jcody@redhat.com \
--cc=kwolf@redhat.com \
--cc=mreitz@redhat.com \
--cc=pbonzini@redhat.com \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).