Hi Florian!
On Tue, 2024-09-10 at 10:40 -0700, Florian Fainelli wrote:
RCU-protect dsa_ptr and use rcu_dereference() or rtnl_dereference() depending on the calling context.
Rename netdev_uses_dsa() into __netdev_uses_dsa_currently() (assumes ether RCU or RTNL lock held) and netdev_uses_dsa_currently() variants which better reflect the uselessness of the function's return value, which becomes outdated right after the call.
Fixes: ee534378f005 ("net: dsa: fix panic when DSA master device unbinds on shutdown") Cc: stable@vger.kernel.org Signed-off-by: Alexander Sverdlin alexander.sverdlin@siemens.com
Thanks for doing this work, just a few nits below. This is likely to be difficult to backport to stable trees.
Thanks for the quick feedback! As I've mentioned in the cover letter, I've v6.1 backport already available and I'm ready to backport to v6.8 as soon as we agree on the final form for v6.11.