From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM01-BY2-obe.outbound.protection.outlook.com (mail-by2nam01on0050.outbound.protection.outlook.com [104.47.34.50]) by dpdk.org (Postfix) with ESMTP id BDF0BFE5 for ; Wed, 6 Sep 2017 13:29:14 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=CAVIUMNETWORKS.onmicrosoft.com; s=selector1-cavium-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=Y7UUd5sJQXLT2JvfKFiHMAaSKXX8n2qyEco1PyGrQAI=; b=SPI1NtJQZ/iOYpOwyIEr4dhOALCgFPVct/sYITbOUIiaXwMpPauzoERM0SBt35Hv8V18vWAF/yrtPl0ZP0AYC03ETqcoMD/G7XhUx5ZC2odyZdhNrNYG18adOEhRJ05EOnXPLmuub8/9ApSGKPF4hyepz+JJoX3s24KVhzczWBs= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Santosh.Shukla@cavium.com; Received: from localhost.localdomain (14.140.2.178) by DM5PR07MB3098.namprd07.prod.outlook.com (10.172.85.8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.20.35.12; Wed, 6 Sep 2017 11:29:10 +0000 From: Santosh Shukla To: olivier.matz@6wind.com, dev@dpdk.org Cc: thomas@monjalon.net, jerin.jacob@caviumnetworks.com, hemant.agrawal@nxp.com, Santosh Shukla Date: Wed, 6 Sep 2017 16:58:26 +0530 Message-Id: <20170906112834.32378-1-santosh.shukla@caviumnetworks.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170815060743.21076-1-santosh.shukla@caviumnetworks.com> References: <20170815060743.21076-1-santosh.shukla@caviumnetworks.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [14.140.2.178] X-ClientProxiedBy: BM1PR01CA0080.INDPRD01.PROD.OUTLOOK.COM (10.174.208.148) To DM5PR07MB3098.namprd07.prod.outlook.com (10.172.85.8) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 6fd2afa7-3f7d-400c-4148-08d4f51a7ff3 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(300000500095)(300135000095)(300000501095)(300135300095)(22001)(300000502095)(300135100095)(2017030254152)(300000503095)(300135400095)(2017052603199)(201703131423075)(201703031133081)(201702281549075)(300000504095)(300135200095)(300000505095)(300135600095)(300000506095)(300135500095); SRVR:DM5PR07MB3098; X-Microsoft-Exchange-Diagnostics: 1; DM5PR07MB3098; 3:jsbgo/V0//ofBJS6Di60aJuDfE+htDI4qCL8tL6zzfcuhsN4UFCJcngFbHqHS5ZdGsXFQoARCNMpmp/NtxtLvH0dLvtGodLjag91lP29fgL0IyZrWipeC+v0H52rFZLKw4x+WfJmkscMoiIFF1/qm7vCHWL6B6fb+3fFTgYQyUYRYft2+B6n75/zokhTI/zXMgk9fVQqtbJ9NX/JL7w2adNiMFLBqWGZ9TUf9LMZr1MX+Pa6tDRN8FbHRHVxy+JI; 25:ej2jP5YEhAtoywKEo+dxaW2qtwyTZf1iDlnpvguUnNBHZtyO63Sl1T2zjb2MwKQfNIVvJajkWRLmmrH2naY/TfIjnwhl/KfZWYeOgeXFYVuDsIU1DclfuFmJCpBn0dEq5wc6PmWjMznZp31brRYO3BwZHef6009NBtrGRE8p5QPWVUaOjAfpQ2ydvwbj3cepCGP4p4pbvbg8d6tkqG3SyuTzPoMiin67bNcp+b6mM5SG9XTiPARPK1DifyDz40Dh+mvZI5ESyXP/2MRCiwvqzuNt5/rg0SQWJzWrWymU3xclLth+1nsTH7N2dD082AE2Y+7Klblgogvl6ER0sHx94A==; 31:CEaXLvC4gxtTMKDf25VW9GKwaE6N0aji22XlR1F+oZeLEIAuEnJfk2K/fy71dxFoKirI6O+0qG1Q48fynh4Nd1PT74aLzRHhX+bC7Q1sUie20+6jzNC4u4pPDxJe0hMRUT4TzOo6uyNf/oEP00SpGCW2PKnAwvER0suUvfpDY6SEOCHPPqdj5KeyeUNHynjyBIIzqQVy6WYoKoltUcH92kX3VJIqV5gktPx8RhHe4EA= X-MS-TrafficTypeDiagnostic: DM5PR07MB3098: X-Microsoft-Exchange-Diagnostics: 1; DM5PR07MB3098; 20:KmmyzaTGa49nV/nnFvQgKOxCGwQYW7FoV8l/n98YuaDIVsQHr1b3c6+8n6RZ4XAn6OS8/FI5zJ5TVU6OLAM90CXb97iiK02Uyjxa7CaE+prMl+aXcv3rTVtbFbEJXeuwBOgmiscwrEqoINSNIibPm9/ky0R0Fwu+f0INLxrD0hVqQ1k1YHwUYaPHAIwhFcg0itjH2CyXMF856jSoq8CmbHACO1K2GaMqnUUWsazxTOnC7mLO2KN8XR+qy/zWMGr2VPZ48oU/jh8dPcHf35drEUVxOnmH756RS8l2K7lBpGDhhDy+Al11RVESK374lc4rNZECn7tdli0iapAM8sz5b5u+hb68oDNm1DuxO5/zXir2rRgzWvuxtP0L/9tF/FVprsjmyD7Gxz/gahB0Ah8uZFE2fTFuNFLe/HtUtvQAcduIE2meWk/y5r23HJnm+RW/p/ZCyMlsmHjUe1aDjOcujqNRVCMz6mxsB/vguU0ym6Y2ENHawwmFzRwNu9gdTS9gRwuMPGvtjAu5hiOitzLYQuEA+W3t8PABON+2w1EDRF3jhB6WDYeX6m1mha7nCPlIlmDiOFhrGljVizP9GptP0hiWA9En11fWRKLIfS/dE38=; 4:tsq4oiRMpUzI063yz7q7PWBejOozRr3WkXb5GM7WMbvOW0Nz+omWw2M0dnfhh+CqL5H4+hJbuem6bRq/s4CDrswya73s9lLmvyPRGVG5dFV8U6Yc6wOvjdW7ito8Qr3hKUzd8Ze4VtcIUq96GjKpuBAbjAlpQlrpIOFCWeAHtAJWIsDhWZQlqii4pYjMo3ylEMHYZbFz6dicjrsOabW1Yqno4VJe/yiOTb5kAVx5Cla5p2FbCQXo8HdM6rK3WF5M X-Exchange-Antispam-Report-Test: UriScan:; X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(2401047)(8121501046)(5005006)(93006095)(10201501046)(100000703101)(100105400095)(3002001)(6041248)(20161123560025)(20161123558100)(20161123564025)(20161123555025)(20161123562025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(6072148)(201708071742011)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:DM5PR07MB3098; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:DM5PR07MB3098; X-Forefront-PRVS: 0422860ED4 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(6009001)(6069001)(189002)(199003)(53936002)(42882006)(2950100002)(6666003)(6506006)(6486002)(6306002)(6512007)(50986999)(76176999)(106356001)(36756003)(189998001)(42186005)(105586002)(50466002)(8936002)(50226002)(48376002)(33646002)(8676002)(81156014)(81166006)(7736002)(101416001)(305945005)(966005)(68736007)(6116002)(3846002)(5003940100001)(1076002)(478600001)(5660300001)(72206003)(2906002)(25786009)(97736004)(4326008)(8656003)(4743002)(5009440100003)(110136004)(107886003)(66066001)(53376002)(47776003)(110426004); DIR:OUT; SFP:1101; SCL:1; SRVR:DM5PR07MB3098; H:localhost.localdomain; FPR:; SPF:None; PTR:InfoNoRecords; MX:1; A:1; LANG:en; Received-SPF: None (protection.outlook.com: cavium.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; DM5PR07MB3098; 23:O75pj9mplA9pto+iWgZMnYkaN0OZU0MAozah9F7JY?= =?us-ascii?Q?gFSFGQHsFzcVEiwXgBiB2h6rnlN+BjczYKxaHcy/znkT64o0X7GxrLA6wUts?= =?us-ascii?Q?gxAqM7RVY/qrfqzkqVV+hpO9NK2zWJv5i0cEQmJLrXlEkr78JQwPe2TpgcTR?= =?us-ascii?Q?I0RopU8cRxFBUDP1bLrh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hvOjuMBzr6cCEc+iNaJhd5uxPxCjlw+5gCt0KWcdaJCl3Bk2Ex1vAfO6vUuDBodMyHJ91Vk= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 06 Sep 2017 11:29:10.5216 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 711e4ccf-2e9b-4bcf-a551-4094005b6194 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR07MB3098 Subject: [dpdk-dev] [PATCH v5 0/8] Infrastructure to support octeontx HW mempool manager 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: Wed, 06 Sep 2017 11:29:15 -0000 V5: Includes v4 review change, suggested by Olivier. v4: Include - mempool deprecation changes, refer [1], - patches are rebased against v17.11-rc0. v3: In order to support octeontx HW mempool manager, the common mempool layer must meet below condition. - Object start address should be block size (total elem size) aligned. - Object must have the physically contiguous address within the pool. And right now mempool doesn't support both. Patchset adds infrastrucure to support both condition in a _generic_ way. Proposed solution won't effect existing mempool drivers or its functionality. Summary: Introducing capability flag. Now mempool drivers can advertise their capabilities to common mempool layer(at the pool creation time). Handlers are introduced in order to support capability flag. Flags: * MEMPOOL_F_CAPA_PHYS_CONTIG - If flag is set then Detect whether the object has the physically contiguous address with in a hugepage. * MEMPOOL_F_BLK_ALIGNED_OBJECTS - If flag is set then make sure that object addresses are block size aligned. API: Two handles are introduced: * rte_mempool_ops_get_capability - advertise mempool manager capability. * rte_mempool_ops_update_range - Update start and end address range to HW mempool manager. Change History: v4 --> v5: - Replaced mp param with flags param in xmem_size/_usage() api. (Suggested by Olivier) - Renamed flags from MEMPOOL_F_POOL_BLK_SZ_ALIGNED to MEMPOOL_F_BLK_ALIGNED_OBJECTS (suggested by Olivier) - added flag param in get_capabilities() handle (suggested by Olivier) Refer individual patch for detailed change history. v3 --> v4: * [01 - 02 - 03/07] mempool deprecation notice changes. * [04 - 05 - 06 - 07/07] are v3 patches. v2 --> v3: (Note: v3 work is based on deprecation notice [1], It's for 17.11) * Changed _version.map from 17.08 to 17.11. * build fixes reported by stv_sys. * Patchset rebased on upstream commit: da94a999. v1 --> v2 : * [01/06] Per deprecation notice [1], Changed rte_mempool 'flag' data type from int to unsigned int and removed flag param from _xmem_size/usage api. * [02/06] Incorporated review feedback from v1 [2] (Suggested by Olivier) * [03/06] Renamed flag to MEMPOOL_F_CAPA_PHYS_CONTIG and comment reworded. (Suggested by Olivier per v1 [3]) * [04/06] added new mempool arg in xmem_size/usage. (Suggested by Olivier) * [05/06] patch description changed. - Removed elseif brakcet mix - removed sanity check for alignment - removed extra var delta - Removed __rte_unused from xmem_usage/size and added _BLK_SZ_ALIGN check. (Suggeted by Olivier per v1[4]) * [06/06] Added RTE_FUNC_PTR_OR_RET in rte_mempool_ops_update_ops. Checkpatch status: CLEAN. Thanks. [1] deprecation notice v2: http://dpdk.org/dev/patchwork/patch/27079/ [2] v1: http://dpdk.org/dev/patchwork/patch/25603/ [3] v1: http://dpdk.org/dev/patchwork/patch/25604/ [4] v1: http://dpdk.org/dev/patchwork/patch/25605/ Santosh Shukla (8): mempool: remove unused flags argument mempool: change flags from int to unsigned int mempool: add flags arg in xmem size and usage doc: remove mempool notice mempool: get the mempool capability mempool: detect physical contiguous object in pool mempool: introduce block size align flag mempool: update range info to pool doc/guides/rel_notes/deprecation.rst | 9 --- doc/guides/rel_notes/release_17_11.rst | 7 +++ drivers/net/xenvirt/rte_mempool_gntalloc.c | 7 ++- lib/librte_mempool/rte_mempool.c | 47 +++++++++++--- lib/librte_mempool/rte_mempool.h | 99 ++++++++++++++++++++++-------- lib/librte_mempool/rte_mempool_ops.c | 28 +++++++++ lib/librte_mempool/rte_mempool_version.map | 8 +++ test/test/test_mempool.c | 25 ++++---- test/test/test_mempool_perf.c | 4 +- 9 files changed, 176 insertions(+), 58 deletions(-) -- 2.11.0