From nobody Sun Feb 8 14:59:37 2026 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id B5A41C7EE32 for ; Mon, 5 Jun 2023 15:09:13 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234644AbjFEPJA (ORCPT ); Mon, 5 Jun 2023 11:09:00 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47912 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233932AbjFEPIa (ORCPT ); Mon, 5 Jun 2023 11:08:30 -0400 Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8798FF2; Mon, 5 Jun 2023 08:08:29 -0700 (PDT) Date: Mon, 05 Jun 2023 15:08:27 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1685977708; 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=RoWJhGlkrPutICGc7rmHeduSzyk5VXIUCCAZUGIdmZA=; b=yrqU0qkFFGzc4V6akX08luOHlQqbf/KLaqDtUCSA27p+ZZsRXsjedaFxvz+4kNQnzxdEd9 yJ/0acy+CIvXIjwnNMi9mAZdU5bN5fB7ZqPj9Bs0518QOIl5ycJ9m/lNComD1SPM2Bms76 F2OHZrR7K+PsihaeP1jWkSMYuox1JtbkEP638Il5Lm4z6TvEOVeRo6GT/kdWa0mqCciH/W eXnTGc3XfxIVBJmSqPZrd08v8+DRQeVN9+k7yvAUFXoG4Mc8Cu+XJTphJ6VhA5sTYlrl53 lvJvl8OOjkjTbVLL58sxeNORL+6282WO1XzGmrR1Soh47OEkICvu6NRDEDCJJQ== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1685977708; 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=RoWJhGlkrPutICGc7rmHeduSzyk5VXIUCCAZUGIdmZA=; b=B/QUh7fArb2UmWGkSRWf/MhK1jd8fQpPDmOeNe1kLHyHUBefnTU4l96crT16VgrhHBZjki 0f6NzRxpzYqBTiAQ== 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/core] posix-timers: Document nanosleep() details Cc: Thomas Gleixner , Frederic Weisbecker , x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <20230425183313.567072835@linutronix.de> References: <20230425183313.567072835@linutronix.de> MIME-Version: 1.0 Message-ID: <168597770779.404.11242027713171629061.tip-bot2@tip-bot2> Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The following commit has been merged into the timers/core branch of tip: Commit-ID: 13da885685d6ae339f2924d3c8a1f4fe16a904cc Gitweb: https://git.kernel.org/tip/13da885685d6ae339f2924d3c8a1f4fe1= 6a904cc Author: Thomas Gleixner AuthorDate: Tue, 25 Apr 2023 20:49:17 +02:00 Committer: Thomas Gleixner CommitterDate: Mon, 05 Jun 2023 17:03:38 +02:00 posix-timers: Document nanosleep() details The descriptions for common_nsleep() is wrong and common_nsleep_timens() lacks any form of comment. Signed-off-by: Thomas Gleixner Reviewed-by: Frederic Weisbecker Link: https://lore.kernel.org/r/20230425183313.567072835@linutronix.de --- kernel/time/posix-timers.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/kernel/time/posix-timers.c b/kernel/time/posix-timers.c index 9d99d4b..9ce13c9 100644 --- a/kernel/time/posix-timers.c +++ b/kernel/time/posix-timers.c @@ -1370,7 +1370,7 @@ SYSCALL_DEFINE2(clock_getres_time32, clockid_t, which= _clock, #endif =20 /* - * nanosleep for monotonic and realtime clocks + * sys_clock_nanosleep() for CLOCK_REALTIME and CLOCK_TAI */ static int common_nsleep(const clockid_t which_clock, int flags, const struct timespec64 *rqtp) @@ -1382,8 +1382,13 @@ static int common_nsleep(const clockid_t which_clock= , int flags, which_clock); } =20 +/* + * sys_clock_nanosleep() for CLOCK_MONOTONIC and CLOCK_BOOTTIME + * + * Absolute nanosleeps for these clocks are time-namespace adjusted. + */ static int common_nsleep_timens(const clockid_t which_clock, int flags, - const struct timespec64 *rqtp) + const struct timespec64 *rqtp) { ktime_t texp =3D timespec64_to_ktime(*rqtp);