Re: [PATCH net-next V2 13/23] ptp: igb: convert to the 64 bit get/set time methods.

From: Arnd Bergmann
Date: Sat Mar 21 2015 - 22:41:14 EST


On Saturday 21 March 2015, Richard Cochran wrote:
> @@ -269,13 +270,13 @@ static int igb_ptp_adjtime_i210(struct ptp_clock_info *ptp, s64 delta)
> struct igb_adapter *igb = container_of(ptp, struct igb_adapter,
> ptp_caps);
> unsigned long flags;
> - struct timespec now, then = ns_to_timespec(delta);
> + struct timespec64 now, then = ns_to_timespec64(delta);
>
> spin_lock_irqsave(&igb->tmreg_lock, flags);
>
> igb_ptp_read_i210(igb, &now);
> - now = timespec_add(now, then);
> - igb_ptp_write_i210(igb, (const struct timespec *)&now);
> + now = timespec64_add(now, then);
> + igb_ptp_write_i210(igb, (const struct timespec64 *)&now);
>
> spin_unlock_irqrestore(&igb->tmreg_lock, flags);
>

This is one of the functions that would actually become more efficient if
the argument type gets changed to ktime_t.

Arnd
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/