From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:56570) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aHTAS-0002ia-Uh for qemu-devel@nongnu.org; Fri, 08 Jan 2016 04:17:09 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aHTAN-0000jJ-RV for qemu-devel@nongnu.org; Fri, 08 Jan 2016 04:17:08 -0500 Received: from e06smtp17.uk.ibm.com ([195.75.94.113]:38038) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aHTAN-0000jB-Gx for qemu-devel@nongnu.org; Fri, 08 Jan 2016 04:17:03 -0500 Received: from localhost by e06smtp17.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Fri, 8 Jan 2016 09:17:02 -0000 Received: from b06cxnps4074.portsmouth.uk.ibm.com (d06relay11.portsmouth.uk.ibm.com [9.149.109.196]) by d06dlp03.portsmouth.uk.ibm.com (Postfix) with ESMTP id C08D31B08067 for ; Fri, 8 Jan 2016 09:17:41 +0000 (GMT) Received: from d06av05.portsmouth.uk.ibm.com (d06av05.portsmouth.uk.ibm.com [9.149.37.229]) by b06cxnps4074.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id u089GxGe5177692 for ; Fri, 8 Jan 2016 09:16:59 GMT Received: from d06av05.portsmouth.uk.ibm.com (localhost [127.0.0.1]) by d06av05.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id u089GxDX020532 for ; Fri, 8 Jan 2016 02:16:59 -0700 Date: Fri, 8 Jan 2016 10:16:56 +0100 From: Greg Kurz Message-ID: <20160108101656.7162631d@bahia.local> In-Reply-To: <568EC2C6.2020604@redhat.com> References: <20160107110747.10897.41118.stgit@bahia.huguette.org> <20160107113214.10897.50820.stgit@bahia.huguette.org> <568EC2C6.2020604@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 3/6] virtio: drop the virtio_needs_swap() helper List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Laurent Vivier Cc: qemu-devel@nongnu.org, "Michael S. Tsirkin" On Thu, 7 Jan 2016 20:55:50 +0100 Laurent Vivier wrote: > > > On 07/01/2016 12:32, Greg Kurz wrote: > > It is not used anymore. > > > > Signed-off-by: Greg Kurz > > --- > > include/hw/virtio/virtio-access.h | 9 --------- > > 1 file changed, 9 deletions(-) > > > > diff --git a/include/hw/virtio/virtio-access.h b/include/hw/virtio/virtio-access.h > > index 8aec843c8ff3..a01fff2e51d7 100644 > > --- a/include/hw/virtio/virtio-access.h > > +++ b/include/hw/virtio/virtio-access.h > > @@ -143,15 +143,6 @@ static inline uint64_t virtio_ldq_p(VirtIODevice *vdev, const void *ptr) > > } > > } > > > > -static inline bool virtio_needs_swap(VirtIODevice *vdev) > > -{ > > -#ifdef HOST_WORDS_BIGENDIAN > > - return virtio_access_is_big_endian(vdev) ? false : true; > > -#else > > - return virtio_access_is_big_endian(vdev) ? true : false; > > -#endif > > -} > > - > > I think you can move this to PATCH 1/6 too. > I usually prefer to separate cleanup from functional changes, but indeed this one is trivial... I'll do that and we will see if it helps when I re-post. > > static inline uint16_t virtio_tswap16(VirtIODevice *vdev, uint16_t s) > > { > > #ifdef HOST_WORDS_BIGENDIAN > > > > >