Re: [PATCH 2/2] net: gmii2rgmii: Switch priv field in mdio device structure
From: Harini Katakam <hidden>
Date: 2019-08-13 11:16:54
Also in:
lkml, netdev
From: Harini Katakam <hidden>
Date: 2019-08-13 11:16:54
Also in:
lkml, netdev
Hi Andrew, On Thu, Aug 1, 2019 at 9:36 AM Andrew Lunn [off-list ref] wrote:
On Wed, Jul 31, 2019 at 03:06:19PM +0530, Harini Katakam wrote:quoted
Use the priv field in mdio device structure instead of the one in phy device structure. The phy device priv field may be used by the external phy driver and should not be overwritten.Hi Harini I _think_ you could use dev_set_drvdata(&mdiodev->dev) in xgmiitorgmii_probe() and dev_get_drvdata(&phydev->mdiomdio.dev) in _read_status()
Thanks for the review. This works if I do: dev_set_drvdata(&priv->phy_dev->mdio.dev->dev) in probe and then dev_get_drvdata(&phydev->mdio.dev) in _read_status() i.e mdiodev in gmii2rgmii probe and priv->phy_dev->mdio are not the same. If this is acceptable, I can send a v2. Regards, Harini _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel