From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by dpdk.org (Postfix) with ESMTP id 6AF552BF2 for ; Mon, 19 Mar 2018 09:18:21 +0100 (CET) X-Amp-Result: UNSCANNABLE X-Amp-File-Uploaded: False Received: from fmsmga007.fm.intel.com ([10.253.24.52]) by orsmga101.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 19 Mar 2018 01:18:20 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.48,329,1517904000"; d="scan'208";a="25155056" Received: from debian.sh.intel.com (HELO debian) ([10.67.104.164]) by fmsmga007.fm.intel.com with ESMTP; 19 Mar 2018 01:18:18 -0700 Date: Mon, 19 Mar 2018 16:16:44 +0800 From: Tiwei Bie To: Jens Freimann Cc: dev@dpdk.org, yliu@fridaylinux.org, maxime.coquelin@redhat.com, mst@redhat.com Message-ID: <20180319081644.lkwamldbwgqcd4ge@debian> References: <20180316152120.13199-1-jfreimann@redhat.com> <20180316152120.13199-4-jfreimann@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20180316152120.13199-4-jfreimann@redhat.com> User-Agent: NeoMutt/20170113 (1.7.2) Subject: Re: [dpdk-dev] [PATCH 03/17] net/virtio: add virtio 1.1 defines X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 19 Mar 2018 08:18:21 -0000 On Fri, Mar 16, 2018 at 04:21:06PM +0100, Jens Freimann wrote: > Signed-off-by: Jens Freimann > --- > drivers/net/virtio/virtio_ring.h | 6 ++++++ > 1 file changed, 6 insertions(+) > > diff --git a/drivers/net/virtio/virtio_ring.h b/drivers/net/virtio/virtio_ring.h > index fc45e34..6eb0077 100644 > --- a/drivers/net/virtio/virtio_ring.h > +++ b/drivers/net/virtio/virtio_ring.h > @@ -17,6 +17,12 @@ > /* This means the buffer contains a list of buffer descriptors. */ > #define VRING_DESC_F_INDIRECT 4 > > +#define VIRTQ_DESC_F_AVAIL 7 > +#define VIRTQ_DESC_F_USED 15 It's better to use consistent prefix (VRING_DESC_F_ instead of VIRTQ_DESC_F_). Besides, maybe it's better to define them as (1ULL << 7) and (1ULL << 15) to make them consistent with the definitions of other VRING_DESC_F_* flags. > +#define DESC_USED (1ULL << VIRTQ_DESC_F_USED) > +#define DESC_AVAIL (1ULL << VIRTQ_DESC_F_AVAIL) > + > + There is no need to add two blank lines here. Thanks > /* The Host uses this in used->flags to advise the Guest: don't kick me > * when you add a buffer. It's unreliable, so it's simply an > * optimization. Guest will still kick if it's out of buffers. */ > -- > 1.8.3.1 >