net: dsa: Encapsulate legacy switch drivers into dsa_switch_driver
authorFlorian Fainelli <f.fainelli@gmail.com>
Sun, 8 Jan 2017 22:52:07 +0000 (14:52 -0800)
committerDavid S. Miller <davem@davemloft.net>
Mon, 9 Jan 2017 20:44:50 +0000 (15:44 -0500)
commitab3d408d3f40f939d46a32b1c24aa2833a13b846
treed63140993898647a7db28c2b635606dc1e7d8bfd
parent73095cb1881e6da77e2ed711deaf954bdfdde71e
net: dsa: Encapsulate legacy switch drivers into dsa_switch_driver

In preparation for making struct dsa_switch_ops const, encapsulate it
within a dsa_switch_driver which has a list pointer and a pointer to
dsa_switch_ops. This allows us to take the list_head pointer out of
dsa_switch_ops, which is written to by {un,}register_switch_driver.

Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/dsa/mv88e6060.c
drivers/net/dsa/mv88e6xxx/chip.c
include/net/dsa.h
net/dsa/dsa.c