]> git.baikalelectronics.ru Git - kernel.git/commit
net: dsa: mv88e6xxx: Fill in STU support for all supported chips
authorTobias Waldekranz <tobias@waldekranz.com>
Sat, 19 Mar 2022 11:03:45 +0000 (12:03 +0100)
committerJakub Kicinski <kuba@kernel.org>
Mon, 21 Mar 2022 23:43:32 +0000 (16:43 -0700)
commit04cbaa6ec7ea2a843e6d52a7232a268f042d8974
treec42510f3cf2bc13e0f2f602079d1c1d662cf3c83
parented247309607a00f2210187a465f9d37eeed1bf38
net: dsa: mv88e6xxx: Fill in STU support for all supported chips

Some chips using the split VTU/STU design will not accept VTU entries
who's SID points to an invalid STU entry. Therefore, mark all those
chips with either the mv88e6352_g1_stu_* or mv88e6390_g1_stu_* ops as
appropriate.

Notably, chips for the Opal Plus (6085/6097) era seem to use a
different implementation than those from Agate (6352) and onwards,
even though their external interface is the same. The former happily
accepts VTU entries referencing invalid STU entries, while the latter
does not.

This fixes an issue where the driver would fail to probe switch trees
that contained chips of the Agate/Topaz generation which did not
declare STU support, as loaded VTU entries would be read back as
invalid.

Fixes: e08979de4499 ("net: dsa: mv88e6xxx: Disentangle STU from VTU")
Reported-by: Marek BehĂșn <kabel@kernel.org>
Signed-off-by: Tobias Waldekranz <tobias@waldekranz.com>
Reviewed-by: Vladimir Oltean <olteanv@gmail.com>
Tested-by: Marek BehĂșn <kabel@kernel.org>
Link: https://lore.kernel.org/r/20220319110345.555270-1-tobias@waldekranz.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/dsa/mv88e6xxx/chip.c