Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752747AbbHEN3P (ORCPT ); Wed, 5 Aug 2015 09:29:15 -0400 Received: from mail-by2on0103.outbound.protection.outlook.com ([207.46.100.103]:45528 "EHLO na01-by2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751294AbbHEN3M (ORCPT ); Wed, 5 Aug 2015 09:29:12 -0400 Authentication-Results: spf=fail (sender IP is 192.88.158.2) smtp.mailfrom=freescale.com; freescale.mail.onmicrosoft.com; dkim=none (message not signed) header.d=none; From: To: CC: , , , , , , , , Igal Liberman Subject: [v4, 0/9] Freescale DPAA FMan Date: Wed, 5 Aug 2015 12:25:16 +0300 Message-ID: <1438766725-8053-1-git-send-email-igal.liberman@freescale.com> X-Mailer: git-send-email 1.7.9.5 Reply-To: X-EOPAttributedMessage: 0 X-Microsoft-Exchange-Diagnostics: 1;BN1AFFO11FD031;1:MU8mrcRWHwiofZ0lQRO96Dd4jtHRvceiD15Fk/MBXbBD9p6we3DcuR1/BrFeoBEuN6ihum6mE+uD3sOo09A7H6ZFwbD6FfXRKMF+NXlXAYlCfM0xVRWRXrImdR4hBjnwkMPRC2NkRcTA2ddN/0/Dwi4RdjrZK3p/hFAoV1ltAU7OSRBYA1oLusHolkQyUGypCxuwjm8M31MN45/LFHxYFo5uha7duQ2o8lfka6cXkLtXjQp6H6O4l5deTLyLzzvcLsSF++vb4uVQ+TYcV8PhEAoImJVlWlVAoS5oi6nVzuz8Cq56yGYtAfn2wKDZiW3AwsDntNImr32fVNnv9brnbA== X-Forefront-Antispam-Report: CIP:192.88.158.2;CTRY:US;IPV:NLI;EFV:NLI;SFV:NSPM;SFS:(10019020)(6009001)(2980300002)(339900001)(199003)(189002)(68736005)(77096005)(229853001)(5003940100001)(110136002)(33646002)(36756003)(104016003)(77156002)(107886002)(5001960100002)(105606002)(62966003)(5001860100001)(2351001)(106466001)(81156007)(97736004)(189998001)(4001540100001)(46102003)(5001830100001)(50226001)(69596002)(50986999)(86362001)(53806999)(50466002)(48376002)(64706001)(19580395003)(86152002)(43066003)(47776003)(6806004)(87936001)(85426001)(19580405001)(4001430100001);DIR:OUT;SFP:1102;SCL:1;SRVR:DM2PR03MB510;H:az84smr01.freescale.net;FPR:;SPF:Fail;PTR:InfoDomainNonexistent;A:1;MX:1;LANG:en; MIME-Version: 1.0 Content-Type: text/plain X-Microsoft-Exchange-Diagnostics: 1;DM2PR03MB510;2:BIjjodVOzjtB4Lg6w1m1F0/TchEA+A3WYsVhkM1Xxli/gEsILWpomtJaR6JJOKD6W0T+qeEpLxsN4RK7V45h3LAINiucJn1TG2rL7NJlGUg1XAaTmrCwgykEuyBY/IRerYy5W3roVoOV7Mz9bOYXhELjoHS25VnMK+YbNiSspgk=;3:kO3qysYXpJhyEoi36ivpoZ6LI5b4qrIaH1KYRFlIwFei9dudtZCf+S+0fqUS5Yzv3YXg8G1DHS3jsAmMEwhvKt3G1wLjgnyWsDzKsXGoHA5GAYfHULM4XeiGEp1Nqwb6FmgEI0EgczHVrcg2WywB5cJ24gW96JVLvoDgSP7LqyWbDb04nqpbTWNlbwbtTRWWhzNz4bbLpld0WmDb7ksgGFqLuvaboLdoIb9opnKqETM=;25:74IeHI1Pvbe5jHD/XbWA6T7bwgsmlk8O94ALlIGvp4zCYrPQONHMs/LQSeRiwX2PYVufdXgRCfr/FVtp+fSsxu9ML/fGkW5yeEr/uAwa/CxSgdgDspetza8wL1L1wAvSDEwqGNtJALpzpZanJk2sV0c6fXQogIxIWp7/AwpCdv44jebdE+TGTN+5vMYa7h8VLkK3gLp+/OBgvvoG2O0XVmpqQ3totD0SDMZruAXHcoSfR/03NkYO+ZeVCFGVIrPRqOd1LMMiOaJBtWcGFoIA/g== X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:;SRVR:DM2PR03MB510; X-Microsoft-Exchange-Diagnostics: 1;DM2PR03MB510;20:Ii+weU2ZOvpoRpIU3XoVtEFnnSbIe+k7A4YtuubCf8wEZkcedu4jSsWNAVmVXE3tgD04cks46040vXfvRFGo4f4FzrXLqvSRrb73knCwy/8B0BPB/iAFwEut8ppH8aoVC8tNsdypHmr2gqbjtpE0ZgLxGpB8VIkgTYNw+3OHjgJS/1VpHeQS7TNJnPhziX8W/Uu/EStj8JgepqkM1CXaGDYDgh6kNekVcLSk+ZVW6IHyWyXWx5VHCZwa+pzJn1MsHXyJPq1xpnAGKrFqipVMWvwJGsNyzusnBzR01K3TnLoyngJEiziYG3/4rxcK8AIrwQ1klg95x84QEdKUy0ti4JS+XHG3O9VEFe9b8gLSbpM=;4:4yoYH+JcOjzX4D0ykaxOY4ARF5LRl2kv+C72u3MhWGhla4flvjW9AivCEEFOTbwiWQZsv1W7JPbNOROH1Zt6yuFbN4ti5bg7V+6lTbLOmNkRonZ1jD8o+XdmwPUNfslDtiHRZlc308Q8Slz9aXNnBn3hDKRhAE0AIvl5wd9mLsJ6TW5uwRpX/TGI5PQL9qyT+aPnZ8QjkGAA6rEmhe5yokYhSdqNnPDhsKPnQ3oYkhbVEIsSN1E9tuJtLFxH9NgTuWePOIc/pt6n+a1kvopMCxhkcXSlP32XigGQyphf45k= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(601004)(5005006)(3002001);SRVR:DM2PR03MB510;BCL:0;PCL:0;RULEID:;SRVR:DM2PR03MB510; X-Forefront-PRVS: 06592CCE58 X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1;DM2PR03MB510;23:lO9MAsd5vNhkJ44Sd9mXUsEOagpyeLk5GVsqU+I4FD?= =?us-ascii?Q?vpy2wBBtkj9KApnF47ZZk2aiyb6YfiyQ5TZseu40wrmBjFKwz294FiPjbYHG?= =?us-ascii?Q?K/0QlICkYZL9jbGQuZOEnb5XUik53QQbPx8LFABca+NflUvHRRgsgny9i3d6?= =?us-ascii?Q?bjusWthOt/GsL8O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reAVnbgPBrAAHW?= =?us-ascii?Q?sNnp9C46Mp+j8Rm2C1d2OzgHgXIfGyXYwyL08qK5kfta7bh/lM6PsONuw6IM?= =?us-ascii?Q?wejJ6covaPSrPBH3zBmdYjbPq1RPZjMlbdTBy12kYnfM88ZqDMsQ=3D=3D?= X-Microsoft-Exchange-Diagnostics: 1;DM2PR03MB510;5:J3cT/I7PdOdVubL8c4cmGAtPM0L/RYQGLlgq6ljogmj5FCzCoc+j2fhcspycRqjAMW1ozDlAwr97x3iLTQQq55wOrMD/pZYaYWtoBecUbceE0KmMajhVORd8C80ME//aRP1oSdlH5+9PQzfcfQZtBw==;24:J/bYJ+TruwOv2lXsmrcec3N4xuPzZpDRSFp3tcporKSQtC+qDZLePgf2SqnlcVnInAkhKnXmHY7c0qyMVPtvBk3GL1aiC5QaMf38EaTG4nk=;20:1H4bU7uMGYAXl2gltlkXJ0YcaRlKa/dg4ujrVMkyILTr/McS72m6il52R5kXsPQrLZ4BozZgQ7j+dCGb7oyKgw== X-OriginatorOrg: freescale.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 05 Aug 2015 13:29:08.8878 (UTC) X-MS-Exchange-CrossTenant-Id: 710a03f5-10f6-4d38-9ff4-a80b81da590d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=710a03f5-10f6-4d38-9ff4-a80b81da590d;Ip=[192.88.158.2];Helo=[az84smr01.freescale.net] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM2PR03MB510 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 10370 Lines: 202 From: Igal Liberman The Freescale Data Path Acceleration Architecture (DPAA) is a set of hardware components on specific QorIQ multicore processors. This architecture provides the infrastructure to support simplified sharing of networking interfaces and accelerators by multiple CPU cores and the accelerators. One of the DPAA accelerators is the Frame Manager (FMan) which contains a series of hardware blocks: ports, Ethernet MACs, a multi user RAM (MURAM) and Storage Profile (SP). This patch set introduce the FMan drivers. Each driver configures and initializes the corresponding FMan hardware module (described above). The MAC driver offers support for three different types of MACs (eTSEC, TGEC, MEMAC). The driver structure and a hint on file naming: ---------------------------------- | FMan driver/MAC driver | fm_drv*, mac* files ---------------------------------- | FMan | Port | MAC | MURAM | SP | fm_* files ---------------------------------- | FLib | fman_*.c, fsl_fman_.*h files ---------------------------------- The first 3 patches present the FMan Foundation Libraries (FLIBs). The FLIBs provide basic internal API for the FMan hardware configuration and control. Header files are located in fman/flib directory. Source files are located in each module directory. The upper layer of the FMan driver makes use of the basic API which is provided by the Flibs. The remaining patches present the required FMan hardware module drivers. v3 --> v4: - Remove device_initcall call in driver registration (redundant) - Remove hot/cold labels - Minor update in FMan Clock read from device-tree - Update fixed-link support - Addressed feedback from Stephen Hemminger - Remove bogus blank line v2 --> v3: - Addressed feedback from Scott: - Remove typedefs - Remove unnecessary memory barriers - Remove unnecessary casting - Remove KConfig options - Remove early_params - Remove Hungarian notation - Remove __packed__ attribute and padding from structures - Remove unlikely attribute (where it's not needed) - Use proper error codes and remove unnecessary prints - Use proper values for sleep routines - Replace complex Macros with functions - Improve device tree processing code - Use symbolic defines - Add time-out in busy-wait loops - Removed exit code (loadable module support will be added later) - Fixed "fixed-link" issue raised by Joakim Tjernlund v1 --> v2: - Addressed feedback from Paul Bolle: - General feedback of FMan Driver layer - Remove Errata defines - Aligned comments to Kernel Doc - Remove Loadable Module support (not yet supported) - Removed not needed KConfig dependencies - Addressed feedback from Scott Wood - Use Kernel ioread/iowrite services - Squash FLIB source and header patches together This submission is based on the prior Freescale DPAA FMan V3,RFC submission. Several issues addresses in this submission: - Reduced MAC layering and complexity - Reduced code base - T1024/T2080 10G best effort support Igal Liberman (9): fsl/fman: Add the FMan FLIB fsl/fman: Add the FMan port FLIB fsl/fman: Add the FMan MAC FLIB fsl/fman: Add FMan MURAM support fsl/fman: Add Frame Manager support fsl/fman: Add FMan MAC support fsl/fman: Add FMan SP support fsl/fman: Add FMan Port Support fsl/fman: Add FMan MAC driver drivers/net/ethernet/freescale/Kconfig | 1 + drivers/net/ethernet/freescale/Makefile | 2 + drivers/net/ethernet/freescale/fman/Kconfig | 8 + drivers/net/ethernet/freescale/fman/Makefile | 12 + .../net/ethernet/freescale/fman/flib/fsl_enet.h | 135 ++ .../net/ethernet/freescale/fman/flib/fsl_fman.h | 590 +++++++++ .../ethernet/freescale/fman/flib/fsl_fman_dtsec.h | 809 ++++++++++++ .../freescale/fman/flib/fsl_fman_dtsec_mii_acc.h | 89 ++ .../ethernet/freescale/fman/flib/fsl_fman_memac.h | 429 ++++++ .../freescale/fman/flib/fsl_fman_memac_mii_acc.h | 72 ++ .../ethernet/freescale/fman/flib/fsl_fman_port.h | 409 ++++++ .../net/ethernet/freescale/fman/flib/fsl_fman_sp.h | 53 + .../ethernet/freescale/fman/flib/fsl_fman_tgec.h | 393 ++++++ drivers/net/ethernet/freescale/fman/fm.c | 1366 ++++++++++++++++++++ drivers/net/ethernet/freescale/fman/fm.h | 279 ++++ drivers/net/ethernet/freescale/fman/fm_common.h | 178 +++ drivers/net/ethernet/freescale/fman/fm_drv.c | 621 +++++++++ drivers/net/ethernet/freescale/fman/fm_drv.h | 111 ++ drivers/net/ethernet/freescale/fman/fm_muram.c | 115 ++ drivers/net/ethernet/freescale/fman/fm_port_drv.c | 372 ++++++ drivers/net/ethernet/freescale/fman/fm_sp_common.h | 105 ++ drivers/net/ethernet/freescale/fman/fman.c | 911 +++++++++++++ .../ethernet/freescale/fman/inc/crc_mac_addr_ext.h | 314 +++++ drivers/net/ethernet/freescale/fman/inc/enet_ext.h | 199 +++ drivers/net/ethernet/freescale/fman/inc/fm_ext.h | 446 +++++++ .../net/ethernet/freescale/fman/inc/fm_muram_ext.h | 102 ++ .../net/ethernet/freescale/fman/inc/fm_port_ext.h | 340 +++++ .../net/ethernet/freescale/fman/inc/fsl_fman_drv.h | 203 +++ drivers/net/ethernet/freescale/fman/inc/mac.h | 135 ++ drivers/net/ethernet/freescale/fman/mac/Makefile | 8 + drivers/net/ethernet/freescale/fman/mac/fm_dtsec.c | 1012 +++++++++++++++ drivers/net/ethernet/freescale/fman/mac/fm_dtsec.h | 207 +++ drivers/net/ethernet/freescale/fman/mac/fm_mac.h | 259 ++++ drivers/net/ethernet/freescale/fman/mac/fm_memac.c | 700 ++++++++++ drivers/net/ethernet/freescale/fman/mac/fm_memac.h | 122 ++ drivers/net/ethernet/freescale/fman/mac/fm_tgec.c | 552 ++++++++ drivers/net/ethernet/freescale/fman/mac/fm_tgec.h | 124 ++ .../net/ethernet/freescale/fman/mac/fman_dtsec.c | 503 +++++++ .../freescale/fman/mac/fman_dtsec_mii_acc.c | 153 +++ .../net/ethernet/freescale/fman/mac/fman_memac.c | 374 ++++++ .../freescale/fman/mac/fman_memac_mii_acc.c | 151 +++ .../net/ethernet/freescale/fman/mac/fman_tgec.c | 207 +++ drivers/net/ethernet/freescale/fman/mac/mac-api.c | 688 ++++++++++ drivers/net/ethernet/freescale/fman/mac/mac.c | 445 +++++++ drivers/net/ethernet/freescale/fman/port/Makefile | 3 + drivers/net/ethernet/freescale/fman/port/fm_port.c | 1081 ++++++++++++++++ drivers/net/ethernet/freescale/fman/port/fm_port.h | 502 +++++++ .../net/ethernet/freescale/fman/port/fman_port.c | 510 ++++++++ drivers/net/ethernet/freescale/fman/sp/Makefile | 3 + drivers/net/ethernet/freescale/fman/sp/fm_sp.c | 371 ++++++ 50 files changed, 16774 insertions(+) create mode 100644 drivers/net/ethernet/freescale/fman/Kconfig create mode 100644 drivers/net/ethernet/freescale/fman/Makefile create mode 100644 drivers/net/ethernet/freescale/fman/flib/fsl_enet.h create mode 100644 drivers/net/ethernet/freescale/fman/flib/fsl_fman.h create mode 100644 drivers/net/ethernet/freescale/fman/flib/fsl_fman_dtsec.h create mode 100644 drivers/net/ethernet/freescale/fman/flib/fsl_fman_dtsec_mii_acc.h create mode 100644 drivers/net/ethernet/freescale/fman/flib/fsl_fman_memac.h create mode 100644 drivers/net/ethernet/freescale/fman/flib/fsl_fman_memac_mii_acc.h create mode 100644 drivers/net/ethernet/freescale/fman/flib/fsl_fman_port.h create mode 100644 drivers/net/ethernet/freescale/fman/flib/fsl_fman_sp.h create mode 100644 drivers/net/ethernet/freescale/fman/flib/fsl_fman_tgec.h create mode 100644 drivers/net/ethernet/freescale/fman/fm.c create mode 100644 drivers/net/ethernet/freescale/fman/fm.h create mode 100644 drivers/net/ethernet/freescale/fman/fm_common.h create mode 100644 drivers/net/ethernet/freescale/fman/fm_drv.c create mode 100644 drivers/net/ethernet/freescale/fman/fm_drv.h create mode 100644 drivers/net/ethernet/freescale/fman/fm_muram.c create mode 100644 drivers/net/ethernet/freescale/fman/fm_port_drv.c create mode 100644 drivers/net/ethernet/freescale/fman/fm_sp_common.h create mode 100644 drivers/net/ethernet/freescale/fman/fman.c create mode 100644 drivers/net/ethernet/freescale/fman/inc/crc_mac_addr_ext.h create mode 100644 drivers/net/ethernet/freescale/fman/inc/enet_ext.h create mode 100644 drivers/net/ethernet/freescale/fman/inc/fm_ext.h create mode 100644 drivers/net/ethernet/freescale/fman/inc/fm_muram_ext.h create mode 100644 drivers/net/ethernet/freescale/fman/inc/fm_port_ext.h create mode 100644 drivers/net/ethernet/freescale/fman/inc/fsl_fman_drv.h create mode 100644 drivers/net/ethernet/freescale/fman/inc/mac.h create mode 100644 drivers/net/ethernet/freescale/fman/mac/Makefile create mode 100644 drivers/net/ethernet/freescale/fman/mac/fm_dtsec.c create mode 100644 drivers/net/ethernet/freescale/fman/mac/fm_dtsec.h create mode 100644 drivers/net/ethernet/freescale/fman/mac/fm_mac.h create mode 100644 drivers/net/ethernet/freescale/fman/mac/fm_memac.c create mode 100644 drivers/net/ethernet/freescale/fman/mac/fm_memac.h create mode 100644 drivers/net/ethernet/freescale/fman/mac/fm_tgec.c create mode 100644 drivers/net/ethernet/freescale/fman/mac/fm_tgec.h create mode 100644 drivers/net/ethernet/freescale/fman/mac/fman_dtsec.c create mode 100644 drivers/net/ethernet/freescale/fman/mac/fman_dtsec_mii_acc.c create mode 100644 drivers/net/ethernet/freescale/fman/mac/fman_memac.c create mode 100644 drivers/net/ethernet/freescale/fman/mac/fman_memac_mii_acc.c create mode 100644 drivers/net/ethernet/freescale/fman/mac/fman_tgec.c create mode 100644 drivers/net/ethernet/freescale/fman/mac/mac-api.c create mode 100644 drivers/net/ethernet/freescale/fman/mac/mac.c create mode 100644 drivers/net/ethernet/freescale/fman/port/Makefile create mode 100644 drivers/net/ethernet/freescale/fman/port/fm_port.c create mode 100644 drivers/net/ethernet/freescale/fman/port/fm_port.h create mode 100644 drivers/net/ethernet/freescale/fman/port/fman_port.c create mode 100644 drivers/net/ethernet/freescale/fman/sp/Makefile create mode 100644 drivers/net/ethernet/freescale/fman/sp/fm_sp.c -- 1.7.9.5 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/