diff options
author | Linus Walleij <linus.walleij@linaro.org> | 2020-10-08 23:03:40 +0200 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2020-10-10 11:25:05 -0700 |
commit | e0b2e0d8e6692ee488387aba871d0b70e1ed400a (patch) | |
tree | b2e7ac2478de7087a1e651e09015012c806bc603 /drivers/net/dsa/realtek-smi-core.h | |
parent | 14b26b127c098bbab9b364d90a007c478090bf5f (diff) |
net: dsa: rtl8366rb: Roof MTU for switch
The MTU setting for this DSA switch is global so we need
to keep track of the MTU set for each port, then as soon
as any MTU changes, roof the MTU to the biggest common
denominator and poke that into the switch MTU setting.
To achieve this we need a per-chip-variant state container
for the RTL8366RB to use for the RTL8366RB-specific
stuff. Other SMI switches does seem to have per-port
MTU setting capabilities.
Fixes: 5f4a8ef384db ("net: dsa: rtl8366rb: Support setting MTU")
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'drivers/net/dsa/realtek-smi-core.h')
-rw-r--r-- | drivers/net/dsa/realtek-smi-core.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/dsa/realtek-smi-core.h b/drivers/net/dsa/realtek-smi-core.h index 5e2e11a26da3..6b6a3dec0984 100644 --- a/drivers/net/dsa/realtek-smi-core.h +++ b/drivers/net/dsa/realtek-smi-core.h @@ -71,6 +71,7 @@ struct realtek_smi { int vlan4k_enabled; char buf[4096]; + void *chip_data; /* Per-chip extra variant data */ }; /** @@ -111,6 +112,7 @@ struct realtek_smi_variant { unsigned int clk_delay; u8 cmd_read; u8 cmd_write; + size_t chip_data_sz; }; /* SMI core calls */ |