From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:36088) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1X0Cxc-0002ot-4J for qemu-devel@nongnu.org; Thu, 26 Jun 2014 12:55:48 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1X0CxX-0004uY-Su for qemu-devel@nongnu.org; Thu, 26 Jun 2014 12:55:44 -0400 Received: from mx1.redhat.com ([209.132.183.28]:13064) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1X0CxX-0004uJ-Jn for qemu-devel@nongnu.org; Thu, 26 Jun 2014 12:55:39 -0400 Message-ID: <53AC5085.9040605@redhat.com> Date: Thu, 26 Jun 2014 10:55:33 -0600 From: Eric Blake MIME-Version: 1.0 References: <1403763216-28508-1-git-send-email-hutao@cn.fujitsu.com> In-Reply-To: <1403763216-28508-1-git-send-email-hutao@cn.fujitsu.com> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="TPObW27JGD0PDpH7wGrciL7xmmDemVOQU" Subject: Re: [Qemu-devel] [PATCH] cleanup of ROUND_UP-like lines List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Hu Tao , qemu-devel@nongnu.org This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --TPObW27JGD0PDpH7wGrciL7xmmDemVOQU Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On 06/26/2014 12:13 AM, Hu Tao wrote: > We already have ROUND_UP but there are similar macros and ROUND_UP-like= > lines all around, replace them with ROUND_UP and clean up similar macro= s. >=20 > Signed-off-by: Hu Tao > --- All of these conversions are correct, so: Reviewed-by: Eric Blake However, without documenting how you found what to convert, I'm quite sure you missed some conversions. In fact, I found at least: util/oslib-win32.c: memory =3D (memory + pagesize - 1) & -pagesize; tcg/ppc/tcg-target.c-#define FRAME_SIZE ((TCG_TARGET_CALL_STACK_OFFSET = \ tcg/ppc/tcg-target.c- + TCG_STATIC_CALL_ARGS_SIZE = \ tcg/ppc/tcg-target.c- + CPU_TEMP_BUF_SIZE = \ tcg/ppc/tcg-target.c- + REG_SAVE_SIZE = \ tcg/ppc/tcg-target.c- + TCG_TARGET_STACK_ALIGN - 1) = \ tcg/ppc/tcg-target.c: & -TCG_TARGET_STACK_ALIGN) block/cow.c: s->cow_sectors_offset =3D (bitmap_size + 511) & ~511; block/qcow.c: header_size =3D (header_size + 7) & ~7; before I quit looking for more. (I just manually read through git grep '[^&]& [~-]' which has a lot of noise for non-rounding uses, but definitely found some missed cases) --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org --TPObW27JGD0PDpH7wGrciL7xmmDemVOQU Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBCAAGBQJTrFCFAAoJEKeha0olJ0NqWUYIAKmvGQIZg5CJlhhmt+atiMNP PRmu75xu8ps65/DV2juzMNWecqOvnmo882SKTAQs4FFZxt32cSIwpmGn1icSMd5b J169nVGucm218FO+2R56mjh/ASAhcyp3DiCGpcrslZ3Yd5gUZ1d2twKuhRXcEoXK sSlVY895KD1iTBrQSYUQxqhpco6kmJ4iLHoXtGmDrPAEAs95ReO3Q6PjnlOy8PAF 2WTMi2iiPnIjdpkDVZRpHKHWidZ8Z6thxN0POXgTQ+r2yVHI3kcXL5MfSLeELH/+ SrnbgTwcc543d2vEShshjC6KAzy/dxd68Bz90sDqOjiVa19+k9HMXUFA1VuV9+g= =izuj -----END PGP SIGNATURE----- --TPObW27JGD0PDpH7wGrciL7xmmDemVOQU--