From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1O0VZV-0006wa-1X for qemu-devel@nongnu.org; Sat, 10 Apr 2010 03:57:41 -0400 Received: from [140.186.70.92] (port=35106 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1O0VZT-0006vs-3F for qemu-devel@nongnu.org; Sat, 10 Apr 2010 03:57:40 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1O0VZR-00060y-Jh for qemu-devel@nongnu.org; Sat, 10 Apr 2010 03:57:38 -0400 Received: from mx1.redhat.com ([209.132.183.28]:57951) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1O0VZR-00060o-CS for qemu-devel@nongnu.org; Sat, 10 Apr 2010 03:57:37 -0400 Message-ID: <4BC02F3F.7050901@redhat.com> Date: Sat, 10 Apr 2010 09:56:47 +0200 From: Kevin Wolf MIME-Version: 1.0 Subject: Re: [Qemu-devel] [PATCH 2/2] block: Convert bdrv_first to QTAILQ References: <1270822934-8623-1-git-send-email-stefanha@linux.vnet.ibm.com> <1270822934-8623-3-git-send-email-stefanha@linux.vnet.ibm.com> <4BBF5A27.8090701@redhat.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Stefan Hajnoczi Cc: Stefan Hajnoczi , qemu-devel@nongnu.org Am 10.04.2010 08:04, schrieb Stefan Hajnoczi: > On Fri, Apr 9, 2010 at 7:17 PM, Stefan Hajnoczi wrote: >> I see three options: >> 1. Leave the search. >> 2. Modify qemu-queue.h to add a QTAILQ_ON_LIST(elm) macro. >> 3. Break the QTAILQ abstraction and test tge_prev directly. > > I see a nicer option: check device_name[0]. Patch v2 sent. Yup, this is exactly what I was just about to suggest. Of course, QTAILQ_ON_LIST would be nice to have either, but I'm afraid it's not possible without putting the loop into that macro. Kevin