realtek: initialize port masks to match the default state
authorJan Hoffmann <jan@3e8.eu>
Sat, 6 May 2023 17:28:53 +0000 (19:28 +0200)
committerSander Vanheule <sander@svanheule.net>
Sun, 7 May 2023 17:07:34 +0000 (19:07 +0200)
commit4c0a1667f3e752d31b22ca699a9a3fda5eb47dc7
treefbf242e2583e8e78f456e78c703fceddee0c5f4f
parent3af984e46e37d5fa2e700143d85a199c85653872
realtek: initialize port masks to match the default state

All ports are disabled by default, so configure the port isolation masks
and the pm field accordingly in the setup function. When port_enable is
called for a port, the isolation masks will be set up so that traffic
can flow between the port and the CPU.

While at it, change the code to also use the traffic_set method in
rtl83xx_setup, instead of writing to the RTL838x_PORT_ISO_CTRL(i)
registers directly.

Signed-off-by: Jan Hoffmann <jan@3e8.eu>
target/linux/realtek/files-5.10/drivers/net/dsa/rtl83xx/dsa.c
target/linux/realtek/files-5.15/drivers/net/dsa/rtl83xx/dsa.c