Merge branch 'dsa-tagger-storage'
Vladimir Oltean says: ==================== Replace DSA dp->priv with tagger-owned storage Ansuel's recent work on qca8k register access over Ethernet: https://patchwork.kernel.org/project/netdevbpf/cover/20211207145942.7444-1-ansuelsmth@gmail.com/ has triggered me to do something which I should've done for a longer time: https://patchwork.kernel.org/project/netdevbpf/patch/20211109095013.27829-7-martin.kaistra@linutronix.de/#24585521 which is to replace dp->priv with something that has less caveats. The dp->priv was introduced when sja1105 needed to hold stateful information in the tagging protocol driver. In that design, dp->priv held memory allocated by the switch driver, because the tagging protocol driver design was 100% stateless. Some years have passed and others have started to feel the need for stateful information kept by the tagger, as well as passing data back and forth between the tagging protocol driver and the switch driver. This isn't possible cleanly in DSA due to a circular dependency which leads to broken module autoloading: https://lore.kernel.org/netdev/20210908220834.d7gmtnwrorhharna@skbuf/ This patchset introduces a framework that resembles something normal, which allows data to be passed from the tagging protocol driver (things like switch management packets, which aren't intended for the network stack) to the switch driver, while the tagging protocol still remains more or less stateless. The overall design of the framework was discussed with Ansuel too and it appears to be flexible enough to cover the "register access over Ethernet" use case. Additionally, the existing uses of dp->priv, which have mainly to do with PTP timestamping, have also been migrated. Changes in v2: Fix transient build breakage in patch 5/11 due to a missing parenthesis, https://patchwork.hopto.org/static/nipa/592567/12665213/build_clang/ and another transient build warning in patch 4/11 that for some reason doesn't appear in my W=1 C=1 build. https://patchwork.hopto.org/static/nipa/592567/12665209/build_clang/stderr ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
Showing
Please register or sign in to comment