1
0
mirror of https://xff.cz/git/u-boot/ synced 2025-09-03 09:42:22 +02:00

x86: tsc: Rename X86_TSC_TIMER_EARLY_FREQ to X86_TSC_TIMER_FREQ

Currently there are two places to specify the x86 TSC timer frequency
with one in Kconfig used for early timer and the other one in device
tree used when the frequency cannot be determined from hardware.

This may potentially create an inconsistent config where the 2 values
do not match. Let's use the one specified in Kconfig in the device
tree as well.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
Bin Meng
2021-07-28 12:00:22 +08:00
parent ffaa7abfc5
commit 5824bc6d6f
4 changed files with 10 additions and 9 deletions

View File

@@ -425,12 +425,13 @@ static void tsc_timer_ensure_setup(bool early)
goto done;
if (early)
fast_calibrate = CONFIG_X86_TSC_TIMER_EARLY_FREQ;
gd->arch.clock_rate = CONFIG_X86_TSC_TIMER_FREQ;
else
return;
done:
gd->arch.clock_rate = fast_calibrate * 1000000;
if (!gd->arch.clock_rate)
gd->arch.clock_rate = fast_calibrate * 1000000;
}
gd->arch.tsc_inited = true;
}