Re: [PATCH 2/2] net: gmii2rgmii: Switch priv field in mdio device structure

2019-09-04 Thread Harini Katakam
Hi Andrew, On Tue, Aug 13, 2019 at 9:40 PM Andrew Lunn wrote: > > > > The kernel does have a few helper, spi_get_drvdata, pci_get_drvdata, > > > hci_get_drvdata. So maybe had add phydev_get_drvdata(struct phy_device > > > *phydev)? > > > > Maybe phydev_mdio_get_drvdata? Because the driver data me

Re: [PATCH 2/2] net: gmii2rgmii: Switch priv field in mdio device structure

2019-08-13 Thread Andrew Lunn
> > The kernel does have a few helper, spi_get_drvdata, pci_get_drvdata, > > hci_get_drvdata. So maybe had add phydev_get_drvdata(struct phy_device > > *phydev)? > > Maybe phydev_mdio_get_drvdata? Because the driver data member available is > phydev->mdio.dev.driver_data. I still prefer phydev_ge

Re: [PATCH 2/2] net: gmii2rgmii: Switch priv field in mdio device structure

2019-08-13 Thread Harini Katakam
Hi Andrew, On Tue, Aug 13, 2019 at 6:54 PM Andrew Lunn wrote: > > On Tue, Aug 13, 2019 at 04:46:40PM +0530, Harini Katakam wrote: > > Hi Andrew, > > > > On Thu, Aug 1, 2019 at 9:36 AM Andrew Lunn wrote: > > > > > > On Wed, Jul 31, 2019 at 03:06:19PM +0530, Harini Katakam wrote: > > > > Use the p

Re: [PATCH 2/2] net: gmii2rgmii: Switch priv field in mdio device structure

2019-08-13 Thread Andrew Lunn
On Tue, Aug 13, 2019 at 04:46:40PM +0530, Harini Katakam wrote: > Hi Andrew, > > On Thu, Aug 1, 2019 at 9:36 AM Andrew Lunn wrote: > > > > On Wed, Jul 31, 2019 at 03:06:19PM +0530, Harini Katakam wrote: > > > Use the priv field in mdio device structure instead of the one in > > > phy device struc

Re: [PATCH 2/2] net: gmii2rgmii: Switch priv field in mdio device structure

2019-08-13 Thread Harini Katakam
Hi Andrew, On Thu, Aug 1, 2019 at 9:36 AM Andrew Lunn wrote: > > On Wed, Jul 31, 2019 at 03:06:19PM +0530, Harini Katakam wrote: > > 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

Re: [PATCH 2/2] net: gmii2rgmii: Switch priv field in mdio device structure

2019-07-31 Thread Andrew Lunn
On Wed, Jul 31, 2019 at 03:06:19PM +0530, Harini Katakam wrote: > 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_d

[PATCH 2/2] net: gmii2rgmii: Switch priv field in mdio device structure

2019-07-31 Thread Harini Katakam
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. Signed-off-by: Harini Katakam Reviewed-by: Radhey Shyam Pandey --- drivers/net/phy/xilinx_gmii2rgmii.c | 4 ++--