From nobody Sat Jun 13 17:06:24 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 4561D36EA9E; Wed, 6 May 2026 07:11:36 +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=1778051497; cv=none; b=o9p8oyl/weuFTNnsScWVcfb0PXPfcY5VX/4wg33bPYv1XuZP+x08BESBfx8x9S0PhJ/4ongvFbIJDt+OgkLc6vxba2gjWLU24Ur4KNL6o7yc/HzL83aIBBfKbewujCCNDboyoOvCvFoQnIPA+LdJubJS+t9bIEJfBjB6Mgz1C68= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778051497; c=relaxed/simple; bh=bIeLtSRKYMejGC4uPcPgqdTTy0EGH/9bW3ip2sXYdN0=; h=Date:From:To:Subject:Cc:In-Reply-To:References:MIME-Version: Message-ID:Content-Type; b=ulVoFSfUpFnn1Htdl2mloDdmYBj9LYx1MDnBdDgYpeTEDtviwzIIUtyQIZqeyGD7xFre+pyVjl5T17lRQp3sb+v9vuivYpdmCjv17iJQn/73+oVVEhuKti9+z3bQqglIyxvUHLDdg2/07hDktXiXacenyKmTQYL4dOYisBNqToQ= 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=O/zOybh1; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=apLIDYi5; 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="O/zOybh1"; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="apLIDYi5" Date: Wed, 06 May 2026 07:11:33 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1778051494; 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=7opUMeiUO9sXiw7qzONK3NRfZsyyET+utMaIxhkCud8=; b=O/zOybh1AK3cJHkomAWmzIEyonm3N12KlJiyLCdC4K6uv4rnUIP++LHipEZtnENIXJAehi su+9JhvVYU8HAcn7LnXO7Ao6X1VLK3OtQpNZ6W2mKAHVHCxF/z2P7e25juh48J95VHwLVz h+bGgF+sNeLFyObK16hwjosWoH23F5wpmDDuvPweUwsl9stB2cc0qx5kR9TWr0SRuYP8fG VQenr6+8rQ/Jl/W9RKlt5qZx0yt+oV9hnWyfOAHk4cFBuR8QUL5U2SNjMy51/TaqD8uuMm NEI/YWyTmhEmnEIxfLIkSjp7ooowVDwn6J3Nt9jGEVtzTO06IG5rp3Ip5HEv5g== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1778051494; 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=7opUMeiUO9sXiw7qzONK3NRfZsyyET+utMaIxhkCud8=; b=apLIDYi5pitgTEgJHW8qcO+KvZVTIwV26PwTCgR9QdiqyZLDuQYvN6iO/dtVoKyn/eLvoG Pf1Pt5vheJEh5YBA== 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] clocksource: Clean up clocksource_update_freq() functions Cc: thomas.weissschuh@linutronix.de, Thomas Gleixner , John Stultz , x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <20260504-clocksource-update_freq-v2-1-3e696fb01776@linutronix.de> References: <20260504-clocksource-update_freq-v2-1-3e696fb01776@linutronix.de> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-ID: <177805149339.424702.6710091735681293574.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: 33d4bfc49613301c8e451a597e377aaa331944bc Gitweb: https://git.kernel.org/tip/33d4bfc49613301c8e451a597e377aaa3= 31944bc Author: Thomas Wei=C3=9Fschuh AuthorDate: Mon, 04 May 2026 08:54:27 +02:00 Committer: Thomas Gleixner CommitterDate: Wed, 06 May 2026 08:33:08 +02:00 clocksource: Clean up clocksource_update_freq() functions Remove the unused functions __clocksource_update_freq_hz() and __clocksource_update_freq_khz(). Then make __clocksource_update_freq_scale() static as it is not used from external callers anymore. Also clean up the comment accordingly. Signed-off-by: Thomas Wei=C3=9Fschuh Signed-off-by: Thomas Gleixner Acked-by: John Stultz Link: https://patch.msgid.link/20260504-clocksource-update_freq-v2-1-3e696f= b01776@linutronix.de --- include/linux/clocksource.h | 12 ------------ kernel/time/clocksource.c | 9 +-------- 2 files changed, 1 insertion(+), 20 deletions(-) diff --git a/include/linux/clocksource.h b/include/linux/clocksource.h index 7c38190..c61aa45 100644 --- a/include/linux/clocksource.h +++ b/include/linux/clocksource.h @@ -236,8 +236,6 @@ clocks_calc_mult_shift(u32 *mult, u32 *shift, u32 from,= u32 to, u32 minsec); */ extern int __clocksource_register_scale(struct clocksource *cs, u32 scale, u32 freq); -extern void -__clocksource_update_freq_scale(struct clocksource *cs, u32 scale, u32 fre= q); =20 /* * Don't call this unless you are a default clocksource @@ -258,16 +256,6 @@ static inline int clocksource_register_khz(struct cloc= ksource *cs, u32 khz) return __clocksource_register_scale(cs, 1000, khz); } =20 -static inline void __clocksource_update_freq_hz(struct clocksource *cs, u3= 2 hz) -{ - __clocksource_update_freq_scale(cs, 1, hz); -} - -static inline void __clocksource_update_freq_khz(struct clocksource *cs, u= 32 khz) -{ - __clocksource_update_freq_scale(cs, 1000, khz); -} - #ifdef CONFIG_ARCH_CLOCKSOURCE_INIT extern void clocksource_arch_init(struct clocksource *cs); #else diff --git a/kernel/time/clocksource.c b/kernel/time/clocksource.c index baee13a..f8d15ed 100644 --- a/kernel/time/clocksource.c +++ b/kernel/time/clocksource.c @@ -1222,14 +1222,8 @@ static void clocksource_enqueue(struct clocksource *= cs) * @cs: clocksource to be registered * @scale: Scale factor multiplied against freq to get clocksource hz * @freq: clocksource frequency (cycles per second) divided by scale - * - * This should only be called from the clocksource->enable() method. - * - * This *SHOULD NOT* be called directly! Please use the - * __clocksource_update_freq_hz() or __clocksource_update_freq_khz() helper - * functions. */ -void __clocksource_update_freq_scale(struct clocksource *cs, u32 scale, u3= 2 freq) +static void __clocksource_update_freq_scale(struct clocksource *cs, u32 sc= ale, u32 freq) { u64 sec; =20 @@ -1287,7 +1281,6 @@ void __clocksource_update_freq_scale(struct clocksour= ce *cs, u32 scale, u32 freq pr_info("%s: mask: 0x%llx max_cycles: 0x%llx, max_idle_ns: %lld ns\n", cs->name, cs->mask, cs->max_cycles, cs->max_idle_ns); } -EXPORT_SYMBOL_GPL(__clocksource_update_freq_scale); =20 /** * __clocksource_register_scale - Used to install new clocksources