From mboxrd@z Thu Jan 1 00:00:00 1970 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 3C60E2DD5E2; Tue, 7 Jul 2026 22:00:30 +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=1783461631; cv=none; b=DseXkr5w2aF6FblO7s9lf5l53H5+vCGLHQCKFe8PbNytQhnpZd1/zEueWJq29X92j5vHIZPx3WCaAii6Bh/Nhbg3qBiSwLUI7nEzEEm+yY4afmWBsw5JR9X1o2jnSnvjIvdgTUS/VPAwAFeqz8Y0ZLHvfZyG9Q6AlsjHWcN4B/I= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1783461631; c=relaxed/simple; bh=ZZLXLOGOI2sqzyvbKQ6Cd87hTwC94bIrpSu8CscG9rg=; h=Date:From:To:Subject:Cc:In-Reply-To:References:MIME-Version: Message-ID:Content-Type; b=KsLipFhn9bI7D608TLds15ZLphgzoFK6cS2F5GIS/3960yEXN+vLpO5ouVQ4T0B9VgsvwriPAO0wDRe75dceTXNzmSiFi4Px5mFJsvqOP9zeo9I8HtAhLjP8+h0biWZ77uZGU3uD5P1oSc3ZXFgpnVK2XGubGGy98nNT2rpTuLA= 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=sIOxyl4d; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=c4DfAmQs; 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="sIOxyl4d"; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="c4DfAmQs" Date: Tue, 07 Jul 2026 22:00:24 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1783461628; 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=c/GPWVsDLkDJeYOygBUMnpHWS+Yf5hFEoU3LIeThpCk=; b=sIOxyl4dcWqycyO3OCqEh3jxwzeiN1p2a6T4ICcNKA0A0rl6o8Mg0bz64xWR3tEK+aU6AA QwvJyW++spBZkVx7TbiuCgDWffu4e0pM8SAKri7de9bIwBw8gmleZCB+ORQyv8iKNUgDVD nSF+en74is9LxeYfbzuncJFcW7lm7XVdGQ4SlddcbDYDuPS20p9yQ78j5fokuQ3/gGtkzJ yFn8dir7isRnMkdbcihiGK38K8eD+339YdN8HCJ0sZxxLR0mJLj1WuSmf0Pgz9aw9mB+bp 6x+0HK5LxCBVaf8OrHvCbqQTR6jJ4R0OTQhMtZwq30s3TPAMLXkqE1/Fec39Iw== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1783461628; 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=c/GPWVsDLkDJeYOygBUMnpHWS+Yf5hFEoU3LIeThpCk=; b=c4DfAmQsAeitVfm/Ow+i1G3xkwWAGgFXChuObm70iOsNG+gMXOUBnaGKWjv53e8Pw/ASMm duMDjBRWIkxpURAg== From: tip-bot2 for Thomas =?utf-8?q?Wei=C3=9Fschuh?= Sender: tip-bot2@linutronix.de Reply-to: linux-kernel@vger.kernel.org To: linux-tip-commits@vger.kernel.org Subject: [tip: timers/core] y2038: uapi: Use 64-bit __kernel_old_timespec::tv_nsec on x32 Cc: thomas.weissschuh@linutronix.de, Thomas Gleixner , x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <20260504-timespec-x32-v2-1-0739c9047fc4@linutronix.de> References: <20260504-timespec-x32-v2-1-0739c9047fc4@linutronix.de> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-ID: <178346162473.744054.2015404896798956792.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/core branch of tip: Commit-ID: 79ced850e549e8c86b772a79ea417a1425b5c04b Gitweb: https://git.kernel.org/tip/79ced850e549e8c86b772a79ea417a1425b= 5c04b Author: Thomas Wei=C3=9Fschuh AuthorDate: Mon, 04 May 2026 08:32:26 +02:00 Committer: Thomas Gleixner CommitterDate: Tue, 07 Jul 2026 23:59:24 +02:00 y2038: uapi: Use 64-bit __kernel_old_timespec::tv_nsec on x32 'struct __kernel_old_timespec' represents the 'native' time ABI of the kernel. On 32-bit systems it uses 32-bit fields and on 64-bit systems it uses 64-bit fields. However the x86 x32 ABI uses the 64-bit time ABI natively. This is correctly handled for the 'tv_sec' fields, through the typedefs of '__kernel_old_time_t' -> '__kernel_long_t' -> 'long long'. The same treatment was missed for 'tv_nsec'. In practice this might not make much of a difference as the value of 'tv_nsec' will always fit into 32 bits and the missing bits fall into the padding of the structure. When introspecting the structure however, a difference can be observed. Switch to 64-bit tv_nsec on x32. No other architectures or ABIs are affected. While this could be interpreted as violating the POSIX requirement of 'timespec::tv_nsec' being 'long': * __kernel_old_timespec is not actually the POSIX timespec type * the requirement is gone in newer versions of POSIX * this matches glibc Fixes: 94c467ddb273 ("y2038: add __kernel_old_timespec and __kernel_old_time_= t") Signed-off-by: Thomas Wei=C3=9Fschuh Signed-off-by: Thomas Gleixner Link: https://patch.msgid.link/20260504-timespec-x32-v2-1-0739c9047fc4@linutr= onix.de --- include/uapi/linux/time_types.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/uapi/linux/time_types.h b/include/uapi/linux/time_types.h index bcc0002..03a0d8a 100644 --- a/include/uapi/linux/time_types.h +++ b/include/uapi/linux/time_types.h @@ -30,7 +30,7 @@ struct __kernel_old_timeval { =20 struct __kernel_old_timespec { __kernel_old_time_t tv_sec; /* seconds */ - long tv_nsec; /* nanoseconds */ + __kernel_long_t tv_nsec; /* nanoseconds */ }; =20 struct __kernel_old_itimerval {