diff options
Diffstat (limited to 'drivers/net/ethernet/freescale/gianfar_ptp.c')
| -rw-r--r-- | drivers/net/ethernet/freescale/gianfar_ptp.c | 8 | 
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/net/ethernet/freescale/gianfar_ptp.c b/drivers/net/ethernet/freescale/gianfar_ptp.c index 098f133908a..bb568006f37 100644 --- a/drivers/net/ethernet/freescale/gianfar_ptp.c +++ b/drivers/net/ethernet/freescale/gianfar_ptp.c @@ -22,7 +22,6 @@  #include <linux/device.h>  #include <linux/hrtimer.h> -#include <linux/init.h>  #include <linux/interrupt.h>  #include <linux/kernel.h>  #include <linux/module.h> @@ -134,7 +133,7 @@ struct gianfar_ptp_registers {  #define REG_SIZE	sizeof(struct gianfar_ptp_registers)  struct etsects { -	struct gianfar_ptp_registers *regs; +	struct gianfar_ptp_registers __iomem *regs;  	spinlock_t lock; /* protects regs */  	struct ptp_clock *clock;  	struct ptp_clock_info caps; @@ -415,6 +414,7 @@ static struct ptp_clock_info ptp_gianfar_caps = {  	.n_alarm	= 0,  	.n_ext_ts	= N_EXT_TS,  	.n_per_out	= 0, +	.n_pins		= 0,  	.pps		= 1,  	.adjfreq	= ptp_gianfar_adjfreq,  	.adjtime	= ptp_gianfar_adjtime, @@ -452,7 +452,9 @@ static int gianfar_ptp_probe(struct platform_device *dev)  	err = -ENODEV;  	etsects->caps = ptp_gianfar_caps; -	etsects->cksel = DEFAULT_CKSEL; + +	if (get_of_u32(node, "fsl,cksel", &etsects->cksel)) +		etsects->cksel = DEFAULT_CKSEL;  	if (get_of_u32(node, "fsl,tclk-period", &etsects->tclk_period) ||  	    get_of_u32(node, "fsl,tmr-prsc", &etsects->tmr_prsc) ||  | 
