2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-15 16:53:54 +08:00
linux-next/net/dsa
Vivien Didelot 3775b1b7f0 net: dsa: add master helper to look up slaves
The DSA tagging code does not need to know about the DSA architecture,
it only needs to return the slave device corresponding to the source
port index (and eventually the source device index for cascade-capable
switches) parsed from the frame received on the master device.

For this purpose, provide an inline dsa_master_get_slave helper which
validates the device and port indexes and look up the slave device.

This makes the tagging rcv functions more concise and robust, and also
makes dsa_get_cpu_port obsolete.

Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2017-10-01 04:15:07 +01:00
..
dsa2.c net: dsa: move master ethtool code 2017-09-19 16:04:23 -07:00
dsa_priv.h net: dsa: add master helper to look up slaves 2017-10-01 04:15:07 +01:00
dsa.c net: dsa: move master ethtool code 2017-09-19 16:04:23 -07:00
Kconfig dsa: add support for Microchip KSZ tail tagging 2017-05-31 20:56:31 -04:00
legacy.c net: dsa: move master ethtool code 2017-09-19 16:04:23 -07:00
Makefile net: dsa: move master ethtool code 2017-09-19 16:04:23 -07:00
master.c net: dsa: move master ethtool code 2017-09-19 16:04:23 -07:00
port.c net: dsa: add port enable and disable helpers 2017-09-25 20:22:46 -07:00
slave.c net: dsa: use phy_ethtool_nway_reset 2017-09-26 20:06:34 -07:00
switch.c net: dsa: Remove switchdev dependency from DSA switch notifier chain 2017-08-07 14:48:48 -07:00
tag_brcm.c net: dsa: add master helper to look up slaves 2017-10-01 04:15:07 +01:00
tag_dsa.c net: dsa: add master helper to look up slaves 2017-10-01 04:15:07 +01:00
tag_edsa.c net: dsa: add master helper to look up slaves 2017-10-01 04:15:07 +01:00
tag_ksz.c net: dsa: add master helper to look up slaves 2017-10-01 04:15:07 +01:00
tag_lan9303.c net: dsa: add master helper to look up slaves 2017-10-01 04:15:07 +01:00
tag_mtk.c net: dsa: add master helper to look up slaves 2017-10-01 04:15:07 +01:00
tag_qca.c net: dsa: add master helper to look up slaves 2017-10-01 04:15:07 +01:00
tag_trailer.c net: dsa: add master helper to look up slaves 2017-10-01 04:15:07 +01:00