mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-23 01:10:04 +00:00
fec: Only pass pdev in fec_ptp_init()
Passing pdev in fec_ptp_init() is enough, since we can get ndev locally. Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
28850dc7c7
commit
ca162a82f5
3 changed files with 4 additions and 3 deletions
|
@ -275,7 +275,7 @@ struct fec_enet_private {
|
|||
struct regulator *reg_phy;
|
||||
};
|
||||
|
||||
void fec_ptp_init(struct net_device *ndev, struct platform_device *pdev);
|
||||
void fec_ptp_init(struct platform_device *pdev);
|
||||
void fec_ptp_start_cyclecounter(struct net_device *ndev);
|
||||
int fec_ptp_ioctl(struct net_device *ndev, struct ifreq *ifr, int cmd);
|
||||
|
||||
|
|
|
@ -1945,7 +1945,7 @@ fec_probe(struct platform_device *pdev)
|
|||
fec_reset_phy(pdev);
|
||||
|
||||
if (fep->bufdesc_ex)
|
||||
fec_ptp_init(ndev, pdev);
|
||||
fec_ptp_init(pdev);
|
||||
|
||||
ret = fec_enet_init(ndev);
|
||||
if (ret)
|
||||
|
|
|
@ -347,8 +347,9 @@ static void fec_time_keep(unsigned long _data)
|
|||
* cyclecounter init routine and exits.
|
||||
*/
|
||||
|
||||
void fec_ptp_init(struct net_device *ndev, struct platform_device *pdev)
|
||||
void fec_ptp_init(struct platform_device *pdev)
|
||||
{
|
||||
struct net_device *ndev = platform_get_drvdata(pdev);
|
||||
struct fec_enet_private *fep = netdev_priv(ndev);
|
||||
|
||||
fep->ptp_caps.owner = THIS_MODULE;
|
||||
|
|
Loading…
Reference in a new issue