From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by dpdk.org (Postfix) with ESMTP id AD97B568B for ; Wed, 9 Dec 2015 15:02:18 +0100 (CET) Received: from orsmga002.jf.intel.com ([10.7.209.21]) by fmsmga102.fm.intel.com with ESMTP; 09 Dec 2015 06:02:09 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.20,403,1444719600"; d="scan'208";a="868015818" Received: from irsmsx102.ger.corp.intel.com ([163.33.3.155]) by orsmga002.jf.intel.com with ESMTP; 09 Dec 2015 06:01:57 -0800 Received: from irsmsx108.ger.corp.intel.com ([169.254.11.23]) by IRSMSX102.ger.corp.intel.com ([169.254.2.251]) with mapi id 14.03.0248.002; Wed, 9 Dec 2015 14:01:55 +0000 From: "De Lara Guarch, Pablo" To: "Xie, Huawei" , "dev@dpdk.org" Thread-Topic: [PATCH v4] Fixes following error on gcc 4.4.7: Thread-Index: AQHRMnwN5ZMiXQjc00eV9KRYm9C7e57Crz5g Date: Wed, 9 Dec 2015 14:01:54 +0000 Message-ID: References: <1449659374-78252-1-git-send-email-pablo.de.lara.guarch@intel.com> <1449663630-83289-1-git-send-email-pablo.de.lara.guarch@intel.com> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [163.33.239.181] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH v4] Fixes following error on gcc 4.4.7: X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 09 Dec 2015 14:02:19 -0000 > -----Original Message----- > From: Xie, Huawei > Sent: Wednesday, December 09, 2015 1:29 PM > To: De Lara Guarch, Pablo; dev@dpdk.org > Cc: yuanhan.liu@linux.intel.com > Subject: Re: [PATCH v4] Fixes following error on gcc 4.4.7: >=20 > On 12/9/2015 8:20 PM, De Lara Guarch, Pablo wrote: > > make: Entering directory `/tmp/dpdk-tmp/examples/vhost' > > CC main.o > [...] > > - rte_ring_sc_dequeue(vpool->ring, (void **)&mbuf); > > + rte_ring_sc_dequeue(vpool->ring, (void *)mbuf); > Here we are expecting the address of &mbuf, not mbuf, which is NULL. > > if (unlikely(mbuf =3D=3D NULL)) { > > LOG_DEBUG(VHOST_DATA, > > "(%"PRIu64") in attach_rxmbuf_zcp: " > > @@ -1801,7 +1801,7 @@ virtio_tx_route_zcp(struct virtio_net *dev, > struct rte_mbuf *m, > > > > /* Allocate an mbuf and populate the structure. */ > > vpool =3D &vpool_array[MAX_QUEUES + vmdq_rx_q]; > > - rte_ring_sc_dequeue(vpool->ring, (void **)&mbuf); > > + rte_ring_sc_dequeue(vpool->ring, (void *)mbuf); > Same as above. > > if (unlikely(mbuf =3D=3D NULL)) { > > struct vhost_virtqueue *vq =3D dev->virtqueue[VIRTIO_TXQ]; > > RTE_LOG(ERR, VHOST_DATA, Right, I will revert to v3 (and fix the title as well, sorry about that).