Commit f8c8bd159a9b for kernel

commit f8c8bd159a9bf626dd4921b7746ff481fce8c758
Author: Vadim Fedorenko <vadim.fedorenko@linux.dev>
Date:   Wed Oct 7 20:33:59 2026 +0000

    ptp: ocp: fix PCIe delay estimation calculation

    The commit in fixes introduced a high cap for delayas U64_MAX value
    while ktime_t is actually s64. This is wrong cap as it becomes negative
    value and any comparison to a real delay will fail to update delay
    value. Use KTIME_MAX constant as correct max cap for PCIe delay.

    The issue was hit in production (a negative value is observed):

      # cat /sys/class/timecard/ocp0/ts_window_adjust
      -3

    Fixes: aa05fe67bcd64 ("ptp: ocp: Improve PCIe delay estimation")
    Signed-off-by: Vadim Fedorenko <vadim.fedorenko@linux.dev>
    Reviewed-by: Daniel Machon <daniel.machon@microchip.com>
    Link: https://patch.msgid.link/20261007203359.417270-1-vadim.fedorenko@linux.dev
    Signed-off-by: Jakub Kicinski <kuba@kernel.org>

diff --git a/drivers/ptp/ptp_ocp.c b/drivers/ptp/ptp_ocp.c
index 3d26ec1f7b9e..a8cba2f64b98 100644
--- a/drivers/ptp/ptp_ocp.c
+++ b/drivers/ptp/ptp_ocp.c
@@ -1825,7 +1825,7 @@ ptp_ocp_watchdog(struct timer_list *t)
 static void
 ptp_ocp_estimate_pci_timing(struct ptp_ocp *bp)
 {
-	ktime_t start, end, delay = U64_MAX;
+	ktime_t start, end, delay = KTIME_MAX;
 	u32 ctrl;
 	int i;