diff options
author | Valentin Schneider <vschneid@redhat.com> | 2024-03-13 19:01:06 +0100 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2024-03-22 11:18:20 +0100 |
commit | 79a4567b2e8ae4d0282602a24f76f5e2382f5b98 (patch) | |
tree | 4f942cdbaf474b6afdc754f94d33a6e98d8df295 | |
parent | ddd8afacc4f65a01204d7a36b8fd96c908e9b72c (diff) | |
download | lwn-79a4567b2e8ae4d0282602a24f76f5e2382f5b98.tar.gz lwn-79a4567b2e8ae4d0282602a24f76f5e2382f5b98.zip |
x86/tsc: Make __use_tsc __ro_after_init
__use_tsc is only ever enabled in __init tsc_enable_sched_clock(), so mark
it as __ro_after_init.
Signed-off-by: Valentin Schneider <vschneid@redhat.com>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Acked-by: Josh Poimboeuf <jpoimboe@kernel.org>
Link: https://lore.kernel.org/r/20240313180106.2917308-5-vschneid@redhat.com
-rw-r--r-- | arch/x86/kernel/tsc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/kernel/tsc.c b/arch/x86/kernel/tsc.c index 5a69a49acc96..0f7624ed1d1d 100644 --- a/arch/x86/kernel/tsc.c +++ b/arch/x86/kernel/tsc.c @@ -44,7 +44,7 @@ EXPORT_SYMBOL(tsc_khz); static int __read_mostly tsc_unstable; static unsigned int __initdata tsc_early_khz; -static DEFINE_STATIC_KEY_FALSE(__use_tsc); +static DEFINE_STATIC_KEY_FALSE_RO(__use_tsc); int tsc_clocksource_reliable; |