From patchwork Sat Sep 16 10:52:24 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hemant Agrawal X-Patchwork-Id: 112791 Delivered-To: patch@linaro.org Received: by 10.140.106.117 with SMTP id d108csp1615537qgf; Sat, 16 Sep 2017 03:55:07 -0700 (PDT) X-Google-Smtp-Source: AOwi7QBOPeBr454CIVzXcbVU9a2iF9h/GFD1KQ7c5AIUftVPm+Eb/jeNBJiKcJBR5FASMIQEaNuH X-Received: by 10.28.99.69 with SMTP id x66mr5096965wmb.30.1505559307209; Sat, 16 Sep 2017 03:55:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1505559307; cv=none; d=google.com; s=arc-20160816; b=qV/sKrqJ1L4tRFIKF8B06OBnmUQizV6N7BXeHSOtTQVwIFct/31XTghOl8MqNKD60v mFonTzSZh1vZQmhdCdGijvVA2ThZqQJ6tn2fARHtWsMd4xfDPf+gqhniKJo9DFRpCLg0 PKX13wlfq7LA0xrkMsZsAnMo9Jx4I3gqJpG0wInkfCE+fyrGiU0PTeGKbh8+0k32KocS y+VtZklg5oZBoBv83LiEXCAr9ZFnu2qTzxwopj5rH1xZkrVDcazFmLKO01Ht5vmwfV1i kuOdKBUuxS3RAC1lJVgCtzUJ7B8xI4i5ksSM6tMEjM9Pi/uAMR3Km5AUGOnVrQJemisG +RYg== 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=glJJ0ACGQ4I9PvO8IDuyxh0J+xGSYF/Z7x83A3lUeWY=; b=skbzB9PnVZvbEVBorTAOU79Dy/ov/MmM+Wcd8+rL89VXjsB0xAZGzOBfSAOfmPZ6mV vqrt2HXU9eRY/IC+M2r+HgoZLqOv8qGZdIZ1ySI69oKaT25kWGi4jrfuqNejJM9tcVrp S3PunRhlvco4gqtWZxd9NUiHgra9Znpfl+q9n+xaLjc9VQ7IL75yBSCdrZb6M0JR/wEU y+ZF3Yb8wuOf9hY2jIVI79wz20B0cVEm2ehX1fBsf83BFN9b11S2kDkIzdjU9Bos1Vcg AxQJdHt6u2XvkfFNMzX/vyjDRXeXaLxtuzlE0vnZEVJJgfDDEh74uu6CFEkJXXJuO5Em 1gYQ== 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 c12si2522351wmi.21.2017.09.16.03.55.06; Sat, 16 Sep 2017 03:55:07 -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 08F761B1BC; Sat, 16 Sep 2017 12:53:36 +0200 (CEST) Received: from NAM03-BY2-obe.outbound.protection.outlook.com (mail-by2nam03on0053.outbound.protection.outlook.com [104.47.42.53]) by dpdk.org (Postfix) with ESMTP id A6DD11B1AC for ; Sat, 16 Sep 2017 12:53:29 +0200 (CEST) Received: from BN6PR03CA0002.namprd03.prod.outlook.com (10.168.230.140) 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.56.11; Sat, 16 Sep 2017 10:53:27 +0000 Received: from BN1AFFO11FD030.protection.gbl (2a01:111:f400:7c10::199) by BN6PR03CA0002.outlook.office365.com (2603:10b6:404:23::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.56.8 via Frontend Transport; Sat, 16 Sep 2017 10:53:27 +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 BN1AFFO11FD030.mail.protection.outlook.com (10.58.52.168) 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:27 +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 v8GAr6uv028328; Sat, 16 Sep 2017 03:53:25 -0700 From: Hemant Agrawal To: CC: , Date: Sat, 16 Sep 2017 16:22:24 +0530 Message-ID: <1505559161-29222-11-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: 131500328075078938; (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)(39860400002)(376002)(39380400002)(2980300002)(1109001)(1110001)(339900001)(189002)(199003)(68736007)(8936002)(5660300001)(316002)(106466001)(4326008)(2906002)(85426001)(81166006)(81156014)(2351001)(50466002)(498600001)(110136004)(356003)(48376002)(16586007)(105606002)(33646002)(8676002)(97736004)(54906002)(104016004)(50986999)(76176999)(36756003)(50226002)(86362001)(189998001)(53936002)(2950100002)(6916009)(8656003)(47776003)(77096006)(305945005)(5003940100001); DIR:OUT; SFP:1101; SCL:1; SRVR:BN3PR03MB2356; H:tx30smr01.am.freescale.net; FPR:; SPF:Fail; PTR:InfoDomainNonexistent; MX:1; A:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; BN1AFFO11FD030; 1:KXZ1G+AcvOnQBjR2aFdCU/+b7n0RDoPwqCfTiPJq4B5LGArhMDZRw0ngV057qt3QyRGCyIRsZs+UHcVI571jIIqRb2FfHPDN3g2kc74GT0N4dy7IKQ/rONwI6hCKaWwu MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: d89ed478-17b7-4e01-2d1a-08d4fcf1293a 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:BN3PR03MB2356; X-Microsoft-Exchange-Diagnostics: 1; BN3PR03MB2356; 3:SqFg3CSzFEZ862YCdgqSmEaucZmEwyFEWSXxKEytsr3Ak1Ib6fXb37AsXfjOU+I9jk2GYA1jddqGiaGOEbhF4D4v/dFbt0Qv0Hs21Bjuaapgbq22cotN1NP4hCR8oY5xaZx6QVdzPTvl1vP6E8hDGeNXDL6c1b1rGElzrRxcFMrYO6VDGIU6JzTDNcJbgazMde+5f+rkNoPHnX4mFRW6PiHEyqx4inKhCf9joxoq850C/ls+n2pK/KeA9Lqh9vOOtH3yEOAkUvLdy7vnVaL+pkwYvjshyZdR3bZqPkyTj6yOr11ltIt7nZimKjynFMcZCnZT9/62ER2G77RYICAf44vKxkPPffyssg5TE4wXrZM=; 25:vocPrROiFmS/LPu9ScSJQDKzGxjgX277y+aJdOv4R7L9YGAWBmfwNRNVgR/w+iJQ6plPKgQb4vJDkbP9prTO177UdKNtaveNsxloZSOK06vlFXuRH4e9dfFd3daFRnu1zeei0PfRHpQifn/NdeS2ZoUfDVw0j+Ho/Toiu9mwzpgZpKjvVpePoWidvMU2tcCPq+2/K+9PYirOH5x3MRl+bBdORO+gppr9Uqu3rUAaaT+NZdZCjTjXFw3cPIpHE+ZU3pMjImKx1ONqr/0cyGZ7VDNGm62QGQpM3NDCkhTgzyc3lKJboxKyCOyuM3Ct/PlLRVsf2XOfv+hTRUQFpApMkg== X-MS-TrafficTypeDiagnostic: BN3PR03MB2356: X-Microsoft-Exchange-Diagnostics: 1; BN3PR03MB2356; 31:Z2xpze+pcD7glpKoTCECe385qtItG9cF+nVoQitvRWwrH9mENYejXMiMCpYvPjrfuE+AsFO+G4D/7TkXValaDUbKnws4lBNuFVotENo8VrXBhf1mOTKg0KQ6K3+1FO2yLUOxC4mng8323FVJH8IiHQTLu8MOzs5Ni4zWzl+7jXaiwnq4d2j8jxujjDqfp/o2ALI+Z4mwofgj0pol7nmhIgrMfSwUlv1gAo+Fw5HxqH8=; 4:prM06byIX9+Yiiw7Umjbe3BlhABwAcNiQfyqzroR0Q93OC8fL2x3OX406OLU1U9rScPJAGcvkXUSJvH6MW4ObZIogJ58uNp+A/7tmNaXmDP4Z6utN1i7CDqWniY0C9g2tbTB4mwwL+SlhiJIbpmNeuLkD6CwLyCPcnhHMOKz2HXamhpj84as+hvIVg22CwlyA5sYqfwkBZzIQjk1MXiMweamDF34loEfEBlr56SmKYHfHD/zreQC2c0PTLqO/ljJVKXsGRt2kfV7mqtqxXhek9ru8S4rMlPDic5MosZvMOcoMmVrNq8ROrTsIahPHXOLnCv8LUzG5ymelNnU4mXM6w== 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)(8121501046)(5005006)(3002001)(93006095)(93001095)(100000703101)(100105400095)(10201501046)(6055026)(6096035)(20161123559100)(201703131430075)(201703131433075)(201703131448075)(201703161259150)(201703151042153)(20161123563025)(20161123556025)(20161123565025)(20161123561025)(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: 0432A04947 X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; BN3PR03MB2356; 23:6AGZdcxhNjbhP2idpE5hd1T+YVxT2EGY4B7vi8vz6?= t9byfN7jVpz5UwoGKegTuWTrDEKHUGY4y0j5rHMPOOpZeB967R/mWX2FJbUk+DJOz6nrAHpSKL4lkEYIfCJtqt3rMhUeY9bgsYYGMPaRF9Y9QtoMlgCUqg8BfDrQIaRi1ilLOkI/W9gCSdTKpaOpchiQBAEsTCCbMqbonAsdvBTKUm39YxJ6fmLWQfOTHwr1WiXdmj8Wk/50LSlWmJCXsQ6GfQIln6jJKtatd0iqDeArCJGPtoY215cmGkcL/3Tr5YGirwt6dmVQ/xY22JBHi0RgIVC+iOxJ4Rhs5+x+wOYKGxsqWfBsJCjQt8kRGPxFyV+l3ZM4alxsMjrNSFJ2yl6cFiYZzQkzaORUCC1feanXADuyejh1ubD/TpCpzJU8aLvF+e5lNtPytMOQMMGUsyngm2d8RBkfW43Lo44j+i9YyTPcrmmiCDx5LYlARGukpEM9pXLiuS0UM0zUxxrAOrMXUSSnBnWOLFbUXSqTyPoKPnNADvaw3EKP3evNGMz75LjbvN+6I76QB5Kom+7bsLzricKsKWwNsWGT1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QNJ66NMpAXtYrkX4rI1L8lccaXr1GEz37Xj+ZE9NUlDpWh2ZJdAr3PDoDSnn5ITqVnUF5jzRk=; 24:Ewq4fVz7UXEPgme0Lm8quNfFlFBWzwVG6K4KMtgSbT7PtFrVrUyf5bV4VO5R9ivt4/x3V2sQDZvDrf8DwCPtX2NZHghFv4IG4TP5nv1iuI8=; 7:+4GboG+VspcBz5l5DswJl5EXMmSJ85gyyFEGl2OpWZQ1dCWUwnJd8pztqGmADbva/vChNqqtn/N9u3+i34Rl41305ExuqQWw6W8gZwBv7NO/tpIgYm6RIRkqkltYQqWqVVLjUVWAiG37Kju7pag3qlqMXVo6SC681fxLz4etp+UU5oRhTfjq2dxsBiy8u1Oq8KFpoh+sh68Wae19rgBjvfLKPLAUcnMfPlvzmQIF35s= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-MS-Exchange-CrossTenant-OriginalArrivalTime: 16 Sep 2017 10:53:27.3362 (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: [dpdk-dev] [PATCH v3 10/27] bus/fslmc: add support for LX2160 platform 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" From: Ashish Jain Signed-off-by: Ashish Jain --- drivers/bus/fslmc/portal/dpaa2_hw_dpio.c | 22 ++++++++++++++-------- drivers/bus/fslmc/portal/dpaa2_hw_pvt.h | 1 + 2 files changed, 15 insertions(+), 8 deletions(-) -- 2.7.4 diff --git a/drivers/bus/fslmc/portal/dpaa2_hw_dpio.c b/drivers/bus/fslmc/portal/dpaa2_hw_dpio.c index 7315555..8db1f6c 100644 --- a/drivers/bus/fslmc/portal/dpaa2_hw_dpio.c +++ b/drivers/bus/fslmc/portal/dpaa2_hw_dpio.c @@ -90,20 +90,22 @@ static int dpaa2_cluster_sz = 2; * Cluster 1 (ID = x02) : CPU0, CPU1, CPU2, CPU3; * Cluster 2 (ID = x03) : CPU4, CPU5, CPU6, CPU7; */ - -/* Set the STASH Destination depending on Current CPU ID. - * e.g. Valid values of SDEST are 4,5,6,7. Where, - * CPU 0-1 will have SDEST 4 - * CPU 2-3 will have SDEST 5.....and so on. +/* For LX2160 platform There are four clusters with following mapping: + * Cluster 1 (ID = x00) : CPU0, CPU1; + * Cluster 2 (ID = x01) : CPU2, CPU3; + * Cluster 3 (ID = x02) : CPU4, CPU5; + * Cluster 4 (ID = x03) : CPU6, CPU7; + * Cluster 1 (ID = x04) : CPU8, CPU9; + * Cluster 2 (ID = x05) : CPU10, CP11; + * Cluster 3 (ID = x06) : CPU12, CPU13; + * Cluster 4 (ID = x07) : CPU14, CPU15; */ + static int dpaa2_core_cluster_sdest(int cpu_id) { int x = cpu_id / dpaa2_cluster_sz; - if (x > 3) - x = 3; - return dpaa2_core_cluster_base + x; } @@ -278,6 +280,10 @@ dpaa2_configure_stashing(struct dpaa2_dpio_dev *dpio_dev, int cpu_id) dpaa2_core_cluster_base = 0x02; dpaa2_cluster_sz = 4; PMD_INIT_LOG(DEBUG, "\tLS108x (A53) Platform Detected"); + } else if ((mc_plat_info.svr & 0xffff0000) == SVR_LX2160A) { + dpaa2_core_cluster_base = 0x00; + dpaa2_cluster_sz = 2; + PMD_INIT_LOG(DEBUG, "\tLX2160 Platform Detected"); } first_time = 1; } diff --git a/drivers/bus/fslmc/portal/dpaa2_hw_pvt.h b/drivers/bus/fslmc/portal/dpaa2_hw_pvt.h index 5d7a828..bb52a15 100644 --- a/drivers/bus/fslmc/portal/dpaa2_hw_pvt.h +++ b/drivers/bus/fslmc/portal/dpaa2_hw_pvt.h @@ -51,6 +51,7 @@ #define SVR_LS1080A 0x87030000 #define SVR_LS2080A 0x87010000 #define SVR_LS2088A 0x87090000 +#define SVR_LX2160A 0x87360000 #ifndef ETH_VLAN_HLEN #define ETH_VLAN_HLEN 4 /** < Vlan Header Length */