mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Arnd Bergmann <arnd@kernel.org>
To: "Thomas Gleixner" <tglx@linutronix.de>,
	"Thomas Weißschuh" <thomas.weissschuh@linutronix.de>,
	"David S. Miller" <davem@davemloft.net>,
	"Andreas Larsson" <andreas@gaisler.com>,
	"John Stultz" <jstultz@google.com>
Cc: Andy Lutomirski <luto@kernel.org>,
	Vincenzo Frascino <vincenzo.frascino@arm.com>,
	shuah <shuah@kernel.org>,
	Anna-Maria Behnsen <anna-maria@linutronix.de>,
	Frederic Weisbecker <frederic@kernel.org>,
	Stephen Boyd <sboyd@kernel.org>,
	Catalin Marinas <catalin.marinas@arm.com>,
	Will Deacon <will@kernel.org>, Arnd Bergmann <arnd@arndb.de>,
	Eric Biggers <ebiggers@google.com>,
	sparclinux@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [PATCH 2/2] clocksource: remove ARCH_CLOCKSOURCE_DATA
Date: Mon,  7 Jul 2025 16:46:38 +0200	[thread overview]
Message-ID: <20250707144726.4008707-2-arnd@kernel.org> (raw)
In-Reply-To: <20250707144726.4008707-1-arnd@kernel.org>

From: Arnd Bergmann <arnd@arndb.de>

Without the sparc64 vdso, there are no remaining users
of ARCH_CLOCKSOURCE_DATA, and it can just be removed.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 arch/sparc/Kconfig                   |  1 -
 arch/sparc/include/asm/clocksource.h | 17 -----------------
 arch/sparc/kernel/time_64.c          |  3 ---
 include/linux/clocksource.h          |  6 +-----
 kernel/time/Kconfig                  |  4 ----
 5 files changed, 1 insertion(+), 30 deletions(-)
 delete mode 100644 arch/sparc/include/asm/clocksource.h

diff --git a/arch/sparc/Kconfig b/arch/sparc/Kconfig
index 776ce79ef188..b126a421db9c 100644
--- a/arch/sparc/Kconfig
+++ b/arch/sparc/Kconfig
@@ -101,7 +101,6 @@ config SPARC64
 	select HAVE_REGS_AND_STACK_ACCESS_API
 	select ARCH_USE_QUEUED_RWLOCKS
 	select ARCH_USE_QUEUED_SPINLOCKS
-	select ARCH_CLOCKSOURCE_DATA
 	select ARCH_HAS_PTE_SPECIAL
 	select PCI_DOMAINS if PCI
 	select ARCH_HAS_GIGANTIC_PAGE
diff --git a/arch/sparc/include/asm/clocksource.h b/arch/sparc/include/asm/clocksource.h
deleted file mode 100644
index d63ef224befe..000000000000
--- a/arch/sparc/include/asm/clocksource.h
+++ /dev/null
@@ -1,17 +0,0 @@
-/*
- * Copyright (c) 2017 Oracle and/or its affiliates. All rights reserved.
- */
-
-#ifndef _ASM_SPARC_CLOCKSOURCE_H
-#define _ASM_SPARC_CLOCKSOURCE_H
-
-/* VDSO clocksources */
-#define VCLOCK_NONE   0  /* Nothing userspace can do. */
-#define VCLOCK_TICK   1  /* Use %tick.  */
-#define VCLOCK_STICK  2  /* Use %stick. */
-
-struct arch_clocksource_data {
-	int vclock_mode;
-};
-
-#endif /* _ASM_SPARC_CLOCKSOURCE_H */
diff --git a/arch/sparc/kernel/time_64.c b/arch/sparc/kernel/time_64.c
index 422ec5d03160..547c6f8bef36 100644
--- a/arch/sparc/kernel/time_64.c
+++ b/arch/sparc/kernel/time_64.c
@@ -838,14 +838,11 @@ void __init time_init_early(void)
 	if (tlb_type == spitfire) {
 		if (is_hummingbird()) {
 			init_tick_ops(&hbtick_operations);
-			clocksource_tick.archdata.vclock_mode = VCLOCK_NONE;
 		} else {
 			init_tick_ops(&tick_operations);
-			clocksource_tick.archdata.vclock_mode = VCLOCK_TICK;
 		}
 	} else {
 		init_tick_ops(&stick_operations);
-		clocksource_tick.archdata.vclock_mode = VCLOCK_STICK;
 	}
 }
 
