* [Qemu-devel] [PULL 0/1] Block patches for 2.5
@ 2015-12-02 14:27 Jeff Cody
2015-12-02 14:27 ` [Qemu-devel] [PULL 1/1] mirror: Quiesce source during "mirror_exit" Jeff Cody
2015-12-02 15:40 ` [Qemu-devel] [PULL 0/1] Block patches for 2.5 Peter Maydell
0 siblings, 2 replies; 4+ messages in thread
From: Jeff Cody @ 2015-12-02 14:27 UTC (permalink / raw)
To: qemu-block; +Cc: peter.maydell, jcody, qemu-devel
The following changes since commit 680617ed43a2811318ac2df63e686f6b7bc22f55:
Merge remote-tracking branch 'remotes/weil/tags/pull-wxx-20151130' into staging (2015-11-30 15:35:20 +0000)
are available in the git repository at:
git@github.com:codyprime/qemu-kvm-jtc.git tags/block-pull-request
for you to fetch changes up to cdf45d4a6d694a394d89f0d8f72f4fefbd82be58:
mirror: Quiesce source during "mirror_exit" (2015-11-30 16:26:14 -0500)
----------------------------------------------------------------
Block patches for 2.5
----------------------------------------------------------------
Fam Zheng (1):
mirror: Quiesce source during "mirror_exit"
block/mirror.c | 4 ++++
1 file changed, 4 insertions(+)
--
1.9.3
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Qemu-devel] [PULL 1/1] mirror: Quiesce source during "mirror_exit"
2015-12-02 14:27 [Qemu-devel] [PULL 0/1] Block patches for 2.5 Jeff Cody
@ 2015-12-02 14:27 ` Jeff Cody
2015-12-02 15:40 ` [Qemu-devel] [PULL 0/1] Block patches for 2.5 Peter Maydell
1 sibling, 0 replies; 4+ messages in thread
From: Jeff Cody @ 2015-12-02 14:27 UTC (permalink / raw)
To: qemu-block; +Cc: peter.maydell, jcody, qemu-devel
From: Fam Zheng <famz@redhat.com>
With dataplane, the ioeventfd events could be dispatched after
mirror_run releases the dirty bitmap, but before mirror_exit actually
does the device switch, because the iothread will still be running, and
it will cause silent data loss.
Fix this by adding a bdrv_drained_begin/end pair around the window, so
that no new external request will be handled.
Signed-off-by: Fam Zheng <famz@redhat.com>
---
block/mirror.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/block/mirror.c b/block/mirror.c
index 52c9abf..0e8f556 100644
--- a/block/mirror.c
+++ b/block/mirror.c
@@ -388,6 +388,7 @@ static void mirror_exit(BlockJob *job, void *opaque)
bdrv_unref(s->target);
block_job_completed(&s->common, data->ret);
g_free(data);
+ bdrv_drained_end(src);
bdrv_unref(src);
}
@@ -607,6 +608,9 @@ immediate_exit:
data = g_malloc(sizeof(*data));
data->ret = ret;
+ /* Before we switch to target in mirror_exit, make sure data doesn't
+ * change. */
+ bdrv_drained_begin(s->common.bs);
block_job_defer_to_main_loop(&s->common, mirror_exit, data);
}
--
1.9.3
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [Qemu-devel] [PULL 0/1] Block patches for 2.5
2015-12-02 14:27 [Qemu-devel] [PULL 0/1] Block patches for 2.5 Jeff Cody
2015-12-02 14:27 ` [Qemu-devel] [PULL 1/1] mirror: Quiesce source during "mirror_exit" Jeff Cody
@ 2015-12-02 15:40 ` Peter Maydell
2015-12-02 15:42 ` Jeff Cody
1 sibling, 1 reply; 4+ messages in thread
From: Peter Maydell @ 2015-12-02 15:40 UTC (permalink / raw)
To: Jeff Cody; +Cc: QEMU Developers, Qemu-block
On 2 December 2015 at 14:27, Jeff Cody <jcody@redhat.com> wrote:
> The following changes since commit 680617ed43a2811318ac2df63e686f6b7bc22f55:
>
> Merge remote-tracking branch 'remotes/weil/tags/pull-wxx-20151130' into staging (2015-11-30 15:35:20 +0000)
>
> are available in the git repository at:
>
>
> git@github.com:codyprime/qemu-kvm-jtc.git tags/block-pull-request
>
> for you to fetch changes up to cdf45d4a6d694a394d89f0d8f72f4fefbd82be58:
>
> mirror: Quiesce source during "mirror_exit" (2015-11-30 16:26:14 -0500)
>
> ----------------------------------------------------------------
> Block patches for 2.5
> ----------------------------------------------------------------
>
> Fam Zheng (1):
> mirror: Quiesce source during "mirror_exit"
>
> block/mirror.c | 4 ++++
> 1 file changed, 4 insertions(+)
Hi. It looks like you forgot to add your own signoff to Fam's patch.
Can you respin this pullreq, please?
thanks
-- PMM
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Qemu-devel] [PULL 0/1] Block patches for 2.5
2015-12-02 15:40 ` [Qemu-devel] [PULL 0/1] Block patches for 2.5 Peter Maydell
@ 2015-12-02 15:42 ` Jeff Cody
0 siblings, 0 replies; 4+ messages in thread
From: Jeff Cody @ 2015-12-02 15:42 UTC (permalink / raw)
To: Peter Maydell; +Cc: QEMU Developers, Qemu-block
On Wed, Dec 02, 2015 at 03:40:42PM +0000, Peter Maydell wrote:
> On 2 December 2015 at 14:27, Jeff Cody <jcody@redhat.com> wrote:
> > The following changes since commit 680617ed43a2811318ac2df63e686f6b7bc22f55:
> >
> > Merge remote-tracking branch 'remotes/weil/tags/pull-wxx-20151130' into staging (2015-11-30 15:35:20 +0000)
> >
> > are available in the git repository at:
> >
> >
> > git@github.com:codyprime/qemu-kvm-jtc.git tags/block-pull-request
> >
> > for you to fetch changes up to cdf45d4a6d694a394d89f0d8f72f4fefbd82be58:
> >
> > mirror: Quiesce source during "mirror_exit" (2015-11-30 16:26:14 -0500)
> >
> > ----------------------------------------------------------------
> > Block patches for 2.5
> > ----------------------------------------------------------------
> >
> > Fam Zheng (1):
> > mirror: Quiesce source during "mirror_exit"
> >
> > block/mirror.c | 4 ++++
> > 1 file changed, 4 insertions(+)
>
> Hi. It looks like you forgot to add your own signoff to Fam's patch.
> Can you respin this pullreq, please?
>
> thanks
> -- PMM
Sorry, yes.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2015-12-02 15:42 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-12-02 14:27 [Qemu-devel] [PULL 0/1] Block patches for 2.5 Jeff Cody
2015-12-02 14:27 ` [Qemu-devel] [PULL 1/1] mirror: Quiesce source during "mirror_exit" Jeff Cody
2015-12-02 15:40 ` [Qemu-devel] [PULL 0/1] Block patches for 2.5 Peter Maydell
2015-12-02 15:42 ` Jeff Cody
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).