From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from m15-1.126.com (m15-1.126.com [220.181.15.1]) by dpdk.org (Postfix) with ESMTP id 11BB61396 for ; Fri, 27 Mar 2015 07:53:12 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=126.com; s=s110527; h=Date:From:Subject:MIME-Version:Message-ID; bh=GkdUW NZ2DazwU30N+UaaqHBTE9u1Gr6nJrOkBtJXDmI=; b=KCe55984dO+abVTJqdx6D v4WzTSAl7S1xNM8R6pWiU6Pym88n0WDBibIP/AlWN+GSxQYpWTeA7lntjynq0iSS C8sKIwFco39sYkDe9iolGzzrnluynGQElrpA50cSPgtad2A5HlfwM7+LvuKGxcu6 uYeg3c+q9eUkXyzhYmbFF8= Received: from dpdkdev$126.com ( [106.186.126.128, 203.14.188.254] ) by ajax-webmail-wmsvr1 (Coremail) ; Fri, 27 Mar 2015 14:53:10 +0800 (CST) X-Originating-IP: [106.186.126.128, 203.14.188.254] Date: Fri, 27 Mar 2015 14:53:10 +0800 (CST) From: "Tim Deng" To: "dev@dpdk.org" X-Priority: 3 X-Mailer: Coremail Webmail Server Version SP_ntes V3.5 build 20150119(59087.7062) Copyright (c) 2002-2015 www.mailtech.cn 126com X-CM-CTRLDATA: MGIicGZvb3Rlcl9odG09MzIyOjgx MIME-Version: 1.0 Message-ID: <53bd7211.9ea2.14c5a01800f.Coremail.dpdkdev@126.com> X-CM-TRANSID: AcqowEA5EEZX_hRVFeCZAA--.2889W X-CM-SenderInfo: pgsgyvlhy6ij2wof0z/1tbi7R-Jok0vVy0H4gABsl X-Coremail-Antispam: 1U5529EdanIXcx71UUUUU7vcSsGvfC2KfnxnUU== Content-Type: text/plain; charset=GBK Content-Transfer-Encoding: base64 X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: [dpdk-dev] method to destroy a rte_mempool 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: Fri, 27 Mar 2015 06:53:14 -0000 SGksCgoKV2hhdCdzIHRoZSByaWdodCB3YXkgdG8gZGVzdHJveSBhIHJ0ZV9tZW1wb29sIHJldHVy bmVkIGJ5IHJ0ZV9tZW1wb29sX2NyZWF0ZSgpPwpJIGNhbm5vdCBmaW5kIGFueSBzdWNoIGZ1bmN0 aW9uLCBjb3VsZCBhbnlvbmUgc2hhcmUgc29tZSBoaW50cz8KCgpUaGFua3MsClRpbQ== >From huawei.xie@intel.com Fri Mar 27 08:40:57 2015 Return-Path: Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by dpdk.org (Postfix) with ESMTP id 631861396 for ; Fri, 27 Mar 2015 08:40:57 +0100 (CET) Received: from orsmga002.jf.intel.com ([10.7.209.21]) by fmsmga101.fm.intel.com with ESMTP; 27 Mar 2015 00:40:56 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.11,477,1422950400"; d="scan'208";a="704978382" Received: from pgsmsx107.gar.corp.intel.com ([10.221.44.105]) by orsmga002.jf.intel.com with ESMTP; 27 Mar 2015 00:40:56 -0700 Received: from shsmsx102.ccr.corp.intel.com (10.239.4.154) by PGSMSX107.gar.corp.intel.com (10.221.44.105) with Microsoft SMTP Server (TLS) id 14.3.224.2; Fri, 27 Mar 2015 15:37:48 +0800 Received: from shsmsx101.ccr.corp.intel.com ([169.254.1.36]) by shsmsx102.ccr.corp.intel.com ([169.254.2.198]) with mapi id 14.03.0224.002; Fri, 27 Mar 2015 15:37:47 +0800 From: "Xie, Huawei" To: "Ouyang, Changchun" Thread-Topic: [PATCH v2] virtio: Fix crash issue for secondary process Thread-Index: AdBoYOsDDW9mOcVpQ2ebmouso6tv3A== Date: Fri, 27 Mar 2015 07:37:46 +0000 Message-ID: References: <1426729537-24892-1-git-send-email-changchun.ouyang@intel.com> <1427438150-6673-1-git-send-email-changchun.ouyang@intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Cc: "dev@dpdk.org" Subject: Re: [dpdk-dev] [PATCH v2] virtio: Fix crash issue for secondary process 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: Fri, 27 Mar 2015 07:40:57 -0000 On 3/27/2015 2:35 PM, Ouyang, Changchun wrote:=0A= > It needs Rx function even in the case of secondary process, and it also n= eeds check if=0A= > it supports mergeable feature or not.=0A= >=0A= > Signed-off-by: Changchun Ouyang =0A= > ---=0A= >=0A= > Changes in v2:=0A= > -- Check if it supports mergeable or not for the secondary process.=0A= >=0A= > lib/librte_pmd_virtio/virtio_ethdev.c | 7 ++++++-=0A= > 1 file changed, 6 insertions(+), 1 deletion(-)=0A= >=0A= > diff --git a/lib/librte_pmd_virtio/virtio_ethdev.c b/lib/librte_pmd_virti= o/virtio_ethdev.c=0A= > index 603be2d..0156b56 100644=0A= > --- a/lib/librte_pmd_virtio/virtio_ethdev.c=0A= > +++ b/lib/librte_pmd_virtio/virtio_ethdev.c=0A= > @@ -1115,8 +1115,13 @@ eth_virtio_dev_init(struct rte_eth_dev *eth_dev)= =0A= > eth_dev->dev_ops =3D &virtio_eth_dev_ops;=0A= > eth_dev->tx_pkt_burst =3D &virtio_xmit_pkts;=0A= > =0A= > - if (rte_eal_process_type() =3D=3D RTE_PROC_SECONDARY)=0A= > + if (rte_eal_process_type() =3D=3D RTE_PROC_SECONDARY) {=0A= > + if (vtpci_with_feature(hw, VIRTIO_NET_F_MRG_RXBUF))=0A= > + eth_dev->rx_pkt_burst =3D &virtio_recv_mergeable_pkts;=0A= > + else=0A= > + eth_dev->rx_pkt_burst =3D &virtio_recv_pkts;=0A= > return 0;=0A= > + }=0A= > =0A= > /* Allocate memory for storing MAC addresses */=0A= > eth_dev->data->mac_addrs =3D rte_zmalloc("virtio", ETHER_ADDR_LEN, 0);= =0A= Acked-by: Huawei Xie =0A= =0A=