From patchwork Sat Sep 16 10:52:26 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hemant Agrawal X-Patchwork-Id: 112794 Delivered-To: patch@linaro.org Received: by 10.140.106.117 with SMTP id d108csp1616018qgf; Sat, 16 Sep 2017 03:55:49 -0700 (PDT) X-Google-Smtp-Source: AOwi7QBD3rgrmeILIToyBVOFLk9nPoSNJLaFswQKkAN97T4f5kRl65w7sYx3NvU1x76lLkXdrxRz X-Received: by 10.28.17.207 with SMTP id 198mr4649809wmr.38.1505559349005; Sat, 16 Sep 2017 03:55:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1505559348; cv=none; d=google.com; s=arc-20160816; b=JNLNPRfeqQr8VGM1kOd50hzKQXlSPH2nlCN+aVEC/ymTGuGRGr8ApY79ahbgQINd7t bocNBj3BAeDxYznE99oxL6EwddC9jW05bUP2dfFPUwFjaUUEZmZfUIJ03hM/zz3IrJHg pkkIeHApXDaG7H0ieHDsVPMOib5blt9/bTURMUTFVKtOZvV3zo5YauEWcr1dPjm/L3ec AeXwvffZKrGfZ/mMCG+H3/0reu+IVQRXgiBGna/SMApwLQXdSlHJ/TJHfK7BEtkLDSTv lNhtbNIG7Tl6iZ3KjsQ4V784HmrIA6p6l5vI/6okstYB80n3LFUbsSooG4W/eVxKMNZJ PlyQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:subject:spamdiagnosticmetadata :spamdiagnosticoutput:mime-version:references:in-reply-to:message-id :date:cc:to:from:arc-authentication-results; bh=R4zj7WJFxUNcjO4OX3hDbevwrhn2uGTZkTCwVBIr2kM=; b=oOHOApn/0qs8oo5ootDyoraWemyoBF+2sFkHc/mx8uDMlp1ofCj21ulRozBpO4ECfo r8VAZNwut4l8IhToZMQgbzPTewyRoBcRQlFd8QF+zh3jATX/Dg4nRn8dDhWNSb9AQrwe qcQLoARfHn5N/jWLE75qVkn4870q1SgSD7zSjN9SMRn5fgK3CJIxGNvOJYCEujYmHnbE EceZfW3uB7JT61VDeGv2KCTQU9ML8ZPzZolcObnr36OWK5TtAng6AvyGIuQDolYpppTG 7fbX+uPntjRKfyxwZAfkUP4ebU25EAK9BnfiEOcAk/pYycjG8rwOeqhLWJprtK/Q6Tc6 CmXg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of dev-bounces@dpdk.org designates 92.243.14.124 as permitted sender) smtp.mailfrom=dev-bounces@dpdk.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Return-Path: Received: from dpdk.org (dpdk.org. [92.243.14.124]) by mx.google.com with ESMTP id h189si683154wmf.89.2017.09.16.03.55.48; Sat, 16 Sep 2017 03:55:48 -0700 (PDT) Received-SPF: pass (google.com: domain of dev-bounces@dpdk.org designates 92.243.14.124 as permitted sender) client-ip=92.243.14.124; Authentication-Results: mx.google.com; spf=pass (google.com: domain of dev-bounces@dpdk.org designates 92.243.14.124 as permitted sender) smtp.mailfrom=dev-bounces@dpdk.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 6971F1B1EC; Sat, 16 Sep 2017 12:53:41 +0200 (CEST) Received: from NAM01-BY2-obe.outbound.protection.outlook.com (mail-by2nam01on0068.outbound.protection.outlook.com [104.47.34.68]) by dpdk.org (Postfix) with ESMTP id 298A81B1B8 for ; Sat, 16 Sep 2017 12:53:33 +0200 (CEST) Received: from BN3PR03CA0116.namprd03.prod.outlook.com (10.174.66.34) by MWHPR03MB2704.namprd03.prod.outlook.com (10.168.207.138) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.56.11; Sat, 16 Sep 2017 10:53:31 +0000 Received: from BL2FFO11OLC008.protection.gbl (2a01:111:f400:7c09::112) by BN3PR03CA0116.outlook.office365.com (2603:10b6:400:4::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.56.11 via Frontend Transport; Sat, 16 Sep 2017 10:53:31 +0000 Authentication-Results: spf=fail (sender IP is 192.88.168.50) smtp.mailfrom=nxp.com; nxp.com; dkim=none (message not signed) header.d=none;nxp.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 BL2FFO11OLC008.mail.protection.outlook.com (10.173.160.143) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.20.13.11 via Frontend Transport; Sat, 16 Sep 2017 10:53:31 +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 v8GAr6ux028328; Sat, 16 Sep 2017 03:53:29 -0700 From: Hemant Agrawal To: CC: , Date: Sat, 16 Sep 2017 16:22:26 +0530 Message-ID: <1505559161-29222-13-git-send-email-hemant.agrawal@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1505559161-29222-1-git-send-email-hemant.agrawal@nxp.com> References: <1504860327-18451-1-git-send-email-hemant.agrawal@nxp.com> <1505559161-29222-1-git-send-email-hemant.agrawal@nxp.com> X-EOPAttributedMessage: 0 X-Matching-Connectors: 131500328112913426; (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)(376002)(39380400002)(346002)(39860400002)(2980300002)(1110001)(1109001)(339900001)(189002)(199003)(48376002)(356003)(50986999)(5660300001)(36756003)(316002)(305945005)(68736007)(76176999)(47776003)(50466002)(53936002)(4326008)(6666003)(16586007)(85426001)(104016004)(110136004)(54906002)(498600001)(2351001)(5003940100001)(86362001)(189998001)(33646002)(77096006)(8936002)(2906002)(97736004)(6916009)(2950100002)(8676002)(105606002)(106466001)(81156014)(81166006)(8656003)(50226002); DIR:OUT; SFP:1101; SCL:1; SRVR:MWHPR03MB2704; H:tx30smr01.am.freescale.net; FPR:; SPF:Fail; PTR:InfoDomainNonexistent; MX:1; A:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; BL2FFO11OLC008; 1:qJPdlGJbslh0ARR6sufFDLTQxu5f4vGkXFRF4GFs5GTC5sr6AXfbWAphEZA8/oZXq1yBJxEM1Hg4+taY47xIjIkQ58bBBpD/I7nfkyiiJv9EupIi/p2fTxVpOMfwgLxK MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: ef52c69d-1efa-4665-1ab5-08d4fcf12b79 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(300000500095)(300135000095)(300000501095)(300135300095)(22001)(300000502095)(300135100095)(300000503095)(300135400095)(2017052603199)(201703131430075)(201703131517081)(300000504095)(300135200095)(300000505095)(300135600095)(300000506095)(300135500095); SRVR:MWHPR03MB2704; X-Microsoft-Exchange-Diagnostics: 1; MWHPR03MB2704; 3:24WTfMB55pHPkcY2Yzo22tkWjhdG5+jl6c1VQspwEUJuI3kU4C2vVyM8ykxDp/pNu9ufrD2xm7BH5NOKnlOOaHwQ+42We1dzSX7SHJmyqY8o2XrR8D4i6PO8pifP15bTUBLG5t5MAgG/BY46cVFcrMJlsHYzew2GiSQPGKM68V+ZhPw4PyvDqTGWGZQPCPE5dFQJ9TJRAFSM1+zOAov+1k4rxkD3oI6uQEdSLiJHF1toZGEO3eS5j7YfLMFWCCXl9QRBGhSxhVE3P7+DBtUIuuKOYnT18iPTN9MboJ3oUJxVQZJ5YJTSPw2U7OHrJAIAl6U1NDJLLBAljMycxw/QttVtJmO4FRG6dgufp0wWnbk=; 25:CoR/D6f17hMJEYA/+98niZHm9cs+8+ps0vbz3zscFTqS0EJuN4om0EBm7RAIh/gg2zp/BWRxhS7cBb/oWl1aV/tenI9tPkGS3jIp3YuPc/sYyRVEfMu03mIzC7UqqCpt9D9VXhQcmLrd0OcJRcND0zDm2h4CqOSCX2tJf9FweAem2lXhoCno3PvdC6dcO+gGtWNQw5L0F5Aoeqno3Qt9PrIYk67W54gDOI6/9mNJMAFTXVdEzJK22T6rxUHtpec5XxtH4+IiNX6UkGR67HpYM0rgHNt/qFQph6KOSIPMF5eaOwDyuN7jQcNUcDnviZDzRQTWAxt1iScF1zwmXzzTkg== X-MS-TrafficTypeDiagnostic: MWHPR03MB2704: X-Microsoft-Exchange-Diagnostics: 1; MWHPR03MB2704; 31:rrfMI32cB5+eWiGkNBhoeYzSj6K5ouQjOkdTyEDWo4761vhr7T5+dkTX6jKugppJyOHqc0we/FWeYeKIy/wu05wnDEMRUv9BHzRcA2BBvx3M0kKt2rLGr2aAaRpZ9o9m75fChLudVuGmJ/YLmrSmkRv1VBp6dEVR/EHnw0bhInDitfcRyGlW7ktFmK55rvEHqaZHEcHwZzhVsT5xfnBuhv0/KECBGU7NJfE5Rqp1p+I=; 4:yv8LzarBse16msdA90bpbXz7d43IZDjbG8gLbe9VN+5vRuxc7Zxt0QI4jb4LeukmYFNQ4o47J5kFhRpNFRYLYsGuMpVNvxuf2qFQz0QqM9DpCrfEqmWd6Hz4y4/TjYPR8FbnxaU04yMNRgHd/GgNURLg0PgotzwAzImjaBIFvLqSMifDbt6PW603Hxf265LFWNB+Yb1zz1bw+4gX8WRI/JCH0aT0lsc6wnf/sTJlnIR2CxFIv3PKQKperKidgnE+z2eVKkGBJC9IooiXxNTrAHVLKugC7+pbZ8LYBf74QSXIhE4yKAXOQ6okgGz67TqzqC0zpUvfLTY+g4pcnyjwqw== X-Exchange-Antispam-Report-Test: UriScan:(185117386973197)(275809806118684); X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6095135)(2401047)(5005006)(8121501046)(93006095)(93001095)(3002001)(100000703101)(100105400095)(10201501046)(6055026)(6096035)(201703131430075)(201703131433075)(201703131448075)(201703161259150)(201703151042153)(20161123559100)(20161123563025)(20161123556025)(20161123561025)(20161123565025)(201708071742011)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:MWHPR03MB2704; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(400006)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:MWHPR03MB2704; X-Forefront-PRVS: 0432A04947 X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; MWHPR03MB2704; 23:xLBtuw/j825YQ2dhPBzz+TTIuwzmLLO34yd5S0OTe?= WeCtbkBF40Ydww7W1rKf7jruaKan8CraQghIuWjZyU50z0fhDL1d6rSTjdUeyX4gPvd6Qvxp76Y0EVPnmivu4PLZn4DCB0gVFpBVv8rjLpm4F+it7M+tdJlsHgYzifA2163l31qGzMWsAh8H/1MwVOAWgUUz0cUwHZcTLjIPMSKpHkJWG5RO0igTI3loQ7fE4xr7gYBy9a2xeN4mJy6rbNc5h6ilGY76vF2S76VbkI7t9waW0tf36/8eVpYOuNmZxILlzVZu3YZF6fvCmEkpm7NsBnsoTyLTq/6fnT31/lK7/3eTRrqiChdf6IBWpTA6Pn632KgbHzItlYkntCXWuI1z96BfAfmoBk+eaj/2ttVhshEPs0jAlNfdYOBbI2WnTPw6XqdP9qz8J7+8cbswFdAd9pt9+txA0PDgCmLV1RM8GSjNKw2pTCMcHpshyQwW28ijr0bdJlSpllhgm/0R0wXz1TwdbkQMMEKKX7zLANrj2+SzPPt9f6sAi2Mh8X4DxsVPIgMaueFBtOCZhzyR5c2g36tVqtva5N8E0FulXew7CbBzvy/fv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TVHxC5zbt21357OWQ18RfE46wSapp8XoXgd3DabLiuTj/BrrC+gP5N72Q1wupB0PcYd9Mg=; 24:FZnCKvve2ZI6skiiW+qlHWRLWqcY6ZO3Bg+pYvDasPzZPBXvLjPyYDZU2b3tTH1TuOTRQjNOk+wRYWAKvlKgRvfG3fufIvbsGJNfBTFapV0=; 7:FOrExHBeWGXGzkvwoZo6Fo2iP4mGOwqkH6QQm4Wqxmqus1fw32KnkbKzS+kxEo9lTVN7PZmhJTdxKOGpOO8VjNjwKJp1Co1b/06BlT4mB9BcxItfF/RROZg/84PCcK0BIIQpXW+22Q+xY2oolSzYE7QS6ZW5WQL/9+lMcpfH6JJ4OS2hmgPP/F5Ha8EGNtoJGneEL3nDpWj2Sd0AEWCPC2sS5PW9jXpt3vtEplc9jQo= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-MS-Exchange-CrossTenant-OriginalArrivalTime: 16 Sep 2017 10:53:31.1197 (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: MWHPR03MB2704 Subject: [dpdk-dev] [PATCH v3 12/27] bus/fslmc: add support to check dpbp presence 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" Signed-off-by: Hemant Agrawal --- drivers/bus/fslmc/portal/dpaa2_hw_dpbp.c | 7 +++++++ drivers/bus/fslmc/portal/dpaa2_hw_pvt.h | 1 + drivers/bus/fslmc/rte_bus_fslmc_version.map | 1 + 3 files changed, 9 insertions(+) -- 2.7.4 diff --git a/drivers/bus/fslmc/portal/dpaa2_hw_dpbp.c b/drivers/bus/fslmc/portal/dpaa2_hw_dpbp.c index 1ddd280..7e96115 100644 --- a/drivers/bus/fslmc/portal/dpaa2_hw_dpbp.c +++ b/drivers/bus/fslmc/portal/dpaa2_hw_dpbp.c @@ -129,6 +129,13 @@ void dpaa2_free_dpbp_dev(struct dpaa2_dpbp_dev *dpbp) } } +int dpaa2_dpbp_supported(void) +{ + if (TAILQ_EMPTY(&dpbp_dev_list)) + return -1; + return 0; +} + static struct rte_dpaa2_object rte_dpaa2_dpbp_obj = { .dev_type = DPAA2_BPOOL, .create = dpaa2_create_dpbp_device, diff --git a/drivers/bus/fslmc/portal/dpaa2_hw_pvt.h b/drivers/bus/fslmc/portal/dpaa2_hw_pvt.h index bb52a15..8f39cfb 100644 --- a/drivers/bus/fslmc/portal/dpaa2_hw_pvt.h +++ b/drivers/bus/fslmc/portal/dpaa2_hw_pvt.h @@ -366,6 +366,7 @@ void set_swp_active_dqs(uint16_t dpio_index, struct qbman_result *dqs) } struct dpaa2_dpbp_dev *dpaa2_alloc_dpbp_dev(void); void dpaa2_free_dpbp_dev(struct dpaa2_dpbp_dev *dpbp); +int dpaa2_dpbp_supported(void); struct dpaa2_dpci_dev *rte_dpaa2_alloc_dpci_dev(void); void rte_dpaa2_free_dpci_dev(struct dpaa2_dpci_dev *dpci); diff --git a/drivers/bus/fslmc/rte_bus_fslmc_version.map b/drivers/bus/fslmc/rte_bus_fslmc_version.map index 3cc7dad..7b25248 100644 --- a/drivers/bus/fslmc/rte_bus_fslmc_version.map +++ b/drivers/bus/fslmc/rte_bus_fslmc_version.map @@ -83,6 +83,7 @@ DPDK_17.08 { DPDK_17.11 { global: + dpaa2_dpbp_supported; rte_dpaa2_dev_type; } DPDK_17.08;