]> git.baikalelectronics.ru Git - kernel.git/commit
Merge branch 'dsa-mv88e6xxx-port-operation-refine'
authorDavid S. Miller <davem@davemloft.net>
Fri, 4 Nov 2016 18:40:01 +0000 (14:40 -0400)
committerDavid S. Miller <davem@davemloft.net>
Fri, 4 Nov 2016 18:40:01 +0000 (14:40 -0400)
commit151fff4d29b7e99d4c6561babcb6ed4bc7746c5b
tree5731f39f46b1b3762138b5c47a15a1c26e9bfe02
parent9d9243ede4c44cd4d89f6f767ee8225c6ac255c2
parenta63d22df6ca3d3c3ffa8aba583558029f383c71c
Merge branch 'dsa-mv88e6xxx-port-operation-refine'

Vivien Didelot says:

====================
net: dsa: mv88e6xxx: refine port operations

The Marvell chips have one internal SMI device per port, containing a
set of registers used to configure a port's link, STP state, default
VLAN or addresses database, etc.

This patchset creates port files to implement the port operations as
described in datasheets, and extend the chip ops structure with them.

Patches 1 to 6 implement accessors for port's STP state, port based VLAN
map, default FID, default VID, and 802.1Q mode.

Patches 7 to 11 implement the port's MAC setup of link state, duplex
mode, RGMII delay and speed, all accessed through port's register 0x01.

The new port's MAC setup code is used to re-implement the adjust_link
code and correctly force the link down before changing any of the MAC
settings, as requested by the datasheets.

The port's MAC accessors use values compatible with struct phy_device
(e.g. DUPLEX_FULL) and extend them when needed (e.g. SPEED_MAX).

Changes in v2:

  - Strictly use new _UNFORCED values instead of re-using _UNKNOWN ones.
====================

Signed-off-by: David S. Miller <davem@davemloft.net>