From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:40177) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bAdjY-0005qo-4l for qemu-devel@nongnu.org; Wed, 08 Jun 2016 09:41:25 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bAdjV-0000FC-Q7 for qemu-devel@nongnu.org; Wed, 08 Jun 2016 09:41:23 -0400 References: <1465348292-26750-1-git-send-email-xiecl.fnst@cn.fujitsu.com> <1465348292-26750-8-git-send-email-xiecl.fnst@cn.fujitsu.com> From: Eric Blake Message-ID: <57582070.6020508@redhat.com> Date: Wed, 8 Jun 2016 07:41:04 -0600 MIME-Version: 1.0 In-Reply-To: <1465348292-26750-8-git-send-email-xiecl.fnst@cn.fujitsu.com> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="WjGjGBM1XX0vnlP0kJa1kJOV1TRtxemPb" Subject: Re: [Qemu-devel] [PATCH v20 07/10] Introduce new APIs to do replication operation List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Changlong Xie , qemu devel , qemu trival , Stefan Hajnoczi , Fam Zheng , Max Reitz , Kevin Wolf , Jeff Cody Cc: qemu block , Paolo Bonzini , John Snow , Markus Armbruster , "Dr. David Alan Gilbert" , Dong Eddie , Jiang Yunhong , zhanghailiang , Gonglei , Wen Congyang This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --WjGjGBM1XX0vnlP0kJa1kJOV1TRtxemPb Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 06/07/2016 07:11 PM, Changlong Xie wrote: > Signed-off-by: Wen Congyang > Signed-off-by: zhanghailiang > Signed-off-by: Gonglei > Signed-off-by: Changlong Xie No mention of the API names in the commit message? Grepping 'git log' is easier if there is something useful to grep for. > --- > Makefile.objs | 1 + > qapi/block-core.json | 13 ++++ > replication.c | 105 ++++++++++++++++++++++++++++++ > replication.h | 176 +++++++++++++++++++++++++++++++++++++++++++= ++++++++ > 4 files changed, 295 insertions(+) > create mode 100644 replication.c > create mode 100644 replication.h >=20 > +++ b/qapi/block-core.json > @@ -2032,6 +2032,19 @@ > '*read-pattern': 'QuorumReadPattern' } } > =20 > ## > +# @ReplicationMode > +# > +# An enumeration of replication modes. > +# > +# @primary: Primary mode, the vm's state will be sent to secondary QEM= U. > +# > +# @secondary: Secondary mode, receive the vm's state from primary QEMU= =2E > +# > +# Since: 2.7 > +## > +{ 'enum' : 'ReplicationMode', 'data' : [ 'primary', 'secondary' ] } > + This part is fine, from an interface point of view. However, I have not closely reviewed the rest of the patch or series. That said, here's some quick things that caught my eye. > +++ b/replication.c > @@ -0,0 +1,105 @@ > +/* > + * Replication filter > + * > + * Copyright (c) 2016 HUAWEI TECHNOLOGIES CO., LTD. > + * Copyright (c) 2016 Intel Corporation > + * Copyright (c) 2016 FUJITSU LIMITED > + * > + * Author: > + * Changlong Xie > + * > + * This work is licensed under the terms of the GNU GPL, version 2 or = later. > + * See the COPYING file in the top-level directory. > + */ > + > +#include "replication.h" All new .c files must include "qemu/osdep.h" first. > +++ b/replication.h > @@ -0,0 +1,176 @@ > +/* > + * Replication filter > + * > + * Copyright (c) 2016 HUAWEI TECHNOLOGIES CO., LTD. > + * Copyright (c) 2016 Intel Corporation > + * Copyright (c) 2016 FUJITSU LIMITED > + * > + * Author: > + * Changlong Xie > + * > + * This work is licensed under the terms of the GNU GPL, version 2 or = later. > + * See the COPYING file in the top-level directory. > + */ > + > +#ifndef REPLICATION_H > +#define REPLICATION_H > + > +#include "qemu/osdep.h" And .h files must NOT include osdep.h. > +#include "qapi/error.h" Do you really need the full error.h, or is typedefs.h enough to get the forward declaration of Error? --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org --WjGjGBM1XX0vnlP0kJa1kJOV1TRtxemPb Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBCAAGBQJXWCBwAAoJEKeha0olJ0Nq9d8H+QECmZOaaMIsra5lQkvcHDpl YusAac884RJeRe+htg777z9+s05x+uHwekuIS1bukRCnN4pEG4dmL+MdZjsujywa lG8NHHdc51SN573+8MO6TRO0TppKTVot4fjo3vREUwSRkVK5yiqW+S3y7t5Jk2hJ UBc9nLvae3fPU1vbdI8nkjgDETVLkoKHuU6u6MxZrTsZTNzQXcbcp6TPrq1183d5 Udgf/BTpUOrUtQ1uGvt60nHCMq6zTwOdUA8Ib6ZXeKv2tJPdx9DJBaqD69dUCV6L McEEKVuxT/1kDGShTtuLS/FO5cyaUDaO8lkOp4fKFNsAqjoheslplrA4+Sh6sUQ= =L4g0 -----END PGP SIGNATURE----- --WjGjGBM1XX0vnlP0kJa1kJOV1TRtxemPb--