From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 1421AA0487 for ; Fri, 5 Jul 2019 17:40:29 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id C40EA1B9DE; Fri, 5 Jul 2019 17:40:27 +0200 (CEST) Received: from mx0b-0016f401.pphosted.com (mx0a-0016f401.pphosted.com [67.231.148.174]) by dpdk.org (Postfix) with ESMTP id B98F01B9C9 for ; Fri, 5 Jul 2019 17:40:25 +0200 (CEST) Received: from pps.filterd (m0045849.ppops.net [127.0.0.1]) by mx0a-0016f401.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x65FdrP7008032; Fri, 5 Jul 2019 08:40:23 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.com; h=from : to : cc : subject : date : message-id : references : in-reply-to : content-type : content-transfer-encoding : mime-version; s=pfpt0818; bh=K9eiXDE2qt04A/odPLGl3JFnJOZJEavrxgt3ZsMLqKc=; b=XD1K+nczDWhkBuBczUWq3EpTkjfCErwRF8Z+38O+5Mape44WZ0qe8/r8b7C5dkYHPwWi 5jYGHaxjL1cDaEJLLbqkjtr+wr2eqp69yyEuMbnFoxqP9jSG9eLDx47PDwYaJYjH4rjh jerRXrWBF2SQecm2OQ4Lxmcbbohglg1On9V44EWI2ZsEhpJmyMkvRj4Bf7S21IIaKowq XYZO/z2XRfMJE0lAzKKXnEol6geDKIiFxTOmApPIQHZC+6yVR+41V9Y6tAlcbVIz59JF H8bJbcj8Y1ggdTCjKnv1b0wxJbZcvmLBbknjOnxu+NTQgGKKGM84Q9/2PigypivzaarD hA== Received: from sc-exch03.marvell.com ([199.233.58.183]) by mx0a-0016f401.pphosted.com with ESMTP id 2thv9p2u5e-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT); Fri, 05 Jul 2019 08:40:23 -0700 Received: from SC-EXCH04.marvell.com (10.93.176.84) by SC-EXCH03.marvell.com (10.93.176.83) with Microsoft SMTP Server (TLS) id 15.0.1367.3; Fri, 5 Jul 2019 08:40:22 -0700 Received: from NAM05-CO1-obe.outbound.protection.outlook.com (104.47.48.59) by SC-EXCH04.marvell.com (10.93.176.84) with Microsoft SMTP Server (TLS) id 15.0.1367.3 via Frontend Transport; Fri, 5 Jul 2019 08:40:22 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.onmicrosoft.com; s=selector2-marvell-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=K9eiXDE2qt04A/odPLGl3JFnJOZJEavrxgt3ZsMLqKc=; b=KPdH5YRi/jwTiLzZgTOZt9RGR9EScjgWVztPQif+LxMi+E4jiYIdLKWeHF/sReIhLJv4i2KU+KC4pSwmDimtIirQkd+Vl2O4LL1h6Lr1wAV0Uq1ZJw0y1Z8cVLYzKOa61pjl2CK/EpRhoBMWXq6UuutvENzcXnbO+xr0LkKdg64= Received: from MN2PR18MB2848.namprd18.prod.outlook.com (20.179.21.149) by MN2PR18MB2557.namprd18.prod.outlook.com (20.179.84.94) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2052.19; Fri, 5 Jul 2019 15:40:20 +0000 Received: from MN2PR18MB2848.namprd18.prod.outlook.com ([fe80::4447:9459:5386:2e18]) by MN2PR18MB2848.namprd18.prod.outlook.com ([fe80::4447:9459:5386:2e18%7]) with mapi id 15.20.2052.019; Fri, 5 Jul 2019 15:40:20 +0000 From: Harman Kalra To: "reshma.pattan@intel.com" , "olivier.matz@6wind.com" , "thomas@monjalon.net" , "arybchenko@solarflare.com" CC: "dev@dpdk.org" , Jerin Jacob Kollanukkaran , Harman Kalra Thread-Topic: [PATCH v2] app/pdump: enforcing pdump to use sw mempool Thread-Index: AQHVM0fz9SWIF6hWIE+6KJ7qPFyHSA== Date: Fri, 5 Jul 2019 15:40:20 +0000 Message-ID: <1562341193-19641-1-git-send-email-hkalra@marvell.com> References: <1571664.Xf5ZK7gnes@xps> In-Reply-To: <1571664.Xf5ZK7gnes@xps> Accept-Language: en-GB, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: BMXPR01CA0050.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00:2c::14) To MN2PR18MB2848.namprd18.prod.outlook.com (2603:10b6:208:3e::21) x-ms-exchange-messagesentrepresentingtype: 1 x-mailer: git-send-email 2.7.4 x-originating-ip: [115.113.156.2] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 1e9cc807-9243-4fca-7289-08d7015f15b5 x-microsoft-antispam: BCL:0; PCL:0; RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(7168020)(4627221)(201703031133081)(201702281549075)(8990200)(5600148)(711020)(4605104)(1401327)(2017052603328)(7193020); SRVR:MN2PR18MB2557; x-ms-traffictypediagnostic: MN2PR18MB2557: x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:2089; x-forefront-prvs: 008960E8EC x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(4636009)(39850400004)(396003)(346002)(376002)(366004)(136003)(199004)(189003)(52116002)(6512007)(53936002)(6436002)(25786009)(66066001)(6506007)(386003)(6486002)(478600001)(3846002)(6116002)(2501003)(50226002)(68736007)(76176011)(99286004)(107886003)(26005)(36756003)(316002)(55236004)(4326008)(102836004)(54906003)(110136005)(186003)(71190400001)(5660300002)(71200400001)(7736002)(4744005)(2906002)(66446008)(476003)(305945005)(446003)(14444005)(11346002)(2616005)(66476007)(66556008)(8936002)(64756008)(66946007)(86362001)(2201001)(256004)(486006)(81156014)(8676002)(81166006)(73956011)(14454004); DIR:OUT; SFP:1101; SCL:1; SRVR:MN2PR18MB2557; H:MN2PR18MB2848.namprd18.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; A:1; MX:1; received-spf: None (protection.outlook.com: marvell.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: 7XLfoomgRlpmJIRAth8Q7I4OpELE6fBbyXpnpZNwSXWkX5I0ub3iAZmExGqHvOQaGj6HsiIUEpueRfmWngZfkz4uggrrX6qhZsWQ+LXVeYiHBp3xzKi/2ysCB0fIkw4dw1z+U1LhFwrV/wQTsZ02lKHYQvuvx8U4/Duz8QNwql7A8RIeZRl8lvHiU6M+8FX4yLO76zZVCCY+o4/Eg9p7bq9P2mjmn0KbpHygKdHJZt2hmuEDAoeJATHry65zHfTaCVThR3BmkBxFTNUC01QbeEmgL2dsX45SYn1DEcMTPETy4zRYG7TmnTfhpoltMhsb14FRGgUV9On/EdNd+VVtz1tSHDiSd/p5ksbQRIGvC3aCarIiIanhdEQlts8f4WiP07csFzpLz6W4ratjQBkImw7ZEVAhfx0xfUtSWyWXsL8= Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-Network-Message-Id: 1e9cc807-9243-4fca-7289-08d7015f15b5 X-MS-Exchange-CrossTenant-originalarrivaltime: 05 Jul 2019 15:40:20.0974 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 70e1fb47-1155-421d-87fc-2e58f638b6e0 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: hkalra@marvell.com X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN2PR18MB2557 X-OriginatorOrg: marvell.com X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, , definitions=2019-07-05_05:, , signatures=0 Subject: [dpdk-dev] [PATCH v2] app/pdump: enforcing pdump to use sw mempool 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: , Errors-To: dev-bounces@dpdk.org Sender: "dev" A secondary process cannot access HW mempool already initiazed by primary, and neither it can setup its own HW mempool due to its own restrictions. Since dpdk-pdump creates mempool for managing its local mbufs, SW mempool is capable enough to solve this purpose. Signed-off-by: Harman Kalra --- app/pdump/main.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/app/pdump/main.c b/app/pdump/main.c index 80dc924cf..c739ae43d 100644 --- a/app/pdump/main.c +++ b/app/pdump/main.c @@ -604,11 +604,12 @@ create_mp_ring_vdev(void) mbuf_pool =3D rte_mempool_lookup(mempool_name); if (mbuf_pool =3D=3D NULL) { /* create mempool */ - mbuf_pool =3D rte_pktmbuf_pool_create(mempool_name, + mbuf_pool =3D rte_pktmbuf_pool_create_by_ops(mempool_name, pt->total_num_mbufs, MBUF_POOL_CACHE_SIZE, 0, pt->mbuf_data_size, - rte_socket_id()); + rte_socket_id(), + RTE_MBUF_DEFAULT_MEMPOOL_OPS); if (mbuf_pool =3D=3D NULL) { cleanup_rings(); rte_exit(EXIT_FAILURE, --=20 2.18.0