From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:59139) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bBO0Y-0005Z8-Rq for qemu-devel@nongnu.org; Fri, 10 Jun 2016 11:06:03 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bBO0T-0007x0-7J for qemu-devel@nongnu.org; Fri, 10 Jun 2016 11:06:02 -0400 Received: from mx1.redhat.com ([209.132.183.28]:57915) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bBO0T-0007ww-1y for qemu-devel@nongnu.org; Fri, 10 Jun 2016 11:05:57 -0400 References: <1465570872-23642-1-git-send-email-peter.maydell@linaro.org> From: Eric Blake Message-ID: <575AD753.2000609@redhat.com> Date: Fri, 10 Jun 2016 09:05:55 -0600 MIME-Version: 1.0 In-Reply-To: <1465570872-23642-1-git-send-email-peter.maydell@linaro.org> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="a6aJJNb4WJSrgOB3Xr5tfXIlseWbvV4Jh" Subject: Re: [Qemu-devel] [PATCH] migration: Don't use *_to_cpup() List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Maydell , qemu-devel@nongnu.org Cc: Amit Shah , Juan Quintela , patches@linaro.org This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --a6aJJNb4WJSrgOB3Xr5tfXIlseWbvV4Jh Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 06/10/2016 09:01 AM, Peter Maydell wrote: > The *_to_cpup() functions just compose a pointer dereference with > a *_to_cpu() byteswap. Instead use ld*_p(), which handles potential > pointer misaligment and avoids the need to cast the pointer. s/misaligment/misalignment/ >=20 > Signed-off-by: Peter Maydell > --- > The motivation here is that I'd like to get rid of _to_cpup() > entirely: we don't have many places that use it. > --- > migration/migration.c | 12 ++++++------ > 1 file changed, 6 insertions(+), 6 deletions(-) >=20 Reviewed-by: Eric Blake --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org --a6aJJNb4WJSrgOB3Xr5tfXIlseWbvV4Jh 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/ iQEcBAEBCAAGBQJXWtdTAAoJEKeha0olJ0NqI9oH/R/U6zSZ0yV4lZ5He+lkgdF+ qD19LociwPCrB4Cp/Ylzbia4ghY3/UyNK3vep9NJ+9AnAQZ7iQNfbomnyNhk+U38 4LXpJU1L0wYlFjtsYQ7olrJhSOx5rBd82gR44WfRUycbJIRwot/XgmdQAI62ChvN ngR7YlJVB775xCdBo0Q3DUuEySwZv+h+akHXrKFUpEw2SqqIb2tcjav8VUSHec77 SEJFe8gOdY428Gi1HxmD/iSKsdK+ghAsnXyxREX6hOK1DfQGWf3cGM2eSKl61zOL 28o7v4FC0JqC4+iEBMizjL7ChQhK/dBrn0T/k7FrEQ3b/A6VsUNd/DRPE1cCX0k= =pjEG -----END PGP SIGNATURE----- --a6aJJNb4WJSrgOB3Xr5tfXIlseWbvV4Jh--