net: sungem_phy: Add of_node_put() for reference returned by of_get_parent()
Subsystems (2)
PATCH 1/1 net: sungem_phy: Add of_node_put() for reference returned by of_get_parent()
In bcm5421_init(), we should call of_node_put() for the reference returned by of_get_parent() which has increased the refcount.
Fixes 3c326fe9cb7a ("[PATCH] ppc64: Add new PHY to sungem")
Signed-off-by Liang He <[email protected]>
--- drivers/net/sungem_phy.c | 1 + 1 file changed, 1 insertion(+)
drivers/net/sungem_phy.c +1 -0
@@ -450,6 +450,7 @@ static int bcm5421_init(struct mii_phy* phy)int can_low_power =1 ;if (np ==NULL ||of_get_property (np,"no-autolowpower" ,NULL )) can_low_power =0 ; +of_node_put (np);if (can_low_power) {/* Enable automatic low-power */ sungem_phy_write (phy,0x1c ,0x9002 );
Signature · 1 line
2.25.1
This patch was applied to netdev/net.git (master) by Jakub Kicinski <[email protected]>:
Hello:
This patch was applied to netdev/net.git (master)
by Jakub Kicinski <[email protected]>:
Quoted 8 lines · On Wed, 20 Jul 2022 21:10:03 +0800 you wrote:
In
bcm5421_init(), we should callof_node_put()for the reference returned byof_get_parent()which has increased the refcount.Fixes 3c326fe9cb7a ("[PATCH] ppc64: Add new PHY to sungem")Signed-off-by Liang He <[email protected]>--- drivers/net/sungem_phy.c | 1 + 1 file changed, 1 insertion(+)
Here is the summary with links:
- net: sungem_phy: Add of_node_put() for reference returned by of_get_parent()
https://git.kernel.org/netdev/net/c/ebbbe23fdf60
You are awesome, thank you!
Signature · 2 lines
Deet-doot-dot, I am a bot. https://korg.docs.kernel.org/patchwork/pwbot.html