From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM01-SN1-obe.outbound.protection.outlook.com (mail-sn1nam01on0044.outbound.protection.outlook.com [104.47.32.44]) by dpdk.org (Postfix) with ESMTP id 2C5241B22F for ; Thu, 12 Oct 2017 13:02:57 +0200 (CEST) Received: from MWHPR03CA0015.namprd03.prod.outlook.com (10.175.133.153) by BN3PR03MB2356.namprd03.prod.outlook.com (10.166.74.151) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.77.7; Thu, 12 Oct 2017 11:02:56 +0000 Received: from BN1AFFO11FD018.protection.gbl (2a01:111:f400:7c10::145) by MWHPR03CA0015.outlook.office365.com (2603:10b6:300:117::25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.77.7 via Frontend Transport; Thu, 12 Oct 2017 11:02:55 +0000 Authentication-Results: spf=fail (sender IP is 192.88.168.50) smtp.mailfrom=nxp.com; intel.com; dkim=none (message not signed) header.d=none;intel.com; dmarc=fail action=none header.from=nxp.com; Received-SPF: Fail (protection.outlook.com: domain of nxp.com does not designate 192.88.168.50 as permitted sender) receiver=protection.outlook.com; client-ip=192.88.168.50; helo=tx30smr01.am.freescale.net; Received: from tx30smr01.am.freescale.net (192.88.168.50) by BN1AFFO11FD018.mail.protection.outlook.com (10.58.52.78) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.20.77.10 via Frontend Transport; Thu, 12 Oct 2017 11:02:55 +0000 Received: from [10.232.133.65] (B10814-12.ap.freescale.net [10.232.133.65]) by tx30smr01.am.freescale.net (8.14.3/8.14.0) with ESMTP id v9CB2q4f000448; Thu, 12 Oct 2017 04:02:53 -0700 To: "Ananyev, Konstantin" , "dev@dpdk.org" References: <1504690460-30616-1-git-send-email-hemant.agrawal@nxp.com> <2601191342CEEE43887BDE71AB9772585FAA80B6@IRSMSX103.ger.corp.intel.com> CC: "ashish.jain@nxp.com" From: Hemant Agrawal Message-ID: Date: Thu, 12 Oct 2017 16:32:52 +0530 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 MIME-Version: 1.0 In-Reply-To: <2601191342CEEE43887BDE71AB9772585FAA80B6@IRSMSX103.ger.corp.intel.com> Content-Type: text/plain; charset="windows-1252"; format=flowed Content-Transfer-Encoding: 7bit X-EOPAttributedMessage: 0 X-Matching-Connectors: 131522797754814964; (91ab9b29-cfa4-454e-5278-08d120cd25b8); () X-Forefront-Antispam-Report: CIP:192.88.168.50; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10009020)(6009001)(336005)(346002)(376002)(39860400002)(39380400002)(2980300002)(1109001)(1110001)(339900001)(3190300001)(13464003)(24454002)(377454003)(199003)(189002)(53936002)(2950100002)(8656003)(76176999)(54356999)(4326008)(33646002)(6246003)(50466002)(64126003)(50986999)(31686004)(104016004)(316002)(58126008)(110136005)(86362001)(2906002)(47776003)(65806001)(2501003)(65956001)(498600001)(189998001)(36756003)(356003)(68736007)(81166006)(8936002)(81156014)(85426001)(8676002)(83506001)(53546010)(23746002)(229853002)(77096006)(106466001)(305945005)(230700001)(65826007)(31696002)(97736004)(105606002)(5660300001); DIR:OUT; SFP:1101; SCL:1; SRVR:BN3PR03MB2356; H:tx30smr01.am.freescale.net; FPR:; SPF:Fail; PTR:InfoDomainNonexistent; A:1; MX:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; BN1AFFO11FD018; 1:8zJKMQZhsfGkk9xBFNdVVOeKW6983fvu6FmglVoIT28c6l+1BxD/xQtLx46Hitx5OnB3pA4vIeXNWMU0reQfBvt5cHkriXtk3m5nDko64L62iOcc1D7iwYpXGoNzLXnM X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: a8fa8dc4-4197-4e73-91f4-08d51160ca81 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(2017052603199)(201703131430075)(201703131517081); SRVR:BN3PR03MB2356; X-Microsoft-Exchange-Diagnostics: 1; BN3PR03MB2356; 3:yBgwszl/ByBq18b2yvTA3XO/bIamA+cBdfaA26RjAkVQ0YO8tE6dHGHDuhYatri0xfnUztkh0TdUpGxf+ovioDLwn3WnwgwV2UnE2Scn/gHZ6zT4yfHtwDKj9z6tunH7ogHDzKiLT8e3h6gipmSyMoELNU8TOYssgUzSKo5wElg2qPzjslgo28rxl4s7ImWLOeElAN9sNAwzZ/Sodo0q8i8kwCh0/bPNmnapaMzW159kdImWvx7g55PAKEteFkr157oWhPqxAizoC9XkFVyccHlInlQeweU1xTOkuMq1j6GWL3wkBXUiK6w9ULtCj6ixWF43I/8cE/3QY2QYE4GJMxSFjntBBjdPMI//MbGcz7s=; 25:Ajt6TcdtYjRJ6p4ZhPgeUsHEDbxdFG6j+4gJjYe0f0dPVi2Bzrv6mETOFQJq21i2xxvYVgEexiNhwfjYUjD944Bs+7SATp9jwuVgG2tPFNKMd9l1Fs2arCscbT/RMn7mXyQBgYsUUV63svzc9OvILu85LRyz9hmQ16Iv5UdV2aRTr3L1brxDxd9ZQOXwGBdn/gcIj2tGy5BpGVRNa6sNFLzP6ty8UXEbI3lwjLHZED2rDMy3ANTln5PK9WepUo1Wg3yzjaLjO/txJYwmcWk4zso9NOS2W2ogrimjlZEfCK3mXHU59fIc6D2IbZYvjPdu1jOVwXt52qHfWXQlKiJCIw== X-MS-TrafficTypeDiagnostic: BN3PR03MB2356: X-Microsoft-Exchange-Diagnostics: 1; BN3PR03MB2356; 31:Mu7CyRuRCz7mOy2fYip+yN2Nx+p0kX0rMTskwDmhmJSv2BKM+KmGNw3WQfDjdWdzkrYm/pITkMsLuI7L8rVfbAs4AY88gszFpJmUKdJIR1KIM5L6KWUWQGyCdlPLgXHD6M4EjLZxB3X5Nd/PwwlhAQk80CkpZ2FLiAZZzkz2n2L6YTQNi5DRojMtcMXKvngT9Ydbge8bP25vICwDof+m1dRdijDhfhCqQN5HnbA91+0=; 4:XsELwFpEUbuMgKc62u5RuL1xbGi9Mn5dYesjB3eggC7tIGo3WGC0VgPHcXD2RVenpr4D1yKHTn64Py83Q4+8C+MMK6NlitG3jjLHrH38ucjm9UWchMsEnnxOny+qDsPAP/4u1me5raf5jbILQLk/PC4jYQ4fqqjVaNJ3yucirod9eYvyiAw+glit2MXdxQ2//qAY7jJ1MKJUOx/Cd1uDXbMaE2WNUBtwZr5r8w+rmq1X5D4RKDBLnvzrf/5Z+4Youqsp+r7SQCYMraBNO4AXe3H2H3e2fGH84vOw1/u8OStqRE2axu9VI6VfdnU2B9NAJiFCaQHxCOgCJGPKf3ygzQ== X-Exchange-Antispam-Report-Test: UriScan:(185117386973197)(228905959029699); X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6095135)(2401047)(8121501046)(5005006)(93006095)(93001095)(3002001)(10201501046)(100000703101)(100105400095)(6055026)(6096035)(201703131430075)(201703131448075)(201703131433075)(201703161259150)(201703151042153)(20161123559100)(20161123563025)(20161123561025)(20161123556025)(20161123565025)(201708071742011)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:BN3PR03MB2356; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(400006)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:BN3PR03MB2356; X-Forefront-PRVS: 04583CED1A X-Microsoft-Exchange-Diagnostics: =?Windows-1252?Q?1; BN3PR03MB2356; 23:jALTbtu0ea+MOj9jiFNqzlWxdqWc7GvV5lg1/?= =?Windows-1252?Q?H4GHLLGpMEHGsHK015bFxGxpht3LI5/zGBICch/xxGb8I7m+nM89V9/Q?= =?Windows-1252?Q?YZMhTj6oadjC/aXV19Mb85TaNhKsGCHbYBPmL1/c5zJCgwV95jxTPWcE?= =?Windows-1252?Q?WQRfaH/CEjFCF7IgZlHJjrhpOAHq2FPxO3Jb45XfuXB6WUZwuQsDbUVa?= =?Windows-1252?Q?nVGZcqbYHb73oizsScU26Zw+LzvkBa8spSKwxDfo5g8VmfPie1AjO1r0?= =?Windows-1252?Q?S5UhK7Bt0fYvMz+ualt6FL9BbYXcgvNawDRA1gfWcRK15AZDHtmFSw5I?= =?Windows-1252?Q?ciNn06UZWRyhRgd1fJaf5W8FvMAEuWhqjO4a2juUObxPK8IkFLEtRG3i?= =?Windows-1252?Q?JEAbVi7jQtk5gI0a0Y3l6qKzmKQtjqgcuU/waUMfwgAlDbgJIfKUreF6?= =?Windows-1252?Q?tFuulyuQU+X1DV2m9XVZEqf54av5BjORv/nsVolG+YUNWwyi0p+WU9jT?= =?Windows-1252?Q?V9qy2UN+Kh89+Pf5E5k3cRkiCQ+2N78ncbieAmNNOqaAckv6PbgcNk/e?= =?Windows-1252?Q?BAw5U/uEvU8cBVXmcm3gvlsUUXzUMoW+AcNIbI2F1fMzwGZyNkThZHbb?= =?Windows-1252?Q?L7seXip3MMeo/3r01kZw2c6gtZLHsLhyBmlrK/b7k8hBRdYyQOpP267D?= =?Windows-1252?Q?AEsa5h1ATHG+6cdb2oS7BIqQ+uALxZh7eVYRjKzJVfDP+62LHRKXLk+M?= =?Windows-1252?Q?blJaofe2mWcvew+KEGGAxwSQVKyrDH1ID7tdhWCgrIHfkY+lOrxGI2Kj?= =?Windows-1252?Q?/MHg25c8RDee2BJ4YKoqt+Q56Kbmoo+BcgWXX/DpKJbdRmRJNXY0qAZV?= =?Windows-1252?Q?op878NI0apqc+MdMM5v/oUVc168os/yD23G/6ivY63oEBkgtdlexazDG?= =?Windows-1252?Q?4cas5nn1xmKYdAb0ZO00/hNQvKV3oLLz2BHpxcWC+YGBCWKcu7WTNfdj?= =?Windows-1252?Q?VbVV55phjyPwrFqR4W12GfpSHhEYNOGqGRSUoqjq67R6RMRUMZFZX92q?= =?Windows-1252?Q?NV+f+uGAbsCCEYMwA6byXiUVCHEsTAC1KZV1NmYJL4nFdgRls0J0RuXl?= =?Windows-1252?Q?+ll+4QqFrGHvYURBmzgpUO+sD0mfMi/gdd4yb9ynE0VbwPDUYmGikTTC?= =?Windows-1252?Q?mwOUL07qVo0lfojzCdMMlVbVnjrrMQKBTnBDBFxVHUmxEwcVjQNURQkV?= =?Windows-1252?Q?yIdp1RUIo7v8Xu8NIqBvAOs/rqP8c/aaLIw9qTuBVO7LM0fssqWHdvmH?= =?Windows-1252?Q?YxNld2LstmUxx8IwrX+Gj0aaxIFZplXBoeCV0soKgA651c9gK93nsHAb?= =?Windows-1252?Q?em8LVh9Oxlz8nNDo0HVScoXtGNJi95b3IbFo+hwZA93dshvLR1XhHmqZ?= =?Windows-1252?Q?598h08fNiSheqJwabF6D+aeu1auFKB/e7drRimBGZWYyddrGacK+FELG?= =?Windows-1252?Q?tJeWBDnayWjlF8kNSmUA2TDfkXDrF7940XaH5EC/3B0tnEiyw=3D=3D?= X-Microsoft-Exchange-Diagnostics: 1; BN3PR03MB2356; 6:BAR7cAdeBc+uS3iWc6zzVF5iYpiaEGTystjplTL0yTPPPyZu3LlpR4Gm3DDoG9falsfcKeRdKuIC5D6jnEzTAshFwyysEP/H77WnI6/a5q3VNlMXJ+D8YR1QL79zRmefrbU0iYJEJQkcNvAhVPxJr4hOgBtCRSAYC/SCHnKNm3P/bxTPftg1hBfFqHIDbeymoMyvRldyyt2FN3mnJlgVpLypt7xt7cHSclFw2BD9y5wQYi+QKvOwGXTIhKsn34P4VpyORXO50ZLyXlYEoB34iyoWU5OqG9I67BojannaBb/wRDia2Nov9+k39OB+Q5NNazPgG52aPkm34Y7j9mnHUg==; 5:2NSCN8b0VwipYeAOysfIsrBB52FfGMxjA/FwzZas9DNCqX1zI1rmwnzFYq1kgvf9f0F30SFa7zxU4ElO4qM/D0Z0wicDw+q4aOPeJrpdfdyZAmFGqIv1mgwbJzHwjeaWeLIQE7JpX3dZ0xeIz+Dmrw==; 24:apAsCMj+TAs42zxtZW+OptCdiHrtZlo9oEvPxboufPeeUY66x/UMg7rSDLfxyXYWytwIObWvVy+Ybe98uIQV/WoeAF8hjwhkw6rlNlktTXI=; 7:iM47VTV3AoaKEQinqm3jC5jxBWkBAn9hYTT01gku7u54H5LYLXvwHMu9CQw46AEMOyH+8Lpw1xZsLW8RkOM7SEwYGSOiVmACx0JA6vmsiJZio2xMOmMg7SEtSC+WNpHIamtyF1zpBJbPzQImBoLmoWeE3SFiA/8oyYZ1um5lToUWhas3zvIElJca77nz6PhoyVYtjWlg0LA9TvbHvtRBdEUSrJLKwI/5UAo9jJb4t9k= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-MS-Exchange-CrossTenant-OriginalArrivalTime: 12 Oct 2017 11:02:55.3098 (UTC) X-MS-Exchange-CrossTenant-Id: 5afe0b00-7697-4969-b663-5eab37d5f47e X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=5afe0b00-7697-4969-b663-5eab37d5f47e; Ip=[192.88.168.50]; Helo=[tx30smr01.am.freescale.net] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN3PR03MB2356 Subject: Re: [dpdk-dev] [PATCH] examples/ip_reassembly: use pktmbuf to create pool 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: Thu, 12 Oct 2017 11:02:57 -0000 On 10/12/2017 4:08 PM, Ananyev, Konstantin wrote: > > >> -----Original Message----- >> From: Hemant Agrawal [mailto:hemant.agrawal@nxp.com] >> Sent: Wednesday, September 6, 2017 10:34 AM >> To: dev@dpdk.org >> Cc: Ananyev, Konstantin ; ashish.jain@nxp.com >> Subject: [PATCH] examples/ip_reassembly: use pktmbuf to create pool >> >> From: Ashish Jain >> >> Use of rte_mempool_create() with the helper provided in >> librte_mbuf: rte_pktmbuf_pool_create(). >> This is the preferred way to create a mbuf pool else >> it may not work on implementation using the HW buffer pool >> >> Signed-off-by: Ashish Jain >> --- >> examples/ip_reassembly/main.c | 13 ++++++------- >> 1 file changed, 6 insertions(+), 7 deletions(-) >> >> diff --git a/examples/ip_reassembly/main.c b/examples/ip_reassembly/main.c >> index e62636c..20caeb3 100644 >> --- a/examples/ip_reassembly/main.c >> +++ b/examples/ip_reassembly/main.c >> @@ -84,8 +84,7 @@ >> #define MAX_JUMBO_PKT_LEN 9600 >> >> #define BUF_SIZE RTE_MBUF_DEFAULT_DATAROOM >> -#define MBUF_SIZE \ >> - (BUF_SIZE + sizeof(struct rte_mbuf) + RTE_PKTMBUF_HEADROOM) >> +#define MBUF_DATA_SIZE RTE_MBUF_DEFAULT_BUF_SIZE >> >> #define NB_MBUF 8192 >> >> @@ -909,11 +908,11 @@ setup_queue_tbl(struct rx_queue *rxq, uint32_t lcore, uint32_t queue) >> >> snprintf(buf, sizeof(buf), "mbuf_pool_%u_%u", lcore, queue); >> >> - if ((rxq->pool = rte_mempool_create(buf, nb_mbuf, MBUF_SIZE, 0, >> - sizeof(struct rte_pktmbuf_pool_private), >> - rte_pktmbuf_pool_init, NULL, rte_pktmbuf_init, NULL, >> - socket, MEMPOOL_F_SP_PUT | MEMPOOL_F_SC_GET)) == NULL) { >> - RTE_LOG(ERR, IP_RSMBL, "mempool_create(%s) failed", buf); >> + rxq->pool = rte_pktmbuf_pool_create(buf, nb_mbuf, 0, 0, >> + MBUF_DATA_SIZE, socket); > > As we can't pass SC|SP anymore can we then setup mempool cache size to some non-zero value? > Konstantin > #define MEMPOOL_CACHE_SIZE 256 do you think "256" will be ok? >> + if (rxq->pool == NULL) { >> + RTE_LOG(ERR, IP_RSMBL, >> + "rte_pktmbuf_pool_create(%s) failed", buf); >> return -1; >> } >> >> -- >> 2.7.4 > >