qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Zhang, Chen" <chen.zhang@intel.com>
To: Kevin Wolf <kwolf@redhat.com>, Lukas Straub <lukasstraub2@web.de>
Cc: Fam Zheng <fam@euphon.net>, qemu-block <qemu-block@nongnu.org>,
	qemu-dev <qemu-devel@nongnu.org>, Max Reitz <mreitz@redhat.com>,
	Stefan Hajnoczi <stefanha@redhat.com>,
	Zhang Chen <zhangckid@gmail.com>, Minghao Yuan <meeho@qq.com>
Subject: RE: [RFC PATCH] block/io.c: Flush parent for quorum in generic code
Date: Tue, 18 May 2021 08:39:23 +0000	[thread overview]
Message-ID: <628ebb3df19e4898a8d407ad8e3671f4@intel.com> (raw)
In-Reply-To: <YKNvBWMyX/kNIPbt@merkur.fritz.box>



> -----Original Message-----
> From: Kevin Wolf <kwolf@redhat.com>
> Sent: Tuesday, May 18, 2021 3:39 PM
> To: Lukas Straub <lukasstraub2@web.de>
> Cc: Zhang, Chen <chen.zhang@intel.com>; Max Reitz <mreitz@redhat.com>;
> Stefan Hajnoczi <stefanha@redhat.com>; Fam Zheng <fam@euphon.net>;
> qemu-dev <qemu-devel@nongnu.org>; qemu-block <qemu-
> block@nongnu.org>; Minghao Yuan <meeho@qq.com>; Zhang Chen
> <zhangckid@gmail.com>
> Subject: Re: [RFC PATCH] block/io.c: Flush parent for quorum in generic code
> 
> Am 18.05.2021 um 08:33 hat Lukas Straub geschrieben:
> > On Wed, 12 May 2021 15:49:57 +0800
> > Zhang Chen <chen.zhang@intel.com> wrote:
> >
> > > Fix the issue from this patch:
> > > [PATCH] block: Flush all children in generic code From
> > > 883833e29cb800b4d92b5d4736252f4004885191
> > >
> > > Quorum driver do not have the primary child.
> > > It will caused guest block flush issue when use quorum and NBD.
> > > The vm guest flushes failed,and then guest filesystem is shutdown.
> >
> > Hi,
> > I think the problem is rather that the quorum driver provides
> > .bdrv_co_flush_to_disk (which predates .bdrv_co_flush) instead of
> > .bdrv_co_flush. Can you try with the following patch instead?
> >
> > diff --git a/block/quorum.c b/block/quorum.c index
> > cfc1436abb..f2c0805000 100644
> > --- a/block/quorum.c
> > +++ b/block/quorum.c
> > @@ -1279,7 +1279,7 @@ static BlockDriver bdrv_quorum = {
> >      .bdrv_dirname                       = quorum_dirname,
> >      .bdrv_co_block_status               = quorum_co_block_status,
> >
> > -    .bdrv_co_flush_to_disk              = quorum_co_flush,
> > +    .bdrv_co_flush                      = quorum_co_flush,
> >
> >      .bdrv_getlength                     = quorum_getlength,
> 
> Thanks, Lukas. This is exactly what I was going to suggest after having a look
> at the code now.
> 
> The problem is not related to drivers not having a primary child in general
> (though quorum might be the only one in this category at the moment), but
> that quorum wants to override the default error handling semantics with its
> voting mechanism.

Yes, you are right. We can ignore this patch.
I tested Lukas's patch, it works for me.
Hi Lukas, Can you send this patch to upstream?

Thanks
Chen

> 
> Kevin

      reply	other threads:[~2021-05-18  8:43 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-12  7:49 [RFC PATCH] block/io.c: Flush parent for quorum in generic code Zhang Chen
2021-05-13 14:25 ` Stefan Hajnoczi
2021-05-17 17:59   ` Zhang, Chen
2021-05-18  6:33 ` Lukas Straub
2021-05-18  7:38   ` Kevin Wolf
2021-05-18  8:39     ` Zhang, Chen [this message]

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=628ebb3df19e4898a8d407ad8e3671f4@intel.com \
    --to=chen.zhang@intel.com \
    --cc=fam@euphon.net \
    --cc=kwolf@redhat.com \
    --cc=lukasstraub2@web.de \
    --cc=meeho@qq.com \
    --cc=mreitz@redhat.com \
    --cc=qemu-block@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    --cc=stefanha@redhat.com \
    --cc=zhangckid@gmail.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).