From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM03-DM3-obe.outbound.protection.outlook.com (mail-dm3nam03on0084.outbound.protection.outlook.com [104.47.41.84]) by dpdk.org (Postfix) with ESMTP id 767DF1B1D0 for ; Sat, 20 Jan 2018 08:25:06 +0100 (CET) Received: from CY4PR03CA0008.namprd03.prod.outlook.com (10.168.162.18) 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.407.7; Sat, 20 Jan 2018 07:25:05 +0000 Received: from BL2FFO11OLC005.protection.gbl (2a01:111:f400:7c09::152) by CY4PR03CA0008.outlook.office365.com (2603:10b6:903:33::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.407.7 via Frontend Transport; Sat, 20 Jan 2018 07:25:04 +0000 Authentication-Results: spf=fail (sender IP is 192.88.168.50) smtp.mailfrom=nxp.com; dpdk.org; dkim=none (message not signed) header.d=none;dpdk.org; 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 BL2FFO11OLC005.mail.protection.outlook.com (10.173.160.91) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.20.428.12 via Frontend Transport; Sat, 20 Jan 2018 07:24:57 +0000 Received: from bf-netperf1.ap.freescale.net (bf-netperf1.ap.freescale.net [10.232.134.28]) by tx30smr01.am.freescale.net (8.14.3/8.14.0) with ESMTP id w0K6GGgj024888; Fri, 19 Jan 2018 23:16:34 -0700 From: Hemant Agrawal To: CC: , , Date: Sat, 20 Jan 2018 11:45:08 +0530 Message-ID: <1516428908-5430-8-git-send-email-hemant.agrawal@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1516428908-5430-1-git-send-email-hemant.agrawal@nxp.com> References: <1516379639-25586-1-git-send-email-hemant.agrawal@nxp.com> <1516428908-5430-1-git-send-email-hemant.agrawal@nxp.com> X-EOPAttributedMessage: 0 X-Matching-Connectors: 131609067045817438; (91ab9b29-cfa4-454e-5278-08d120cd25b8); () X-Forefront-Antispam-Report: CIP:192.88.168.50; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10009020)(7966004)(346002)(39860400002)(376002)(39380400002)(396003)(2980300002)(1109001)(1110001)(339900001)(199004)(189003)(4326008)(107886003)(50226002)(8936002)(81156014)(8676002)(81166006)(47776003)(68736007)(16586007)(54906003)(104016004)(86362001)(575784001)(316002)(2950100002)(6916009)(6666003)(5660300001)(50466002)(105606002)(2351001)(106466001)(508600001)(53936002)(48376002)(36756003)(51416003)(2906002)(356003)(76176011)(85426001)(59450400001)(77096007)(26005)(97736004)(336011)(305945005); 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; BL2FFO11OLC005; 1:h9pJWXoKeJ8FQzHE5xjTNsyNrbKHELJbiQlXqiS/8eE8XQh0kHVkP1fjUNUWG415PugnXb+BSUghCMLFW8kQuoUMx/CpXVWIPlYdMEY+vT5r9Xp9mpluet+gmlTm0kxm MIME-Version: 1.0 Content-Type: text/plain X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: bc2525ef-490f-4840-2b04-08d55fd6ecf1 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(5600026)(4604075)(2017052603307); SRVR:BN3PR03MB2356; X-Microsoft-Exchange-Diagnostics: 1; BN3PR03MB2356; 3:/V5npJJcGtSmxiR4VWPe2fiHAhD049HzP5Go+3KG2L4tKPD1wyKbRqBGfN+hInLZF5gsBtD29HJm+LKCNknfFCScTowo5G32J6SvFU6kYiKzCwGRKCPzniW2sSG/pnw5IowB8P9W6q1hZlOPFYS9igh2BZpmlLm3DY6p+wi5pR4xgqYzVDQbfDN0RYMPE6Hlc7vt19qF0PwqibcQWxbjsT2OXcP7ZN3R/oREb13129mjhFciEsuq3pPEmlWqhYWWBCLW6fMgl2guqCVlTvUsF7cY/jvB49StJLW/2jrUbDLL2fXJ+Hx13wTuaS5vrVFt84E2h+fwU/0H3wa0Kh8JwU559Xafnvo9Dtc1gNssnMA=; 25:vig6lhmCPMO7S+8vhueFQcAp7G3ituygfOY+KnHG0LJ5lAswUwSuN804KgY7X6oC67V3xHrFzVF9naic4ZvnQHoCILhdEimH0lyw2tlrQUij36Z5iIHW1B+lRODBjJfw7Xpuilkg7AwL7FSBltkoADb7PSlymaDmDPsGYvhv48aELeomIhUrEO/sOH3gzDWJrdD4a4T7PHP8xa6ogSn61jUGvq72AlOam+W50jbYIqsQ22sYL1xd4QH2/gYymnE7o0EcCRoT2sAK3vIfZaUCt2p+u47HwndyO8CQhAv/KkekyZvUa1LnnmFGkivsece0lcHjPuLCXk5AH2J1Nbr9Bg== X-MS-TrafficTypeDiagnostic: BN3PR03MB2356: X-Microsoft-Exchange-Diagnostics: 1; BN3PR03MB2356; 31:kPLu1Ah3XQ87lDxLCH0651MuBWW/HRnSvLbQTPEhGWd/zku/QgFfC+tsyUqazT+2J+fOJ7OYyGBNiVew2zjm3anYAiL0/zntw4WTAbuhUghEIRy8EVBvsz6uQacoP/6dCeATdv9Z8Rl8ChNszZhFqeuBNMffpBKYHscpzmMOTr62ws82GMm/QwKNKGKeIZRp4pr9R/Mro9LW3IpTys6E1xmeUwA164lUAXxmFC/TRUk=; 4:08ZL/AtoICO8hF4OaV//hkKR1tAJCwoWq4tgmpAMm+x7430z6yZ6RrBLA3fjkt/z1l7HTycqInDktljF1C1+dfgnhaAwJ/083ZfADYTdZsMHGRNIJX6faSamGo8c89XWwtwgSGwehKUrW6vdGIw1dyMHZy+HwywgibO3u55bLl3BzxsZbmTlXDCZQdyIVPJUXIRaX3BpX25zH9/rnzjgcKhZAumOHUHT2uVfYBmj7iYZTlfjZ9ow0s5+HI/xpvNxRe55Z1JJL1nTSMDader5dHYQGpn2Z/1l4jChio7i8NdhfhS7FKNN1FFQqK5A728Yi7IYKvo0fkttCj956Z10aQ== X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(185117386973197)(275809806118684); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6095135)(2401047)(5005006)(8121501046)(3002001)(93006095)(93001095)(3231023)(2400081)(944501161)(10201501046)(6055026)(6096035)(20161123559100)(201703131430075)(201703131441075)(201703131448075)(201703131433075)(20161123565025)(20161123556025)(20161123561025)(20161123563025)(201708071742011); SRVR:BN3PR03MB2356; BCL:0; PCL:0; RULEID:(100000803101)(100110400095)(400006); SRVR:BN3PR03MB2356; X-Forefront-PRVS: 0558D3C5AC X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; BN3PR03MB2356; 23:R650uckrGLuSaRfB6G9GMIdN+w6VS/8ujOT8Gazc2?= =?us-ascii?Q?esylzrYFLxImJ6WsmS7k/PeMSzX/1vi8yRDUqC8wZHPi42OLLQPzDDp5qHFD?= =?us-ascii?Q?rHUuHVcUvPl8ffMdYwzvTgmQs7WXwnLXGbVhTrlLNDHfdpH1YkfadHJHDud/?= =?us-ascii?Q?LmdfLil05A4cJYeyoSWUsTgcD0h4SQQnFaYmG9SzJunxe7TkTodkTfE5NYUF?= =?us-ascii?Q?ffk02lzDErlMYMSj9/We8PrJ3h+21rMEtaaGEWLs2AVp57J+60FpIukt0nyz?= =?us-ascii?Q?9vXSh5r0klT2BmahCRjLVMVwCBWxGyVWQyYPw+d8YRCNaj572sIw0Gk35kpQ?= =?us-ascii?Q?GJpuA3kcNwVCwlyEz1mF/lHAL6Ab0iArmOpnfKIyPh5XllmINJ+fR6f6QBSz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zuKQQx1qxo56P86EzNzLCkwscj80cNhslMYUK4owYs0LO+t9iuXuKy+P2KHvu0/nJmu8LUHXCKS74qFlH7HlFV941mO/+IYcPdos3VCtbfPS7n0zoz3ZsR68RGwbE2eem8oKNBEEsncFs2ZMAnAaOVd6OyRmfy1zywVIaiYnrXhbJvXX32jWfh51hJtxod8n2biia8OxC6BzXj1EkJbOlOvs6fJof9VB59DpHkJ2jTv1rHgw+h19/iMLFdxFRWZCczQSUjs5zCT5lMCYMRfJe15J+QaNcH53H9bPg==; 5:rFKu2fkFEg9iNJQUgJwpytnKlGbE0wSzZ0Kr5MGF33VsdUqCKlGZlLoq2P3yqC1RiQrjpWNxAtaaC13ojIUZwxuxrPTdel3mW+oIZiduDKpivT95nDQlPEs5fl4PUY5DVIVdOHSmo1yBkg/mZYNvQiPzK/UccfKmjJV4lTwM7gA=; 24:cOWjGQlnsC5EyWJVqKNIAFO09DfvZlUallLxYD/kisfbQI0/6JpQDVBXkJPIi8dBX+RcegO2mZ2XoaoV2cuFemsjxtVgOfnj4n9nS3YHBSI=; 7:A+fG8GvSCFHEvEiVSCslPS/0i/DsLCTgNHTWXNxqZ5FwJXU9/uspS1JFwUVhThlQG39mZRMd2PbxPsQ2/QgdAd9Up0/bAnIb//xuELXbK7nXoI5c92ew+zSt+j+d1p+Bo1OX7pb/zBlUGiEfMKKnG1RrXRSSd/IfBnA4WP5stTBH2iI4D9UsHgOIwu+z3yIRwKqUu3XbX8eW9c7zRyzv4L9Qt0mlIORNIIWfmtjqvgJtkZH7FMu/kL/sQvB23mwV SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-MS-Exchange-CrossTenant-OriginalArrivalTime: 20 Jan 2018 07:24:57.5620 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: bc2525ef-490f-4840-2b04-08d55fd6ecf1 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: [dpdk-dev] [PATCH v5 7/7] dpaa2: register dpaa2 as platform HW mempool on runtime 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: Sat, 20 Jan 2018 07:25:07 -0000 Detect if the DPAA2 mempool objects are present and register it as platform default hw mempool Signed-off-by: Hemant Agrawal --- config/defconfig_arm64-dpaa2-linuxapp-gcc | 1 - drivers/bus/fslmc/portal/dpaa2_hw_dpbp.c | 3 +++ drivers/bus/fslmc/portal/dpaa2_hw_pvt.h | 2 ++ drivers/mempool/dpaa2/dpaa2_hw_mempool.c | 2 +- 4 files changed, 6 insertions(+), 2 deletions(-) diff --git a/config/defconfig_arm64-dpaa2-linuxapp-gcc b/config/defconfig_arm64-dpaa2-linuxapp-gcc index cd3396b..c7d891c 100644 --- a/config/defconfig_arm64-dpaa2-linuxapp-gcc +++ b/config/defconfig_arm64-dpaa2-linuxapp-gcc @@ -26,7 +26,6 @@ CONFIG_RTE_LIBRTE_VHOST_NUMA=n # Compile Support Libraries for DPAA2 # CONFIG_RTE_LIBRTE_DPAA2_MEMPOOL=y -CONFIG_RTE_MBUF_DEFAULT_MEMPOOL_OPS="dpaa2" CONFIG_RTE_LIBRTE_DPAA2_USE_PHYS_IOVA=n # diff --git a/drivers/bus/fslmc/portal/dpaa2_hw_dpbp.c b/drivers/bus/fslmc/portal/dpaa2_hw_dpbp.c index ffad0f5..1dfee25 100644 --- a/drivers/bus/fslmc/portal/dpaa2_hw_dpbp.c +++ b/drivers/bus/fslmc/portal/dpaa2_hw_dpbp.c @@ -20,6 +20,7 @@ #include #include #include +#include #include #include @@ -74,6 +75,8 @@ dpaa2_create_dpbp_device(int vdev_fd __rte_unused, RTE_LOG(DEBUG, PMD, "DPAA2: Added [dpbp.%d]\n", dpbp_id); + rte_mbuf_set_platform_mempool_ops(DPAA2_MEMPOOL_OPS_NAME); + return 0; } diff --git a/drivers/bus/fslmc/portal/dpaa2_hw_pvt.h b/drivers/bus/fslmc/portal/dpaa2_hw_pvt.h index 2e79399..9b1afe8 100644 --- a/drivers/bus/fslmc/portal/dpaa2_hw_pvt.h +++ b/drivers/bus/fslmc/portal/dpaa2_hw_pvt.h @@ -44,6 +44,8 @@ /* Maximum release/acquire from QBMAN */ #define DPAA2_MBUF_MAX_ACQ_REL 7 +#define DPAA2_MEMPOOL_OPS_NAME "dpaa2" + #define MAX_BPID 256 #define DPAA2_MBUF_HW_ANNOTATION 64 #define DPAA2_FD_PTA_SIZE 0 diff --git a/drivers/mempool/dpaa2/dpaa2_hw_mempool.c b/drivers/mempool/dpaa2/dpaa2_hw_mempool.c index 51770d4..d15347b 100644 --- a/drivers/mempool/dpaa2/dpaa2_hw_mempool.c +++ b/drivers/mempool/dpaa2/dpaa2_hw_mempool.c @@ -354,7 +354,7 @@ rte_hw_mbuf_get_count(const struct rte_mempool *mp) } struct rte_mempool_ops dpaa2_mpool_ops = { - .name = "dpaa2", + .name = DPAA2_MEMPOOL_OPS_NAME, .alloc = rte_hw_mbuf_create_pool, .free = rte_hw_mbuf_free_pool, .enqueue = rte_hw_mbuf_free_bulk, -- 2.7.4