2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-21 03:33:59 +08:00

docs: networking: device drivers: convert freescale/dpaa.txt to ReST

- add SPDX header;
- adjust titles and chapters, adding proper markups;
- mark code blocks and literals as such;
- use :field: markup;
- add to networking/index.rst.

Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Mauro Carvalho Chehab 2020-05-01 16:44:44 +02:00 committed by David S. Miller
parent ca705e4793
commit 0d0d976f59
2 changed files with 75 additions and 65 deletions

View File

@ -1,12 +1,14 @@
.. SPDX-License-Identifier: GPL-2.0
==============================
The QorIQ DPAA Ethernet Driver The QorIQ DPAA Ethernet Driver
============================== ==============================
Authors: Authors:
Madalin Bucur <madalin.bucur@nxp.com> - Madalin Bucur <madalin.bucur@nxp.com>
Camelia Groza <camelia.groza@nxp.com> - Camelia Groza <camelia.groza@nxp.com>
Contents .. Contents
========
- DPAA Ethernet Overview - DPAA Ethernet Overview
- DPAA Ethernet Supported SoCs - DPAA Ethernet Supported SoCs
@ -34,7 +36,7 @@ following drivers in the Linux kernel:
- Queue Manager (QMan), Buffer Manager (BMan) - Queue Manager (QMan), Buffer Manager (BMan)
drivers/soc/fsl/qbman drivers/soc/fsl/qbman
A simplified view of the dpaa_eth interfaces mapped to FMan MACs: A simplified view of the dpaa_eth interfaces mapped to FMan MACs::
dpaa_eth /eth0\ ... /ethN\ dpaa_eth /eth0\ ... /ethN\
driver | | | | driver | | | |
@ -42,89 +44,93 @@ A simplified view of the dpaa_eth interfaces mapped to FMan MACs:
-Ports / Tx Rx \ ... / Tx Rx \ -Ports / Tx Rx \ ... / Tx Rx \
FMan | | | | FMan | | | |
-MACs | MAC0 | | MACN | -MACs | MAC0 | | MACN |
/ dtsec0 \ ... / dtsecN \ (or tgec) / dtsec0 \ ... / dtsecN \ (or tgec)
/ \ / \(or memac) / \ / \(or memac)
--------- -------------- --- -------------- --------- --------- -------------- --- -------------- ---------
FMan, FMan Port, FMan SP, FMan MURAM drivers FMan, FMan Port, FMan SP, FMan MURAM drivers
--------------------------------------------------------- ---------------------------------------------------------
FMan HW blocks: MURAM, MACs, Ports, SP FMan HW blocks: MURAM, MACs, Ports, SP
--------------------------------------------------------- ---------------------------------------------------------
The dpaa_eth relation to the QMan, BMan and FMan: The dpaa_eth relation to the QMan, BMan and FMan::
________________________________
________________________________
dpaa_eth / eth0 \ dpaa_eth / eth0 \
driver / \ driver / \
--------- -^- -^- -^- --- --------- --------- -^- -^- -^- --- ---------
QMan driver / \ / \ / \ \ / | BMan | QMan driver / \ / \ / \ \ / | BMan |
|Rx | |Rx | |Tx | |Tx | | driver | |Rx | |Rx | |Tx | |Tx | | driver |
--------- |Dfl| |Err| |Cnf| |FQs| | | --------- |Dfl| |Err| |Cnf| |FQs| | |
QMan HW |FQ | |FQ | |FQs| | | | | QMan HW |FQ | |FQ | |FQs| | | | |
/ \ / \ / \ \ / | | / \ / \ / \ \ / | |
--------- --- --- --- -v- --------- --------- --- --- --- -v- ---------
| FMan QMI | | | FMan QMI | |
| FMan HW FMan BMI | BMan HW | | FMan HW FMan BMI | BMan HW |
----------------------- -------- ----------------------- --------
where the acronyms used above (and in the code) are: where the acronyms used above (and in the code) are:
DPAA = Data Path Acceleration Architecture
FMan = DPAA Frame Manager =============== ===========================================================
QMan = DPAA Queue Manager DPAA Data Path Acceleration Architecture
BMan = DPAA Buffers Manager FMan DPAA Frame Manager
QMI = QMan interface in FMan QMan DPAA Queue Manager
BMI = BMan interface in FMan BMan DPAA Buffers Manager
FMan SP = FMan Storage Profiles QMI QMan interface in FMan
MURAM = Multi-user RAM in FMan BMI BMan interface in FMan
FQ = QMan Frame Queue FMan SP FMan Storage Profiles
Rx Dfl FQ = default reception FQ MURAM Multi-user RAM in FMan
Rx Err FQ = Rx error frames FQ FQ QMan Frame Queue
Tx Cnf FQ = Tx confirmation FQs Rx Dfl FQ default reception FQ
Tx FQs = transmission frame queues Rx Err FQ Rx error frames FQ
dtsec = datapath three speed Ethernet controller (10/100/1000 Mbps) Tx Cnf FQ Tx confirmation FQs
tgec = ten gigabit Ethernet controller (10 Gbps) Tx FQs transmission frame queues
memac = multirate Ethernet MAC (10/100/1000/10000) dtsec datapath three speed Ethernet controller (10/100/1000 Mbps)
tgec ten gigabit Ethernet controller (10 Gbps)
memac multirate Ethernet MAC (10/100/1000/10000)
=============== ===========================================================
DPAA Ethernet Supported SoCs DPAA Ethernet Supported SoCs
============================ ============================
The DPAA drivers enable the Ethernet controllers present on the following SoCs: The DPAA drivers enable the Ethernet controllers present on the following SoCs:
# PPC PPC
P1023 - P1023
P2041 - P2041
P3041 - P3041
P4080 - P4080
P5020 - P5020
P5040 - P5040
T1023 - T1023
T1024 - T1024
T1040 - T1040
T1042 - T1042
T2080 - T2080
T4240 - T4240
B4860 - B4860
# ARM ARM
LS1043A - LS1043A
LS1046A - LS1046A
Configuring DPAA Ethernet in your kernel Configuring DPAA Ethernet in your kernel
======================================== ========================================
To enable the DPAA Ethernet driver, the following Kconfig options are required: To enable the DPAA Ethernet driver, the following Kconfig options are required::
# common for arch/arm64 and arch/powerpc platforms # common for arch/arm64 and arch/powerpc platforms
CONFIG_FSL_DPAA=y CONFIG_FSL_DPAA=y
CONFIG_FSL_FMAN=y CONFIG_FSL_FMAN=y
CONFIG_FSL_DPAA_ETH=y CONFIG_FSL_DPAA_ETH=y
CONFIG_FSL_XGMAC_MDIO=y CONFIG_FSL_XGMAC_MDIO=y
# for arch/powerpc only # for arch/powerpc only
CONFIG_FSL_PAMU=y CONFIG_FSL_PAMU=y
# common options needed for the PHYs used on the RDBs # common options needed for the PHYs used on the RDBs
CONFIG_VITESSE_PHY=y CONFIG_VITESSE_PHY=y
CONFIG_REALTEK_PHY=y CONFIG_REALTEK_PHY=y
CONFIG_AQUANTIA_PHY=y CONFIG_AQUANTIA_PHY=y
DPAA Ethernet Frame Processing DPAA Ethernet Frame Processing
============================== ==============================
@ -167,7 +173,9 @@ classes as follows:
* priorities 8 to 11 - traffic class 2 (medium-high priority) * priorities 8 to 11 - traffic class 2 (medium-high priority)
* priorities 12 to 15 - traffic class 3 (high priority) * priorities 12 to 15 - traffic class 3 (high priority)
tc qdisc add dev <int> root handle 1: \ ::
tc qdisc add dev <int> root handle 1: \
mqprio num_tc 4 map 0 0 0 0 1 1 1 1 2 2 2 2 3 3 3 3 hw 1 mqprio num_tc 4 map 0 0 0 0 1 1 1 1 2 2 2 2 3 3 3 3 hw 1
DPAA IRQ Affinity and Receive Side Scaling DPAA IRQ Affinity and Receive Side Scaling
@ -201,11 +209,11 @@ of these frame queues will arrive at the same portal and will always
be processed by the same CPU. This ensures intra-flow order preservation be processed by the same CPU. This ensures intra-flow order preservation
and workload distribution for multiple traffic flows. and workload distribution for multiple traffic flows.
RSS can be turned off for a certain interface using ethtool, i.e. RSS can be turned off for a certain interface using ethtool, i.e.::
# ethtool -N fm1-mac9 rx-flow-hash tcp4 "" # ethtool -N fm1-mac9 rx-flow-hash tcp4 ""
To turn it back on, one needs to set rx-flow-hash for tcp4/6 or udp4/6: To turn it back on, one needs to set rx-flow-hash for tcp4/6 or udp4/6::
# ethtool -N fm1-mac9 rx-flow-hash udp4 sfdn # ethtool -N fm1-mac9 rx-flow-hash udp4 sfdn
@ -216,7 +224,7 @@ going to control the rx-flow-hashing for all protocols on that interface.
Besides using the FMan Keygen computed hash for spreading traffic on the Besides using the FMan Keygen computed hash for spreading traffic on the
128 Rx FQs, the DPAA Ethernet driver also sets the skb hash value when 128 Rx FQs, the DPAA Ethernet driver also sets the skb hash value when
the NETIF_F_RXHASH feature is on (active by default). This can be turned the NETIF_F_RXHASH feature is on (active by default). This can be turned
on or off through ethtool, i.e.: on or off through ethtool, i.e.::
# ethtool -K fm1-mac9 rx-hashing off # ethtool -K fm1-mac9 rx-hashing off
# ethtool -k fm1-mac9 | grep hash # ethtool -k fm1-mac9 | grep hash
@ -246,6 +254,7 @@ The following statistics are exported for each interface through ethtool:
- Rx error count per CPU - Rx error count per CPU
- Rx error count per type - Rx error count per type
- congestion related statistics: - congestion related statistics:
- congestion status - congestion status
- time spent in congestion - time spent in congestion
- number of time the device entered congestion - number of time the device entered congestion
@ -254,7 +263,7 @@ The following statistics are exported for each interface through ethtool:
The driver also exports the following information in sysfs: The driver also exports the following information in sysfs:
- the FQ IDs for each FQ type - the FQ IDs for each FQ type
/sys/devices/platform/soc/<addr>.fman/<addr>.ethernet/dpaa-ethernet.<id>/net/fm<nr>-mac<nr>/fqids /sys/devices/platform/soc/<addr>.fman/<addr>.ethernet/dpaa-ethernet.<id>/net/fm<nr>-mac<nr>/fqids
- the ID of the buffer pool in use - the ID of the buffer pool in use
/sys/devices/platform/soc/<addr>.fman/<addr>.ethernet/dpaa-ethernet.<id>/net/fm<nr>-mac<nr>/bpids /sys/devices/platform/soc/<addr>.fman/<addr>.ethernet/dpaa-ethernet.<id>/net/fm<nr>-mac<nr>/bpids

View File

@ -37,6 +37,7 @@ Contents:
dec/de4x5 dec/de4x5
dec/dmfe dec/dmfe
dlink/dl2k dlink/dl2k
freescale/dpaa
.. only:: subproject and html .. only:: subproject and html