|
@@ -158,9 +158,10 @@ static int i40e_ptp_adjfreq(struct ptp_clock_info *ptp, s32 ppb)
|
|
|
static int i40e_ptp_adjtime(struct ptp_clock_info *ptp, s64 delta)
|
|
|
{
|
|
|
struct i40e_pf *pf = container_of(ptp, struct i40e_pf, ptp_caps);
|
|
|
- struct timespec64 now, then = ns_to_timespec64(delta);
|
|
|
+ struct timespec64 now, then;
|
|
|
unsigned long flags;
|
|
|
|
|
|
+ then = ns_to_timespec64(delta);
|
|
|
spin_lock_irqsave(&pf->tmreg_lock, flags);
|
|
|
|
|
|
i40e_ptp_read(pf, &now);
|