Patch "net: dsa: Removed unneeded of_node_put in felix_parse_ports_node" has been added to the 6.4-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    net: dsa: Removed unneeded of_node_put in felix_parse_ports_node

to the 6.4-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     net-dsa-removed-unneeded-of_node_put-in-felix_parse_.patch
and it can be found in the queue-6.4 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit e63a1d795279609a3479ddd881e2263853d8e98e
Author: Lu Hongfei <luhongfei@xxxxxxxx>
Date:   Mon Jul 10 11:18:59 2023 +0800

    net: dsa: Removed unneeded of_node_put in felix_parse_ports_node
    
    [ Upstream commit 04499f28b40bfc24f20b0e2331008bb90a54a6cf ]
    
    Remove unnecessary of_node_put from the continue path to prevent
    child node from being released twice, which could avoid resource
    leak or other unexpected issues.
    
    Signed-off-by: Lu Hongfei <luhongfei@xxxxxxxx>
    Reviewed-by: Vladimir Oltean <vladimir.oltean@xxxxxxx>
    Fixes: de879a016a94 ("net: dsa: felix: add functionality when not all ports are supported")
    Link: https://lore.kernel.org/r/20230710031859.36784-1-luhongfei@xxxxxxxx
    Signed-off-by: Paolo Abeni <pabeni@xxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/net/dsa/ocelot/felix.c b/drivers/net/dsa/ocelot/felix.c
index 8348da2b3c97a..d78b4bd4787e8 100644
--- a/drivers/net/dsa/ocelot/felix.c
+++ b/drivers/net/dsa/ocelot/felix.c
@@ -1286,7 +1286,6 @@ static int felix_parse_ports_node(struct felix *felix,
 		if (err < 0) {
 			dev_info(dev, "Unsupported PHY mode %s on port %d\n",
 				 phy_modes(phy_mode), port);
-			of_node_put(child);
 
 			/* Leave port_phy_modes[port] = 0, which is also
 			 * PHY_INTERFACE_MODE_NA. This will perform a



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux