OSDN Git Service

net: dsa: lan9303: Add basic offloading of unicast traffic
authorEgil Hjelmeland <privat@egil-hjelmeland.no>
Tue, 10 Oct 2017 12:49:53 +0000 (14:49 +0200)
committerDavid S. Miller <davem@davemloft.net>
Wed, 11 Oct 2017 20:53:21 +0000 (13:53 -0700)
commitd99a86ae83d28ad08bcd46570d81033b48db2ca0
tree3305634ee07187260e5a9cc340d5c7a5ffc4407a
parentf7e3bfa14daa35ea393ad6389c9e01e61196e93f
net: dsa: lan9303: Add basic offloading of unicast traffic

When both user ports are joined to the same bridge, the normal
HW MAC learning is enabled. This means that unicast traffic is forwarded
in HW.

If one of the user ports leave the bridge,
the ports goes back to the initial separated operation.

Port separation relies on disabled HW MAC learning. Hence the condition
that both ports must join same bridge.

Add brigde methods port_bridge_join, port_bridge_leave and
port_stp_state_set.

Signed-off-by: Egil Hjelmeland <privat@egil-hjelmeland.no>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/dsa/lan9303-core.c
drivers/net/dsa/lan9303.h