diff options
author | Russell King (Oracle) <rmk+kernel@armlinux.org.uk> | 2025-01-08 16:48:30 +0000 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2025-01-10 17:51:02 -0800 |
commit | 0a900ea89a0cdf2a09e987663192ab5e0a28544e (patch) | |
tree | 36728cbbbdb5ae44f405763858977172b3cae7cc /tools/perf/scripts/python/export-to-postgresql.py | |
parent | 2914a5cd811ac0f4e7c3b5db5a5d43041636f8dc (diff) |
net: stmmac: move priv->eee_enabled into stmmac_eee_init()
All call sites for stmmac_eee_init() assign the return code to
priv->eee_enabled. Rather than having this coded at each call site,
move the assignment inside stmmac_eee_init().
Since stmmac_init_eee() takes priv->lock before checking the state of
priv->eee_enabled, move the assignment within the locked region. Also,
stmmac_suspend() checks the state of this member under the lock. While
two concurrent calls to stmmac_init_eee() aren't possible, there is
a possibility that stmmac_suspend() may run concurrently with a change
of priv->eee_enabled unless we modify it under the lock.
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Tested-by: Choong Yong Liang <yong.liang.choong@linux.intel.com>
Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
Link: https://patch.msgid.link/E1tVZEM-0002Kq-2Z@rmk-PC.armlinux.org.uk
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions