From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from nbfkord-smmo02.seg.att.com (nbfkord-smmo02.seg.att.com [209.65.160.78]) by dpdk.org (Postfix) with ESMTP id 9F11C2A5D for ; Mon, 21 Nov 2016 16:01:24 +0100 (CET) Received: from unknown [12.187.104.26] (EHLO webmail.solarflare.com) by nbfkord-smmo02.seg.att.com(mxl_mta-7.2.4-7) over TLS secured channel with ESMTP id 34c03385.0.1541294.00-2341.3424165.nbfkord-smmo02.seg.att.com (envelope-from ); Mon, 21 Nov 2016 15:01:24 +0000 (UTC) X-MXL-Hash: 58330c4464b6e16c-4fc36670fcb6856fdc285ef8fd3782c5733366bf Received: from ocex03.SolarFlarecom.com (10.20.40.36) by ocex03.SolarFlarecom.com (10.20.40.36) with Microsoft SMTP Server (TLS) id 15.0.1044.25; Mon, 21 Nov 2016 07:01:21 -0800 Received: from opal.uk.solarflarecom.com (10.17.10.1) by ocex03.SolarFlarecom.com (10.20.40.36) with Microsoft SMTP Server (TLS) id 15.0.1044.25 via Frontend Transport; Mon, 21 Nov 2016 07:01:20 -0800 Received: from uklogin.uk.solarflarecom.com (uklogin.uk.solarflarecom.com [10.17.10.10]) by opal.uk.solarflarecom.com (8.13.8/8.13.8) with ESMTP id uALF1Jwu007098 for ; Mon, 21 Nov 2016 15:01:19 GMT Received: from uklogin.uk.solarflarecom.com (localhost.localdomain [127.0.0.1]) by uklogin.uk.solarflarecom.com (8.13.8/8.13.8) with ESMTP id uALF1J2p006765 for ; Mon, 21 Nov 2016 15:01:19 GMT From: Andrew Rybchenko To: Date: Mon, 21 Nov 2016 15:00:14 +0000 Message-ID: <1479740470-6723-1-git-send-email-arybchenko@solarflare.com> X-Mailer: git-send-email 1.8.2.3 MIME-Version: 1.0 Content-Type: text/plain X-AnalysisOut: [v=2.1 cv=UI/baXry c=1 sm=1 tr=0 a=8BlWFWvVlq5taO8ncb8nKg==] X-AnalysisOut: [:17 a=L24OOQBejmoA:10 a=6I5d2MoRAAAA:8 a=NEAV23lmAAAA:8 a=] X-AnalysisOut: [TkLbPbiAmUzpt8QcQGUA:9 a=gjON0x1lc9o1BFgo:21 a=IjZwj45LgO3] X-AnalysisOut: [ly-622nXo:22 a=Bn2pgwyD2vrAyMmN8A2t:22] X-Spam: [F=0.2000000000; CM=0.500; S=0.200(2015072901)] X-MAIL-FROM: X-SOURCE-IP: [12.187.104.26] Subject: [dpdk-dev] [PATCH 00/56] Solarflare libefx-based PMD X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Nov 2016 15:01:25 -0000 The patch series adds Solarflare libefx-based network PMD. This version of the driver supports Solarflare SFN7xxx and SFN8xxx families of 10/40 Gbps adapters. libefx is a platform-independent library to implement drivers for Solarflare network adapters. It provides unified adapter family independent interface (if possible). FreeBSD [1] and illumos [2] drivers are built on top of the library. The patch series could be logically structured into 5 sub-series: 1. (1) add the driver skeleton including documentation 2. (2-30) import libefx and include it in build with the latest patch 3. (31-43) implement minimal device level operations in steps 4. (44-51) implement Rx subsystem 5. (52-56) implement Tx subsystem Functional driver with multi-queue support capable to send and receive traffic appears with the last patch in the series. The following design decisions are made during development: 1. Since libefx uses positive errno return codes, positive errno return codes are used inside the driver and coversion to negative is done on return from eth_dev_ops callbacks. We think that it is the less error-prone way. 2. Another Solarflare PMD with in-kernel part (for control operations) is considered and could be added in the future. Code for data path should be shared by these two drivers. libefx-based PMD is put into 'efx' subdirectory to have a space for another PMD and shared code. 3. Own event queue (a way to deliver events from HW to host CPU) is used for house-keeping (e.g. link status notifications), each Tx and each Rx queue. No locks on datapath are requires in this case. 4. Alarm is used to periodically poll house-keeping event queue. The event queue is used to deliver link status change notifications, Rx/Tx queue flush events, SRAM events. It is not used on datapath. The event queue polling is protected using spin-lock since concurrent access from different contexts is possible (e.g. device stop when polling alarm is running). [1] https://svnweb.freebsd.org/base/head/sys/dev/sfxge/common/ [2] https://github.com/illumos/illumos-gate/tree/master/usr/src/uts/common/io/sfxge/common/ --- Andrew Rybchenko (49): net/sfc: libefx-based PMD stub sufficient to build and init net/sfc: import libefx base net/sfc: import libefx register definitions net/sfc: import libefx filters support net/sfc: import libefx MCDI definition net/sfc: import libefx MCDI implementation net/sfc: import libefx MCDI logging support net/sfc: import libefx MCDI proxy authorization support net/sfc: import libefx 5xxx/6xxx family support net/sfc: import libefx SFN7xxx family support net/sfc: import libefx SFN8xxx family support net/sfc: import libefx diagnostics support net/sfc: import libefx built-in selftest support net/sfc: import libefx software per-queue statistics support net/sfc: import libefx PHY flags control support net/sfc: import libefx PHY statistics support net/sfc: import libefx PHY LEDs control support net/sfc: import libefx MAC statistics support net/sfc: import libefx event prefetch support net/sfc: import libefx Rx scatter support net/sfc: import libefx RSS support net/sfc: import libefx loopback control support net/sfc: import libefx monitors statistics support net/sfc: import libefx support to access monitors via MCDI net/sfc: import libefx support for Rx packed stream mode net/sfc: import libefx NVRAM support net/sfc: import libefx VPD support net/sfc: import libefx bootrom configuration support net/sfc: import libefx licensing support net/sfc: implement dummy callback to get device information net/sfc: implement driver operation to init device on attach net/sfc: add device configure and close stubs net/sfc: add device configuration checks net/sfc: implement device start and stop operations net/sfc: make available resources estimation and allocation net/sfc: interrupts support sufficient for event queue init net/sfc: implement event queue support net/sfc: implement EVQ dummy exception handling net/sfc: maintain management event queue net/sfc: periodic management EVQ polling using alarm net/sfc: minimum port control sufficient to receive traffic net/sfc: implement Rx subsystem stubs net/sfc: check configured rxmode net/sfc: implement Rx queue setup release operations net/sfc: calculate Rx buffer size which may be used net/sfc: validate Rx queue buffers setup net/sfc: implement Rx queue start and stop operations net/sfc: implement device callback to Rx burst of packets net/sfc: discard scattered packet on Rx correctly Artem Andreev (2): net/sfc: include libefx in build net/sfc: implement device operation to retrieve link info Ivan Malov (5): net/sfc: provide basic stubs for Tx subsystem net/sfc: add function to check configured Tx mode net/sfc: add callbacks to set up and release Tx queues net/sfc: implement transmit path start / stop net/sfc: add callback to send bursts of packets MAINTAINERS | 6 + config/common_base | 6 + config/defconfig_arm-armv7a-linuxapp-gcc | 1 + config/defconfig_arm64-armv8a-linuxapp-gcc | 1 + config/defconfig_i686-native-linuxapp-gcc | 5 + config/defconfig_i686-native-linuxapp-icc | 5 + config/defconfig_ppc_64-power8-linuxapp-gcc | 1 + config/defconfig_tile-tilegx-linuxapp-gcc | 1 + config/defconfig_x86_64-native-linuxapp-icc | 5 + config/defconfig_x86_x32-native-linuxapp-gcc | 5 + doc/guides/nics/features/sfc_efx.ini | 13 + doc/guides/nics/index.rst | 1 + doc/guides/nics/sfc_efx.rst | 157 + drivers/net/Makefile | 1 + drivers/net/sfc/Makefile | 33 + drivers/net/sfc/efx/Makefile | 142 + drivers/net/sfc/efx/base/README | 36 + drivers/net/sfc/efx/base/ef10_ev.c | 1401 ++ drivers/net/sfc/efx/base/ef10_filter.c | 1479 ++ drivers/net/sfc/efx/base/ef10_impl.h | 1182 ++ drivers/net/sfc/efx/base/ef10_intr.c | 197 + drivers/net/sfc/efx/base/ef10_mac.c | 897 ++ drivers/net/sfc/efx/base/ef10_mcdi.c | 342 + drivers/net/sfc/efx/base/ef10_nic.c | 1833 +++ drivers/net/sfc/efx/base/ef10_nvram.c | 2385 ++++ drivers/net/sfc/efx/base/ef10_phy.c | 631 + drivers/net/sfc/efx/base/ef10_rx.c | 965 ++ drivers/net/sfc/efx/base/ef10_tlv_layout.h | 941 ++ drivers/net/sfc/efx/base/ef10_tx.c | 709 + drivers/net/sfc/efx/base/ef10_vpd.c | 463 + drivers/net/sfc/efx/base/efx.h | 2503 ++++ drivers/net/sfc/efx/base/efx_bootcfg.c | 563 + drivers/net/sfc/efx/base/efx_check.h | 346 + drivers/net/sfc/efx/base/efx_crc32.c | 122 + drivers/net/sfc/efx/base/efx_ev.c | 1470 ++ drivers/net/sfc/efx/base/efx_filter.c | 1402 ++ drivers/net/sfc/efx/base/efx_hash.c | 328 + drivers/net/sfc/efx/base/efx_impl.h | 1206 ++ drivers/net/sfc/efx/base/efx_intr.c | 572 + drivers/net/sfc/efx/base/efx_lic.c | 1751 +++ drivers/net/sfc/efx/base/efx_mac.c | 926 ++ drivers/net/sfc/efx/base/efx_mcdi.c | 2269 ++++ drivers/net/sfc/efx/base/efx_mcdi.h | 406 + drivers/net/sfc/efx/base/efx_mon.c | 255 + drivers/net/sfc/efx/base/efx_nic.c | 1062 ++ drivers/net/sfc/efx/base/efx_nvram.c | 1044 ++ drivers/net/sfc/efx/base/efx_phy.c | 561 + drivers/net/sfc/efx/base/efx_phy_ids.h | 51 + drivers/net/sfc/efx/base/efx_port.c | 252 + drivers/net/sfc/efx/base/efx_regs.h | 3870 ++++++ drivers/net/sfc/efx/base/efx_regs_ef10.h | 571 + drivers/net/sfc/efx/base/efx_regs_mcdi.h | 15690 ++++++++++++++++++++++ drivers/net/sfc/efx/base/efx_regs_pci.h | 2356 ++++ drivers/net/sfc/efx/base/efx_rx.c | 1315 ++ drivers/net/sfc/efx/base/efx_sram.c | 331 + drivers/net/sfc/efx/base/efx_tx.c | 1089 ++ drivers/net/sfc/efx/base/efx_types.h | 1647 +++ drivers/net/sfc/efx/base/efx_vpd.c | 1016 ++ drivers/net/sfc/efx/base/hunt_impl.h | 74 + drivers/net/sfc/efx/base/hunt_nic.c | 398 + drivers/net/sfc/efx/base/mcdi_mon.c | 565 + drivers/net/sfc/efx/base/mcdi_mon.h | 74 + drivers/net/sfc/efx/base/medford_impl.h | 67 + drivers/net/sfc/efx/base/medford_nic.c | 398 + drivers/net/sfc/efx/base/siena_flash.h | 215 + drivers/net/sfc/efx/base/siena_impl.h | 431 + drivers/net/sfc/efx/base/siena_mac.c | 476 + drivers/net/sfc/efx/base/siena_mcdi.c | 263 + drivers/net/sfc/efx/base/siena_nic.c | 581 + drivers/net/sfc/efx/base/siena_nvram.c | 734 + drivers/net/sfc/efx/base/siena_phy.c | 797 ++ drivers/net/sfc/efx/base/siena_sram.c | 178 + drivers/net/sfc/efx/base/siena_vpd.c | 618 + drivers/net/sfc/efx/efsys.h | 767 ++ drivers/net/sfc/efx/rte_pmd_sfc_efx_version.map | 4 + drivers/net/sfc/efx/sfc.c | 571 + drivers/net/sfc/efx/sfc.h | 236 + drivers/net/sfc/efx/sfc_debug.h | 57 + drivers/net/sfc/efx/sfc_ethdev.c | 465 + drivers/net/sfc/efx/sfc_ev.c | 688 + drivers/net/sfc/efx/sfc_ev.h | 144 + drivers/net/sfc/efx/sfc_intr.c | 129 + drivers/net/sfc/efx/sfc_kvargs.c | 108 + drivers/net/sfc/efx/sfc_kvargs.h | 58 + drivers/net/sfc/efx/sfc_log.h | 72 + drivers/net/sfc/efx/sfc_mcdi.c | 197 + drivers/net/sfc/efx/sfc_port.c | 189 + drivers/net/sfc/efx/sfc_rx.c | 803 ++ drivers/net/sfc/efx/sfc_rx.h | 145 + drivers/net/sfc/efx/sfc_tweak.h | 51 + drivers/net/sfc/efx/sfc_tx.c | 646 + drivers/net/sfc/efx/sfc_tx.h | 124 + mk/rte.app.mk | 1 + 93 files changed, 70142 insertions(+) create mode 100644 doc/guides/nics/features/sfc_efx.ini create mode 100644 doc/guides/nics/sfc_efx.rst create mode 100644 drivers/net/sfc/Makefile create mode 100644 drivers/net/sfc/efx/Makefile create mode 100644 drivers/net/sfc/efx/base/README create mode 100644 drivers/net/sfc/efx/base/ef10_ev.c create mode 100644 drivers/net/sfc/efx/base/ef10_filter.c create mode 100644 drivers/net/sfc/efx/base/ef10_impl.h create mode 100644 drivers/net/sfc/efx/base/ef10_intr.c create mode 100644 drivers/net/sfc/efx/base/ef10_mac.c create mode 100644 drivers/net/sfc/efx/base/ef10_mcdi.c create mode 100644 drivers/net/sfc/efx/base/ef10_nic.c create mode 100644 drivers/net/sfc/efx/base/ef10_nvram.c create mode 100644 drivers/net/sfc/efx/base/ef10_phy.c create mode 100644 drivers/net/sfc/efx/base/ef10_rx.c create mode 100644 drivers/net/sfc/efx/base/ef10_tlv_layout.h create mode 100644 drivers/net/sfc/efx/base/ef10_tx.c create mode 100644 drivers/net/sfc/efx/base/ef10_vpd.c create mode 100644 drivers/net/sfc/efx/base/efx.h create mode 100644 drivers/net/sfc/efx/base/efx_bootcfg.c create mode 100644 drivers/net/sfc/efx/base/efx_check.h create mode 100644 drivers/net/sfc/efx/base/efx_crc32.c create mode 100644 drivers/net/sfc/efx/base/efx_ev.c create mode 100644 drivers/net/sfc/efx/base/efx_filter.c create mode 100644 drivers/net/sfc/efx/base/efx_hash.c create mode 100644 drivers/net/sfc/efx/base/efx_impl.h create mode 100644 drivers/net/sfc/efx/base/efx_intr.c create mode 100644 drivers/net/sfc/efx/base/efx_lic.c create mode 100644 drivers/net/sfc/efx/base/efx_mac.c create mode 100644 drivers/net/sfc/efx/base/efx_mcdi.c create mode 100644 drivers/net/sfc/efx/base/efx_mcdi.h create mode 100644 drivers/net/sfc/efx/base/efx_mon.c create mode 100644 drivers/net/sfc/efx/base/efx_nic.c create mode 100644 drivers/net/sfc/efx/base/efx_nvram.c create mode 100644 drivers/net/sfc/efx/base/efx_phy.c create mode 100644 drivers/net/sfc/efx/base/efx_phy_ids.h create mode 100644 drivers/net/sfc/efx/base/efx_port.c create mode 100644 drivers/net/sfc/efx/base/efx_regs.h create mode 100644 drivers/net/sfc/efx/base/efx_regs_ef10.h create mode 100644 drivers/net/sfc/efx/base/efx_regs_mcdi.h create mode 100644 drivers/net/sfc/efx/base/efx_regs_pci.h create mode 100644 drivers/net/sfc/efx/base/efx_rx.c create mode 100644 drivers/net/sfc/efx/base/efx_sram.c create mode 100644 drivers/net/sfc/efx/base/efx_tx.c create mode 100644 drivers/net/sfc/efx/base/efx_types.h create mode 100644 drivers/net/sfc/efx/base/efx_vpd.c create mode 100644 drivers/net/sfc/efx/base/hunt_impl.h create mode 100644 drivers/net/sfc/efx/base/hunt_nic.c create mode 100644 drivers/net/sfc/efx/base/mcdi_mon.c create mode 100644 drivers/net/sfc/efx/base/mcdi_mon.h create mode 100644 drivers/net/sfc/efx/base/medford_impl.h create mode 100644 drivers/net/sfc/efx/base/medford_nic.c create mode 100644 drivers/net/sfc/efx/base/siena_flash.h create mode 100644 drivers/net/sfc/efx/base/siena_impl.h create mode 100644 drivers/net/sfc/efx/base/siena_mac.c create mode 100644 drivers/net/sfc/efx/base/siena_mcdi.c create mode 100644 drivers/net/sfc/efx/base/siena_nic.c create mode 100644 drivers/net/sfc/efx/base/siena_nvram.c create mode 100644 drivers/net/sfc/efx/base/siena_phy.c create mode 100644 drivers/net/sfc/efx/base/siena_sram.c create mode 100644 drivers/net/sfc/efx/base/siena_vpd.c create mode 100644 drivers/net/sfc/efx/efsys.h create mode 100644 drivers/net/sfc/efx/rte_pmd_sfc_efx_version.map create mode 100644 drivers/net/sfc/efx/sfc.c create mode 100644 drivers/net/sfc/efx/sfc.h create mode 100644 drivers/net/sfc/efx/sfc_debug.h create mode 100644 drivers/net/sfc/efx/sfc_ethdev.c create mode 100644 drivers/net/sfc/efx/sfc_ev.c create mode 100644 drivers/net/sfc/efx/sfc_ev.h create mode 100644 drivers/net/sfc/efx/sfc_intr.c create mode 100644 drivers/net/sfc/efx/sfc_kvargs.c create mode 100644 drivers/net/sfc/efx/sfc_kvargs.h create mode 100644 drivers/net/sfc/efx/sfc_log.h create mode 100644 drivers/net/sfc/efx/sfc_mcdi.c create mode 100644 drivers/net/sfc/efx/sfc_port.c create mode 100644 drivers/net/sfc/efx/sfc_rx.c create mode 100644 drivers/net/sfc/efx/sfc_rx.h create mode 100644 drivers/net/sfc/efx/sfc_tweak.h create mode 100644 drivers/net/sfc/efx/sfc_tx.c create mode 100644 drivers/net/sfc/efx/sfc_tx.h -- 2.5.5