Skip to content

Commit 8309f86

Browse files
Peter ZijlstraIngo Molnar
authored andcommitted
x86/tsc: Provide 'tsc=unstable' boot parameter
Since the clocksource watchdog will only detect broken TSC after the fact, all TSC based clocks will likely have observed non-continuous values before/when switching away from TSC. Therefore only thing to fully avoid random clock movement when your BIOS randomly mucks with TSC values from SMI handlers is reporting the TSC as unstable at boot. Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-kernel@vger.kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org>
1 parent 625ed2b commit 8309f86

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

arch/x86/kernel/tsc.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -374,6 +374,8 @@ static int __init tsc_setup(char *str)
374374
tsc_clocksource_reliable = 1;
375375
if (!strncmp(str, "noirqtime", 9))
376376
no_sched_irq_time = 1;
377+
if (!strcmp(str, "unstable"))
378+
mark_tsc_unstable("boot parameter");
377379
return 1;
378380
}
379381

0 commit comments

Comments
 (0)