net: dsa: slave: fix of-node leak and phy priority
BugLink: https://bugs.launchpad.net/bugs/1878232 commit 0d8f3c67 upstream. Make sure to drop the reference taken by of_parse_phandle() before returning from dsa_slave_phy_setup(). Note that this also modifies the PHY priority so that any fixed-link node is only parsed when no phy-handle is given, which is in accordance with the common scheme for this. Fixes: 0d8bcdd3 ("net: dsa: allow for more complex PHY setups") Signed-off-by:Johan Hovold <johan@kernel.org> Signed-off-by:
David S. Miller <davem@davemloft.net> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by:
Ian May <ian.may@canonical.com> Signed-off-by:
Kleber Sacilotto de Souza <kleber.souza@canonical.com>
Showing
Please register or sign in to comment