Skip to content

Commit

Permalink
dp83640: Get calibration pin with ptp_find_pin
Browse files Browse the repository at this point in the history
For consistency, use the ptp_find_pin function to get the calibration pin,
not gpio_tab.

Signed-off-by: Stefan Sørensen <stefan.sorensen@spectralink.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Stefan Sørensen authored and David S. Miller committed Jul 2, 2014
1 parent 6f39eb8 commit e015595
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion drivers/net/phy/dp83640.c
Original file line number Diff line number Diff line change
Expand Up @@ -609,7 +609,11 @@ static void recalibrate(struct dp83640_clock *clock)
u16 cal_gpio, cfg0, evnt, ptp_trig, trigger, val;

trigger = CAL_TRIGGER;
cal_gpio = gpio_tab[CALIBRATE_GPIO];
cal_gpio = 1 + ptp_find_pin(clock->ptp_clock, PTP_PF_PHYSYNC, 0);
if (cal_gpio < 1) {
pr_err("PHY calibration pin not avaible - PHY is not calibrated.");
return;
}

mutex_lock(&clock->extreg_lock);

Expand Down

0 comments on commit e015595

Please sign in to comment.