Page MenuHomeFreeBSD

x86: make the arrays that depend on MAX_APIC_ID dynamic
ClosedPublic

Authored by royger on Aug 7 2017, 10:23 AM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Dec 16, 3:02 AM
Unknown Object (File)
Sun, Dec 1, 3:03 AM
Unknown Object (File)
Mon, Nov 25, 6:15 PM
Unknown Object (File)
Nov 22 2024, 7:23 PM
Unknown Object (File)
Nov 22 2024, 7:40 AM
Unknown Object (File)
Nov 21 2024, 7:11 AM
Unknown Object (File)
Nov 10 2024, 2:16 PM
Unknown Object (File)
Nov 5 2024, 11:28 AM
Subscribers
None

Details

Summary

So that MAX_APIC_ID can be bumped without wasting memory.

Note that the usage of MAX_APIC_ID in the SRAT parsing forces the
parser to allocate memory directly from the phys_avail physical memory
array, which is not the best approach probably, but I haven't found
any other way to allocate memory so early in boot. This memory is not
returned to the system afterwards, but at least it's sized according
to the maximum APIC ID found in the MADT table.

Sponsored by: Citrix Systems R&D

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

kib added inline comments.
sys/x86/acpica/srat.c
479 ↗(On Diff #31699)

I believe this is fine, it starts to take 2 pages when max_apic_id > 512.

This revision is now accepted and ready to land.Aug 7 2017, 11:09 AM
This revision was automatically updated to reflect the committed changes.