Page MenuHomeFreeBSD

Use CPUID leaf 0x40000010 for local APIC freq
ClosedPublic

Authored by cperciva on Jan 14 2022, 6:32 AM.
Tags
None
Referenced Files
Unknown Object (File)
Sat, Oct 4, 3:52 PM
Unknown Object (File)
Wed, Sep 17, 5:10 PM
Unknown Object (File)
Aug 31 2025, 3:41 PM
Unknown Object (File)
Aug 14 2025, 11:05 PM
Unknown Object (File)
Jul 26 2025, 7:58 PM
Unknown Object (File)
Jul 23 2025, 3:39 PM
Unknown Object (File)
Jul 7 2025, 1:21 PM
Unknown Object (File)
Jun 25 2025, 2:57 AM
Subscribers

Details

Reviewers
markj
Summary

Some VM systems announce the frequency of the local APIC via the
CPUID leaf 0x40000010. Using this allows us to boot slightly
faster by avoiding the need for timer calibration.

Sponsored by: https://www.patreon.com/cperciva

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 43934
Build 40822: arc lint + arc unit

Event Timeline

sys/x86/x86/local_apic.c
1017

Can this multiplication overflow? I suspect value should be uint64_t too.

sys/x86/x86/local_apic.c
1017

Thanks, fixed!

This revision is now accepted and ready to land.Jan 14 2022, 11:27 PM

Committed. (I forgot to include the Differential Revision tag in the commit message.)