diff options
-rw-r--r-- | sys/amd64/amd64/tsc.c | 2 | ||||
-rw-r--r-- | sys/conf/options.i386 | 1 | ||||
-rw-r--r-- | sys/i386/conf/NOTES | 5 | ||||
-rw-r--r-- | sys/i386/i386/tsc.c | 2 |
4 files changed, 8 insertions, 2 deletions
diff --git a/sys/amd64/amd64/tsc.c b/sys/amd64/amd64/tsc.c index e12a48d..abc6a93 100644 --- a/sys/amd64/amd64/tsc.c +++ b/sys/amd64/amd64/tsc.c @@ -77,7 +77,7 @@ init_TSC(void) if (bootverbose) printf("TSC clock: %ju Hz\n", (intmax_t)tsc_freq); -#if defined(SMP) +#if defined(SMP) && !defined(SMP_TSC) /* * We can not use the TSC in SMP mode, until we figure out a * cheap (impossible), reliable and precise (yeah right!) way diff --git a/sys/conf/options.i386 b/sys/conf/options.i386 index de784be..d60b57e 100644 --- a/sys/conf/options.i386 +++ b/sys/conf/options.i386 @@ -41,6 +41,7 @@ PAE opt_global.h CLK_CALIBRATION_LOOP opt_clock.h CLK_USE_I8254_CALIBRATION opt_clock.h CLK_USE_TSC_CALIBRATION opt_clock.h +SMP_TSC opt_clock.h TIMER_FREQ opt_clock.h NO_F00F_HACK opt_cpu.h diff --git a/sys/i386/conf/NOTES b/sys/i386/conf/NOTES index 46bebdd..6b0fb42 100644 --- a/sys/i386/conf/NOTES +++ b/sys/i386/conf/NOTES @@ -247,6 +247,11 @@ options CLK_CALIBRATION_LOOP options CLK_USE_I8254_CALIBRATION options CLK_USE_TSC_CALIBRATION +# One some SMP mainboards, the TSCs can be used in SMP mode due to +# them being synchronized. This can significantly reduce the context +# switch cost. +options SMP_TSC + ##################################################################### # MISCELLANEOUS DEVICES AND OPTIONS diff --git a/sys/i386/i386/tsc.c b/sys/i386/i386/tsc.c index e12a48d..abc6a93 100644 --- a/sys/i386/i386/tsc.c +++ b/sys/i386/i386/tsc.c @@ -77,7 +77,7 @@ init_TSC(void) if (bootverbose) printf("TSC clock: %ju Hz\n", (intmax_t)tsc_freq); -#if defined(SMP) +#if defined(SMP) && !defined(SMP_TSC) /* * We can not use the TSC in SMP mode, until we figure out a * cheap (impossible), reliable and precise (yeah right!) way |