mirror of
https://github.com/torvalds/linux.git
synced 2024-11-15 16:41:58 +00:00
4ac0567e40
It's nice to be able to test a tagging protocol with dsa_loop, but not
at the cost of losing the ability of building the tagging protocol and
switch driver as modules, because as things stand, there is a circular
dependency between the two. Tagging protocol drivers cannot depend on
switch drivers, that is a hard fact.
The reasoning behind the blamed patch was that accessing dp->priv should
first make sure that the structure behind that pointer is what we really
think it is.
Currently the "sja1105" and "sja1110" tagging protocols only operate
with the sja1105 switch driver, just like any other tagging protocol and
switch combination. The only way to mix and match them is by modifying
the code, and this applies to dsa_loop as well (by default that uses
DSA_TAG_PROTO_NONE). So while in principle there is an issue, in
practice there isn't one.
Until we extend dsa_loop to allow user space configuration, treat the
problem as a non-issue and just say that DSA ports found by tag_sja1105
are always sja1105 ports, which is in fact true. But keep the
dsa_port_is_sja1105 function so that it's easy to patch it during
testing, and rely on dead code elimination.
Fixes:
|
||
---|---|---|
.. | ||
Kconfig | ||
Makefile | ||
sja1105_clocking.c | ||
sja1105_devlink.c | ||
sja1105_dynamic_config.c | ||
sja1105_dynamic_config.h | ||
sja1105_ethtool.c | ||
sja1105_flower.c | ||
sja1105_main.c | ||
sja1105_mdio.c | ||
sja1105_ptp.c | ||
sja1105_ptp.h | ||
sja1105_spi.c | ||
sja1105_static_config.c | ||
sja1105_static_config.h | ||
sja1105_tas.c | ||
sja1105_tas.h | ||
sja1105_vl.c | ||
sja1105_vl.h | ||
sja1105.h |