From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:33249) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UQhi0-0000yN-Sj for qemu-devel@nongnu.org; Fri, 12 Apr 2013 13:24:25 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UQhhu-0001wq-On for qemu-devel@nongnu.org; Fri, 12 Apr 2013 13:24:20 -0400 Received: from e23smtp09.au.ibm.com ([202.81.31.142]:51833) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UQhhu-0001w1-6z for qemu-devel@nongnu.org; Fri, 12 Apr 2013 13:24:14 -0400 Received: from /spool/local by e23smtp09.au.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Sat, 13 Apr 2013 03:15:06 +1000 Received: from d23relay03.au.ibm.com (d23relay03.au.ibm.com [9.190.235.21]) by d23dlp02.au.ibm.com (Postfix) with ESMTP id 6186E2BB0053 for ; Sat, 13 Apr 2013 03:23:54 +1000 (EST) Received: from d23av01.au.ibm.com (d23av01.au.ibm.com [9.190.234.96]) by d23relay03.au.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id r3CHNmp764487468 for ; Sat, 13 Apr 2013 03:23:48 +1000 Received: from d23av01.au.ibm.com (loopback [127.0.0.1]) by d23av01.au.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id r3CHNqMI030290 for ; Sat, 13 Apr 2013 03:23:53 +1000 Date: Sat, 13 Apr 2013 02:47:15 +1000 From: David Gibson Message-ID: <20130412164715.GL5065@truffula.fritz.box> References: <1365730875-22854-1-git-send-email-aik@ozlabs.ru> <5167E747.2020106@suse.de> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="NZiXfHLGvOGtDZMn" Content-Disposition: inline In-Reply-To: <5167E747.2020106@suse.de> Subject: Re: [Qemu-devel] [PATCH] bswap: fix compiler warning List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Andreas =?iso-8859-1?Q?F=E4rber?= Cc: Anthony Liguori , Alexey Kardashevskiy , Stefan Hajnoczi , qemu-devel@nongnu.org, Blue Swirl , Paolo Bonzini , Richard Henderson --NZiXfHLGvOGtDZMn Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Apr 12, 2013 at 12:51:51PM +0200, Andreas F=E4rber wrote: > Am 12.04.2013 03:41, schrieb Alexey Kardashevskiy: > > The bswap functions use memcpy but the bswap.h header itself does not s= eem to > > include it in some configuration such as cross compiling for powerpc64 > > on x86_64 machine (gcc 4.6.3 from ftp.kernel.org, headers/libs from FC1= 8/ppc64), > > the example warning is below. > >=20 > > The patch explicitly includes string.h. > >=20 > > CC ppc64-softmmu/hw/virtio/virtio.o > > In file included from /home/alexey/qemu/include/libfdt_env.h:22:0, > > from /home/alexey/qemu/../lib4qemu/usr/include/libfdt.= h:54, > > from /home/alexey/qemu/hw/nvram/spapr_nvram.c:25: > > /home/alexey/qemu/include/qemu/bswap.h: In function 'lduw_p': > > /home/alexey/qemu/include/qemu/bswap.h:244:5: warning: implicit declara= tion of function 'memcpy' [-Wimplicit-function-declaration] > > /home/alexey/qemu/include/qemu/bswap.h:244:5: warning: incompatible imp= licit declaration of built-in function 'memcpy' [enabled by default] > >=20 > > Signed-off-by: Alexey Kardashevskiy > > --- > > include/qemu/bswap.h | 2 ++ > > 1 file changed, 2 insertions(+) > >=20 > > diff --git a/include/qemu/bswap.h b/include/qemu/bswap.h > > index d3af35d..d50de0d 100644 > > --- a/include/qemu/bswap.h > > +++ b/include/qemu/bswap.h > > @@ -1,6 +1,8 @@ > > #ifndef BSWAP_H > > #define BSWAP_H > > =20 > > +#include > > + > > #include "config-host.h" > > #include > > #include >=20 > Including string.h is certainly the right thing to do, but why do you > single it out first? Yeah, it probably shouldn't go above the config header. Otherwise it's the right thing. --=20 David Gibson | I'll have my music baroque, and my code david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_ | _way_ _around_! http://www.ozlabs.org/~dgibson --NZiXfHLGvOGtDZMn Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (GNU/Linux) iEYEARECAAYFAlFoOpMACgkQaILKxv3ab8ZOmACdHnK9FHHd78b1oA9JhHny28Gy /n4AoIfeAWH+R6U4ixKryOPmEeIe6M0O =OxxR -----END PGP SIGNATURE----- --NZiXfHLGvOGtDZMn--