From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MmLj2-0002Ny-1z for qemu-devel@nongnu.org; Sat, 12 Sep 2009 02:04:44 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MmLix-0002LW-44 for qemu-devel@nongnu.org; Sat, 12 Sep 2009 02:04:43 -0400 Received: from [199.232.76.173] (port=41422 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MmLiw-0002L8-Qn for qemu-devel@nongnu.org; Sat, 12 Sep 2009 02:04:38 -0400 Received: from mail-ew0-f221.google.com ([209.85.219.221]:44817) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MmLiw-0007UJ-5y for qemu-devel@nongnu.org; Sat, 12 Sep 2009 02:04:38 -0400 Received: by ewy21 with SMTP id 21so1549545ewy.8 for ; Fri, 11 Sep 2009 23:04:37 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: <37d5a3ce941bc89f6d73b8e7bf746952a0074da2.1252699478.git.armbru@redhat.com> References: <37d5a3ce941bc89f6d73b8e7bf746952a0074da2.1252699478.git.armbru@redhat.com> From: Blue Swirl Date: Sat, 12 Sep 2009 09:04:17 +0300 Message-ID: Subject: Re: [Qemu-devel] [PATCH 1/6] Move function definitions out of xilinx.h Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Markus Armbruster , Paul Brook Cc: qemu-devel@nongnu.org On Fri, Sep 11, 2009 at 11:19 PM, Markus Armbruster wro= te: > xilinx.h defines a couple of static inline functions for creating > devices. =C2=A0While that's a fair technique for hot functions, device > initialization is about as cold as it gets. =C2=A0Define them in the devi= ce > source files instead, and keep only declarations in the header. If I understood the qdev plan correctly, this is going to wrong direction. These functions should reside near the instantiation, not in the device code. The current approach looks OK if there are going to be more users of the devices.