提交 9d73adf4 编写于 作者: F Fabio Estevam 提交者: David S. Miller

fec: Fix the build as module

Since commit ff43da86 (NET: FEC: dynamtic check DMA desc buff type) the
following build error happens when CONFIG_FEC=m

ERROR: "fec_ptp_init" [drivers/net/ethernet/freescale/fec.ko] undefined!
ERROR: "fec_ptp_ioctl" [drivers/net/ethernet/freescale/fec.ko] undefined!
ERROR: "fec_ptp_start_cyclecounter" [drivers/net/ethernet/freescale/fec.ko] undefined!

Fix it by exporting the required fec_ptp symbols.
Reported-by: NUwe Kleine-Koenig <u.kleine-koenig@pengutronix.de>
Signed-off-by: NFabio Estevam <fabio.estevam@freescale.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 da2191e3
...@@ -128,6 +128,7 @@ void fec_ptp_start_cyclecounter(struct net_device *ndev) ...@@ -128,6 +128,7 @@ void fec_ptp_start_cyclecounter(struct net_device *ndev)
spin_unlock_irqrestore(&fep->tmreg_lock, flags); spin_unlock_irqrestore(&fep->tmreg_lock, flags);
} }
EXPORT_SYMBOL(fec_ptp_start_cyclecounter);
/** /**
* fec_ptp_adjfreq - adjust ptp cycle frequency * fec_ptp_adjfreq - adjust ptp cycle frequency
...@@ -318,6 +319,7 @@ int fec_ptp_ioctl(struct net_device *ndev, struct ifreq *ifr, int cmd) ...@@ -318,6 +319,7 @@ int fec_ptp_ioctl(struct net_device *ndev, struct ifreq *ifr, int cmd)
return copy_to_user(ifr->ifr_data, &config, sizeof(config)) ? return copy_to_user(ifr->ifr_data, &config, sizeof(config)) ?
-EFAULT : 0; -EFAULT : 0;
} }
EXPORT_SYMBOL(fec_ptp_ioctl);
/** /**
* fec_time_keep - call timecounter_read every second to avoid timer overrun * fec_time_keep - call timecounter_read every second to avoid timer overrun
...@@ -383,3 +385,4 @@ void fec_ptp_init(struct net_device *ndev, struct platform_device *pdev) ...@@ -383,3 +385,4 @@ void fec_ptp_init(struct net_device *ndev, struct platform_device *pdev)
pr_info("registered PHC device on %s\n", ndev->name); pr_info("registered PHC device on %s\n", ndev->name);
} }
} }
EXPORT_SYMBOL(fec_ptp_init);
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册