[PATCH 24/27] net/mlx5: Use timecounter_reset interface

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



With new interface timecounter_reset we can update the start time for
timecounter. Update mlx5_ptp_settime with this new function.

Signed-off-by: Sagar Arun Kamble <sagar.a.kamble@xxxxxxxxx>
Cc: Richard Cochran <richardcochran@xxxxxxxxx>
Cc: Saeed Mahameed <saeedm@xxxxxxxxxxxx>
Cc: Matan Barak <matanb@xxxxxxxxxxxx>
Cc: Leon Romanovsky <leonro@xxxxxxxxxxxx>
Cc: Eugenia Emantayev <eugenia@xxxxxxxxxxxx>
Cc: Eitan Rabin <rabin@xxxxxxxxxxxx>
Cc: Feras Daoud <ferasda@xxxxxxxxxxxx>
Cc: Tariq Toukan <tariqt@xxxxxxxxxxxx>
Cc: Thomas Gleixner <tglx@xxxxxxxxxxxxx>
Cc: netdev@xxxxxxxxxxxxxxx
Cc: linux-rdma@xxxxxxxxxxxxxxx
Cc: linux-kernel@xxxxxxxxxxxxxxx
---
 drivers/net/ethernet/mellanox/mlx5/core/lib/clock.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/ethernet/mellanox/mlx5/core/lib/clock.c b/drivers/net/ethernet/mellanox/mlx5/core/lib/clock.c
index 071f78a..e490522 100644
--- a/drivers/net/ethernet/mellanox/mlx5/core/lib/clock.c
+++ b/drivers/net/ethernet/mellanox/mlx5/core/lib/clock.c
@@ -122,7 +122,7 @@ static int mlx5_ptp_settime(struct ptp_clock_info *ptp,
 	unsigned long flags;
 
 	write_lock_irqsave(&clock->lock, flags);
-	timecounter_init(&clock->tc, ns);
+	timecounter_reset(&clock->tc, ns);
 	write_unlock_irqrestore(&clock->lock, flags);
 
 	return 0;
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux