On Tue, Jan 12, 2021 at 05:55:54PM +0200, Andy Shevchenko wrote: > On Tue, Jan 12, 2021 at 3:43 PM Calvin Johnson > <calvin.john...@oss.nxp.com> wrote: > > > > Define phylink_fwnode_phy_connect() to connect phy specified by > > a fwnode to a phylink instance. > > ... > > > + phy_dev = fwnode_phy_find_device(phy_fwnode); > > + /* We're done with the phy_node handle */ > > + fwnode_handle_put(phy_fwnode); > > + if (!phy_dev) > > + return -ENODEV; > > + > > + ret = phy_attach_direct(pl->netdev, phy_dev, flags, > > + pl->link_interface); > > + if (ret) > > Hmm... Shouldn't you put phy_dev here? I think you are right. We may have to add put_device(&phydev->mdio.dev); It is missing in phylink_of_phy_connect() as well. > > > + return ret; > > -- Thanks Calvin
- Re: [net-next PATCH v3 09/15] device property: Introd... Andy Shevchenko
- Re: [net-next PATCH v3 09/15] device property: Introd... Andy Shevchenko
- Re: [net-next PATCH v3 09/15] device property: Introd... Calvin Johnson
- [net-next PATCH v3 10/15] net: mdio: Add ACPI support code... Calvin Johnson
- [net-next PATCH v3 11/15] net: mdiobus: Introduce fwnode_m... Calvin Johnson
- Re: [net-next PATCH v3 11/15] net: mdiobus: Introduce... Andy Shevchenko
- [net-next PATCH v3 12/15] net/fsl: Use fwnode_mdiobus_regi... Calvin Johnson
- Re: [net-next PATCH v3 12/15] net/fsl: Use fwnode_mdi... Andy Shevchenko
- [net-next PATCH v3 13/15] phylink: introduce phylink_fwnod... Calvin Johnson
- Re: [net-next PATCH v3 13/15] phylink: introduce phyl... Andy Shevchenko
- Re: [net-next PATCH v3 13/15] phylink: introduce ... Calvin Johnson
- [net-next PATCH v3 05/15] net: phy: Introduce fwnode_get_p... Calvin Johnson
- [net-next PATCH v3 08/15] of: mdio: Refactor of_mdiobus_re... Calvin Johnson
- [net-next PATCH v3 14/15] net: phylink: Refactor phylink_o... Calvin Johnson
- Re: [net-next PATCH v3 14/15] net: phylink: Refactor ... Andy Shevchenko
- Re: [net-next PATCH v3 14/15] net: phylink: Refac... Calvin Johnson
- [net-next PATCH v3 15/15] net: dpaa2-mac: Add ACPI support... Calvin Johnson