From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1L61yU-0005Oa-Rp for qemu-devel@nongnu.org; Fri, 28 Nov 2008 06:57:30 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1L61yS-0005ME-9s for qemu-devel@nongnu.org; Fri, 28 Nov 2008 06:57:30 -0500 Received: from [199.232.76.173] (port=38596 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1L61yS-0005M9-15 for qemu-devel@nongnu.org; Fri, 28 Nov 2008 06:57:28 -0500 Received: from outbound-wa4.frontbridge.com ([216.32.181.16]:35559 helo=WA4EHSOBE004.bigfish.com) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_ARCFOUR_MD5:16) (Exim 4.60) (envelope-from ) id 1L61yR-0000h9-Jc for qemu-devel@nongnu.org; Fri, 28 Nov 2008 06:57:27 -0500 From: Christoph Egger Subject: Re: [Qemu-devel] Re: [PATCH 5/6] qemu fixes Date: Fri, 28 Nov 2008 13:56:54 +0200 References: <200811281139.07092.Christoph.Egger@amd.com> <492FD75E.9040900@siemens.com> In-Reply-To: <492FD75E.9040900@siemens.com> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-15" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Message-ID: <200811281256.54759.Christoph.Egger@amd.com> Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Blue Swirl , Jan Kiszka On Friday 28 November 2008 12:34:54 Jan Kiszka wrote: > Christoph Egger wrote: > > Hi, > > > > This is a series of four patches which improve support > > for qemu on NetBSD. > > > > sys-queue.h defines _SYS_QUEUE_H_ which is also defined by > > the system header. uses SLIST_ENTRY > > on NetBSD, which doesn't exist in sys-queue.h. Therefore, > > include before including sys-queue.h. > > Does this patch (which my mail client unfortunately refuses to cite...) > take into account that we now have TAILQ_FOREACH_SAFE which NetBSD may > lack? Yes, NetBSD has it: #define TAILQ_FOREACH_SAFE(var, head, field, next) \ for ((var) =3D ((head)->tqh_first); \ (var) !=3D NULL && ((next) =3D TAILQ_NEXT(var, field), 1); = \ (var) =3D (next)) Another option to this patch would be: Renaming _SYS_QUEUE_H_ to QEMU_SYS_QUEUE_H_ at least allows to include both sys-queue.h and . If the macros are not compatible, gcc prints a warning about redefining them. Using the -Wredundant-decls warning flag, gcc always prints a warning when you try override or duplicate macro defines and function declarations. Christoph =2D-=20 AMD Saxony, Dresden, Germany Operating System Research Center Legal Information: AMD Saxony Limited Liability Company & Co. KG Sitz (Gesch=E4ftsanschrift): Wilschdorfer Landstr. 101, 01109 Dresden, Deutschland Registergericht Dresden: HRA 4896 vertretungsberechtigter Komplement=E4r: AMD Saxony LLC (Sitz Wilmington, Delaware, USA) Gesch=E4ftsf=FChrer der AMD Saxony LLC: Dr. Hans-R. Deppe, Thomas McCoy