[PATCH] Time: i386 Conversion - part 2: Rework TSC Support
As part of the i386 conversion to the generic timekeeping infrastructure, this introduces a new tsc.c file. The code in this file replaces the TSC initialization, management and access code currently in timer_tsc.c (which will be removed) that we want to preserve. The code also introduces the following functionality: o tsc_khz: like cpu_khz but stores the TSC frequency on systems that do not change TSC frequency w/ CPU frequency o check/mark_tsc_unstable: accessor/modifier flag for TSC timekeeping usability o minor cleanups to calibration math. This patch also includes a one line __cpuinitdata fix from Zwane Mwaikambo. Signed-off-by: John Stultz <johnstul@us.ibm.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
committed by
Linus Torvalds
parent
8d016ef138
commit
539eb11e6e
@@ -369,6 +369,11 @@ static void acpi_processor_idle(void)
|
||||
t2 = inl(acpi_fadt.xpm_tmr_blk.address);
|
||||
/* Get end time (ticks) */
|
||||
t2 = inl(acpi_fadt.xpm_tmr_blk.address);
|
||||
|
||||
#ifdef CONFIG_GENERIC_TIME
|
||||
/* TSC halts in C2, so notify users */
|
||||
mark_tsc_unstable();
|
||||
#endif
|
||||
/* Re-enable interrupts */
|
||||
local_irq_enable();
|
||||
set_thread_flag(TIF_POLLING_NRFLAG);
|
||||
@@ -409,6 +414,10 @@ static void acpi_processor_idle(void)
|
||||
ACPI_MTX_DO_NOT_LOCK);
|
||||
}
|
||||
|
||||
#ifdef CONFIG_GENERIC_TIME
|
||||
/* TSC halts in C3, so notify users */
|
||||
mark_tsc_unstable();
|
||||
#endif
|
||||
/* Re-enable interrupts */
|
||||
local_irq_enable();
|
||||
set_thread_flag(TIF_POLLING_NRFLAG);
|
||||
|
Reference in New Issue
Block a user