diff --git a/include/linux/clocksource.h b/include/linux/clocksource.h
index 65b7c41471c3..12d853b18832 100644
--- a/include/linux/clocksource.h
+++ b/include/linux/clocksource.h
@@ -25,8 +25,7 @@ struct clocksource_base;
 struct clocksource;
 struct module;
 
-#if defined(CONFIG_ARCH_CLOCKSOURCE_DATA) || \
-    defined(CONFIG_GENERIC_GETTIMEOFDAY)
+#if defined(CONFIG_GENERIC_GETTIMEOFDAY)
 #include <asm/clocksource.h>
 #endif
 
@@ -106,9 +105,6 @@ struct clocksource {
 	u64			max_idle_ns;
 	u32			maxadj;
 	u32			uncertainty_margin;
-#ifdef CONFIG_ARCH_CLOCKSOURCE_DATA
-	struct arch_clocksource_data archdata;
-#endif
 	u64			max_cycles;
 	u64			max_raw_delta;
 	const char		*name;
diff --git a/kernel/time/Kconfig b/kernel/time/Kconfig
index b0b97a60aaa6..d7e67d397c86 100644
--- a/kernel/time/Kconfig
+++ b/kernel/time/Kconfig
@@ -9,10 +9,6 @@
 config CLOCKSOURCE_WATCHDOG
 	bool
 
-# Architecture has extra clocksource data
-config ARCH_CLOCKSOURCE_DATA
-	bool
-
 # Architecture has extra clocksource init called from registration
 config ARCH_CLOCKSOURCE_INIT
 	bool
-- 
2.39.5


  reply	other threads:[~2025-07-07 14:48 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-07-07 14:46 [PATCH 1/2] vdso: sparc: stub out custom vdso implementation Arnd Bergmann
2025-07-07 14:46 ` Arnd Bergmann [this message]
2025-07-07 17:31   ` [PATCH 2/2] clocksource: remove ARCH_CLOCKSOURCE_DATA John Stultz
2025-07-07 15:22 ` [PATCH 1/2] vdso: sparc: stub out custom vdso implementation John Paul Adrian Glaubitz
2025-07-07 15:45   ` Arnd Bergmann
2025-07-07 16:05     ` John Paul Adrian Glaubitz
2025-07-10 16:22       ` Andreas Larsson
2025-07-11 10:31         ` Arnd Bergmann
2025-07-14  8:40           ` John Paul Adrian Glaubitz
2025-07-21 21:12           ` Thomas Gleixner
2025-07-08  5:39 ` Thomas Weißschuh
2025-07-08  6:40   ` Arnd Bergmann
2025-07-08  7:13     ` Thomas Weißschuh
2025-07-23 10:57 ` Thomas Weißschuh
2025-07-23 11:10   ` John Paul Adrian Glaubitz
2025-07-23 17:24   ` Thomas Gleixner

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250707144726.4008707-2-arnd@kernel.org \
    --to=arnd@kernel.org \
    --cc=andreas@gaisler.com \
    --cc=anna-maria@linutronix.de \
    --cc=arnd@arndb.de \
    --cc=catalin.marinas@arm.com \
    --cc=davem@davemloft.net \
    --cc=ebiggers@google.com \
    --cc=frederic@kernel.org \
    --cc=jstultz@google.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=luto@kernel.org \
    --cc=sboyd@kernel.org \
    --cc=shuah@kernel.org \
    --cc=sparclinux@vger.kernel.org \
    --cc=tglx@linutronix.de \
    --cc=thomas.weissschuh@linutronix.de \
    --cc=vincenzo.frascino@arm.com \
    --cc=will@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®