]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
igc: move ktime snapshot into PTM retry loop
authorChristopher S M Hall <christopher.s.hall@intel.com>
Tue, 1 Apr 2025 23:35:31 +0000 (16:35 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 2 May 2025 05:44:10 +0000 (07:44 +0200)
commit5572511776d405923913138d5ab0dce39e7bc5a2
tree20700d09a726712cd2a998a84826168e06e3e8cc
parentc1f174edaccc5a00f8e218c42a0aa9156efd5f76
igc: move ktime snapshot into PTM retry loop

[ Upstream commit cd7f7328d691937102732f39f97ead35b15bf803 ]

Move ktime_get_snapshot() into the loop. If a retry does occur, a more
recent snapshot will result in a more accurate cross-timestamp.

Fixes: a90ec8483732 ("igc: Add support for PTP getcrosststamp()")
Reviewed-by: Michal Swiatkowski <michal.swiatkowski@linux.intel.com>
Tested-by: Mor Bar-Gabay <morx.bar.gabay@intel.com>
Tested-by: Avigail Dahan <avigailx.dahan@intel.com>
Signed-off-by: Christopher S M Hall <christopher.s.hall@intel.com>
Reviewed-by: Corinna Vinschen <vinschen@redhat.com>
Signed-off-by: Jacob Keller <jacob.e.keller@intel.com>
Acked-by: Vinicius Costa Gomes <vinicius.gomes@intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/ethernet/intel/igc/igc_ptp.c