With new interface timecounter_reset we can update the start time for timecounter. Update cpts_ptp_settime with this new function.
Signed-off-by: Sagar Arun Kamble <sagar.a.kam...@intel.com> Cc: "David S. Miller" <da...@davemloft.net> Cc: Grygorii Strashko <grygorii.stras...@ti.com> Cc: Bhumika Goyal <bhumi...@gmail.com> Cc: Richard Cochran <richardcoch...@gmail.com> Cc: Thomas Gleixner <t...@linutronix.de> Cc: netdev@vger.kernel.org Cc: linux-ker...@vger.kernel.org --- drivers/net/ethernet/ti/cpts.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/ti/cpts.c b/drivers/net/ethernet/ti/cpts.c index e6afc94..41bac4d 100644 --- a/drivers/net/ethernet/ti/cpts.c +++ b/drivers/net/ethernet/ti/cpts.c @@ -268,7 +268,7 @@ static int cpts_ptp_settime(struct ptp_clock_info *ptp, ns = timespec64_to_ns(ts); spin_lock_irqsave(&cpts->lock, flags); - timecounter_init(&cpts->tc, ns); + timecounter_reset(&cpts->tc, ns); spin_unlock_irqrestore(&cpts->lock, flags); return 0; -- 1.9.1