From nobody Mon Jun 8 03:20:27 2026 Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 02B7A3D566E; Tue, 2 Jun 2026 09:46:19 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=193.142.43.55 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1780393581; cv=none; b=qCTMmvxg7iPYp30R8/cIpO4JrAVUQ2Dd1nUaOc28Lm9zlDUsV6ApNi7gKKuf0RhB8DHU228GC8EkKhqU5PJDIByIKy0YaITk5wt4JJ+9TwOU9HY4y3Y2UFkxq+9GTQLyuzEurV9Q5sKouyp898WBTAtrHN6JntY615M8ES/SvKg= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1780393581; c=relaxed/simple; bh=I0bRa1nvax1qmpxtKROvsWgIktQ3zACLFanclpwGpQM=; h=Date:From:To:Subject:Cc:In-Reply-To:References:MIME-Version: Message-ID:Content-Type; b=MskTnJhvZye6VZ6eebkBnZo/SVHaxNoEqP5x16u/NuQ+k3MzMAntNSqZ6gdks+zyBNob2L3Wq2KH3zXzyd2Jb5MJg1JdKg/ydw7qHVZxLI7cBgh05bEqJS5nWAwP23uLO39kgsNcDYsk76OoAjWQi6UUVugQK2iVNk3brbLUZII= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linutronix.de; spf=pass smtp.mailfrom=linutronix.de; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=f72TZ6ej; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=8ycQwEGu; arc=none smtp.client-ip=193.142.43.55 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linutronix.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linutronix.de Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="f72TZ6ej"; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="8ycQwEGu" Date: Tue, 02 Jun 2026 09:46:17 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1780393578; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=UP/jCs/4Ul+A02Og0qce2OmnJ/Afq0HYXR90bhx5o+4=; b=f72TZ6ejZOh1nOGJJU6wfOujL8NutQ0ADW9Hd1DwMIxg0z4GsE7HmdPafI3QLpyyYdP/om 7loUl95yc3wRzdfQUnHfdyGZX9ZC7fGT9BVK9vjLRXA+xkJZ5Yavrblos9Gvh/KjWhfElJ 50E1V0GYuWLYred29wYz1UG2Ndl4Y9LHoLC+BRNeKFTOIQy3gXH8T0mj94rXeNiDRmFA0k 9AHOfyiCTt67y+Y96+bXlsJKstkbvx8DeWwyLTPZXZE4hvNRvBwDCzXakosK8bw7mVsrof 9e3ygthFoCQ1EWk2t8uSb0zSFunfxGmuUCpftA3zNzi0zZMTRtS7ciUFrpN6GA== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1780393578; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=UP/jCs/4Ul+A02Og0qce2OmnJ/Afq0HYXR90bhx5o+4=; b=8ycQwEGuK/ZRoeubEVdFp4+sKNX2Uc/ka2hpX0vgislxegD91Br93WQqIW3nJija2W77hY TnxbWgqFbNvH6CAA== From: "tip-bot2 for Thomas Gleixner" Sender: tip-bot2@linutronix.de Reply-to: linux-kernel@vger.kernel.org To: linux-tip-commits@vger.kernel.org Subject: [tip: timers/ptp] timekeeping: Use system_time_snapshot::systime/monoraw instead of ::real/raw Cc: Thomas Gleixner , David Woodhouse , Arthur Kiyanovski , thomas.weissschuh@linutronix.de, Jacob Keller , x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <20260529195557.024415766@kernel.org> References: <20260529195557.024415766@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-ID: <178039357716.2140988.11675863131952508424.tip-bot2@tip-bot2> Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails Precedence: bulk Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable The following commit has been merged into the timers/ptp branch of tip: Commit-ID: ef22786707e3967b539c3b1e6b5c7ea8b408430f Gitweb: https://git.kernel.org/tip/ef22786707e3967b539c3b1e6b5c7ea8b= 408430f Author: Thomas Gleixner AuthorDate: Fri, 29 May 2026 21:59:55 +02:00 Committer: Thomas Gleixner CommitterDate: Tue, 02 Jun 2026 11:39:57 +02:00 timekeeping: Use system_time_snapshot::systime/monoraw instead of ::real/raw system_time_snapshot::systime provides the same information as system_time_snapshot::real when the snapshot was taken with ktime_get_snapshot_id(CLOCK_REALTIME). Convert the history interpolation over to use 'systime' and 'monoraw' as 'real/raw' are going away once all users are converted. As a side effect this is the first step to support CLOCK_AUX with get_device_crosstime_stamp() and the history interpolation. Signed-off-by: Thomas Gleixner Tested-by: David Woodhouse Tested-by: Arthur Kiyanovski Reviewed-by: David Woodhouse Reviewed-by: Thomas Wei=C3=9Fschuh Reviewed-by: Jacob Keller Link: https://patch.msgid.link/20260529195557.024415766@kernel.org --- kernel/time/timekeeping.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/kernel/time/timekeeping.c b/kernel/time/timekeeping.c index 0053dc0..ccd04ad 100644 --- a/kernel/time/timekeeping.c +++ b/kernel/time/timekeeping.c @@ -1323,7 +1323,7 @@ static int adjust_historical_crosststamp(struct syste= m_time_snapshot *history, * partial_history_cycles / total_history_cycles */ corr_raw =3D (u64)ktime_to_ns( - ktime_sub(ts->sys_monoraw, history->raw)); + ktime_sub(ts->sys_monoraw, history->monoraw)); ret =3D scale64_check_overflow(partial_history_cycles, total_history_cycles, &corr_raw); if (ret) @@ -1341,7 +1341,7 @@ static int adjust_historical_crosststamp(struct syste= m_time_snapshot *history, (corr_raw, tk->tkr_mono.mult, tk->tkr_raw.mult); } else { corr_real =3D (u64)ktime_to_ns( - ktime_sub(ts->sys_realtime, history->real)); + ktime_sub(ts->sys_realtime, history->systime)); ret =3D scale64_check_overflow(partial_history_cycles, total_history_cycles, &corr_real); if (ret) @@ -1350,8 +1350,8 @@ static int adjust_historical_crosststamp(struct syste= m_time_snapshot *history, =20 /* Fixup monotonic raw and real time time values */ if (interp_forward) { - ts->sys_monoraw =3D ktime_add_ns(history->raw, corr_raw); - ts->sys_realtime =3D ktime_add_ns(history->real, corr_real); + ts->sys_monoraw =3D ktime_add_ns(history->monoraw, corr_raw); + ts->sys_realtime =3D ktime_add_ns(history->systime, corr_real); } else { ts->sys_monoraw =3D ktime_sub_ns(ts->sys_monoraw, corr_raw); ts->sys_realtime =3D ktime_sub_ns(ts->sys_realtime, corr_real);