]> git.baikalelectronics.ru Git - kernel.git/commit
net-next: dsa: add dsa support for Mediatek MT7530 switch
authorSean Wang <sean.wang@mediatek.com>
Fri, 7 Apr 2017 08:45:09 +0000 (16:45 +0800)
committerDavid S. Miller <davem@davemloft.net>
Fri, 7 Apr 2017 20:52:11 +0000 (13:52 -0700)
commit6c2eb115dba911a3b995daa16fb120ba46c89596
tree270bbb32004a50adf2c123ded98de61fc49c1d7b
parent23a9fd8c5a32d2969037de7c8e00b8107f2f3d67
net-next: dsa: add dsa support for Mediatek MT7530 switch

MT7530 is a 7-ports Gigabit Ethernet Switch that could be found on
Mediatek router platforms such as MT7623A or MT7623N platform which
includes 7-port Gigabit Ethernet MAC and 5-port Gigabit Ethernet PHY.
Among these ports, The port from 0 to 4 are the user ports connecting
with the remote devices while the port 5 and 6 are the CPU ports
connecting into Mediatek Ethernet GMAC.

For port 6, it can communicate with the CPU via Mediatek Ethernet GMAC
through either the TRGMII or RGMII which could be controlled by phy-mode
in the dt-bindings to specify which mode is preferred to use. And for
port 5, only RGMII can be specified. However, currently, only port 6 is
being supported in this DSA driver.

The driver is made with the reference to qca8k and other existing DSA
driver. The most of the essential callbacks of the DSA are already
support in the driver, including tag insert for user port distinguishing,
port control, bridge offloading, STP setup and ethtool operation to allow
DSA to model each user port into a standalone netdevice as the other DSA
driver had done.

Signed-off-by: Sean Wang <sean.wang@mediatek.com>
Signed-off-by: Landen Chao <Landen.Chao@mediatek.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/dsa/Kconfig
drivers/net/dsa/Makefile
drivers/net/dsa/mt7530.c [new file with mode: 0644]
drivers/net/dsa/mt7530.h [new file with mode: 0644]