summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python
diff options
context:
space:
mode:
authorAli Tariq <alitariq45892@gmail.com>2026-11-13 18:24:35 +0500
committerJakub Kicinski <kuba@kernel.org>2026-11-17 17:57:30 -0800
commitf60eae61466cca9b50690bd3f2b5b4b2397d9376 (patch)
tree51e2a4f87f575b414acfd251ca63d643e9d1e1da /tools/perf/scripts/python
parent0dcf21648f258d2be36def2aacc8c7ee5e15e2ee (diff)
net: spacemit: Hold RTNL lock in emac_resume() and emac_suspend()
The emac_resume() calls the emac_open() and emac_suspend() calls emac_stop() functions directly without holding the lock through rtnl_lock(). These functions rely on phy_disconnect() which reads pointer with rtnl_dereference(). But since no lock is being held, rtnl_dereference throws a suspicious RCU usage on Orange Pi RV2 (SpacemiT K1) warning when lockdep is enabled. WARNING: suspicious RCU usage drivers/net/phy/phy_device.c:1831 suspicious rcu_dereference_protected() usage! Call Trace: phy_detach_internal+0x490/0x5f2 phy_disconnect+0x90/0xc0 emac_stop+0x114/0x626 emac_suspend+0xac/0x126 platform_pm_suspend+0x72/0xe4 Take RTNL in emac_suspend() and emac_resume() before the netif_running() checks, so the interface can't be opened or closed between the check and emac_stop() or emac_open(). Found by CI suspend tests on Orange Pi RV2 (SpacemiT K1). Tested on the same board with lockdep enabled: 12 suspend/resume cycles without the warning, and kselftest with no new failures. Fixes: bfec6d7f2001 ("net: spacemit: Add K1 Ethernet MAC") Signed-off-by: Ali Tariq <alitariq45892@gmail.com> Reviewed-by: Vivian Wang <wangruikang@iscas.ac.cn> Reviewed-by: Muhammad Bilal <meatuni001@gmail.com> Link: https://patch.msgid.link/20261113132435.434615-3-alitariq45892@gmail.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions