Page MenuHomeFreeBSD

Increase number of regions in physical RAM which can be tracked
AcceptedPublic

Authored by bcran on Sat, Oct 19, 7:27 PM.
Tags
None
Referenced Files
Unknown Object (File)
Wed, Oct 30, 8:17 AM
Unknown Object (File)
Sat, Oct 26, 6:46 AM
Unknown Object (File)
Sat, Oct 26, 6:45 AM
Unknown Object (File)
Sat, Oct 26, 6:45 AM
Unknown Object (File)
Sat, Oct 26, 6:45 AM
Unknown Object (File)
Sat, Oct 26, 6:32 AM
Unknown Object (File)
Mon, Oct 21, 10:57 PM
Unknown Object (File)
Mon, Oct 21, 12:32 PM
Subscribers

Details

Reviewers
imp
manu
andrew
Summary

The ASRock Rack ALTRAD8UD-1L2T AMI AptioV UEFI firmware has 63
areas of memory with RuntimeServicesData or RuntimeServicesCode.

Increase the values of MAX_HWCNT and MAX_EXCNT to 256 to avoid
overflowing the arrays (resulting in the boot hanging) when booting on
this system or any others which have very fragmented memory maps.

Test Plan

Verified that after this change FreeBSD -CURRENT boots on my ALTRAD8UD-1L2T
system. Also verified that by allocating 40 alternating runtime and boot
areas on my ADLINK Ampere Altra Dev Platform with EDK2 UEFI firmware that
FreeBSD also ends up hanging.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 60103
Build 56987: arc lint + arc unit

Event Timeline

bcran requested review of this revision.Sat, Oct 19, 7:27 PM

The increased memory is trivial. Why not 128 if there's one with 63 now?

This revision is now accepted and ready to land.Sat, Oct 19, 7:37 PM

Increase array size to 256, as suggested by the developer who root caused the problem.

This revision now requires review to proceed.Sat, Oct 19, 7:51 PM

Actually update the value to 256.

In D47202#1076166, @imp wrote:

The increased memory is trivial. Why not 128 if there's one with 63 now?

The PAE engineer who root caused the hang suggested 256 or 512, so I've updated the patch to 256.

bcran retitled this revision from Double number of regions in physical RAM which can be tracked to Increase number of regions in physical RAM which can be tracked.Sat, Oct 19, 7:54 PM
bcran edited the summary of this revision. (Show Details)

All good. Do you need someone to push the change? Or do you still have a valid bit?

This revision is now accepted and ready to land.Sat, Oct 19, 9:18 PM
In D47202#1076215, @imp wrote:

All good. Do you need someone to push the change? Or do you still have a valid bit?

Thanks. I need someone to push the change, since my bit was taken for safekeeping.