audk/PcAtChipsetPkg/Library/AcpiTimerLib
Star Zeng a012df5ec6 PcAtChipsetPkg AcpiTimerLib: Wait 363 ACPI timer counts to get TSC Freq
Compute the number of ticks to wait to measure TSC frequency.
Instead of (ACPI_TIMER_FREQUENCY / 10000) = 357 and 357 * 10000 = 3570000,
use 363 * 9861 = 3579543 Hz which is within 2 Hz of ACPI_TIMER_FREQUENCY.
363 counts is a calibration time of 101.4 uS.

The idea comes from Michael and Paolo.

Cc: Michael D Kinney <michael.d.kinney@intel.com>
Cc: Liming Gao <liming.gao@intel.com>
Cc: Paolo Bonzini <pbonzini@redhat.com>
Cc: Paul A Lohr <paul.a.lohr@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Star Zeng <star.zeng@intel.com>
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Michael D Kinney <michael.d.kinney@intel.com>
2016-08-18 11:01:54 +08:00
..
AcpiTimerLib.c PcAtChipsetPkg AcpiTimerLib: Wait 363 ACPI timer counts to get TSC Freq 2016-08-18 11:01:54 +08:00
BaseAcpiTimerLib.c PcAtChipsetPkg AcpiTimerLib: Wait 363 ACPI timer counts to get TSC Freq 2016-08-18 11:01:54 +08:00
BaseAcpiTimerLib.inf PcAtChipsetPkg: Update BaseAcpiTimerLib 2015-02-28 05:34:38 +00:00
BaseAcpiTimerLib.uni PcAtChipsetPkg: Convert all .uni files to utf-8 2015-12-15 04:57:25 +00:00
DxeAcpiTimerLib.c PcAtChipsetPkg AcpiTimerLib: Wait 363 ACPI timer counts to get TSC Freq 2016-08-18 11:01:54 +08:00
DxeAcpiTimerLib.inf PcAtChipsetPkg: Update BaseAcpiTimerLib 2015-02-28 05:34:38 +00:00
DxeAcpiTimerLib.uni PcAtChipsetPkg: Convert all .uni files to utf-8 2015-12-15 04:57:25 +00:00