Page MenuHomeFreeBSD

Move phys_avail and dump_avail into MI code.
ClosedPublic

Authored by jeff on Aug 13 2019, 5:31 PM.
Tags
None
Referenced Files
Unknown Object (File)
Thu, Nov 21, 6:46 AM
Unknown Object (File)
Sun, Nov 17, 5:30 AM
Unknown Object (File)
Oct 9 2024, 5:23 AM
Unknown Object (File)
Oct 2 2024, 12:28 PM
Unknown Object (File)
Oct 1 2024, 11:02 PM
Unknown Object (File)
Oct 1 2024, 10:16 PM
Unknown Object (File)
Oct 1 2024, 9:11 PM
Unknown Object (File)
Oct 1 2024, 8:17 PM

Details

Summary

I need to move phys_avail and dump_avail into MI code so that I can write boot time allocators. This also eliminates a lot of confusing redundant code and definitions. Since MI is manipulating these arrays it makes sense to define them MI.

The following two revisions depend on this refactoring:

https://reviews.freebsd.org/D21251
https://reviews.freebsd.org/D21252

Test Plan

I have built universe and tested on amd64.

Diff Detail

Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 25846
Build 24417: arc lint + arc unit

Event Timeline

jeff added reviewers: kib, jhb, jhibbits.
sys/vm/vm_param.h
132

Maybe (PHYS_AVAIL_ENTRIES + 2) (similar to how the default for PHYS_AVAIL_ENTRIES is defined above)

sys/vm/vm_phys.c
122

Do you want to add a note here to say something like: "Initially dump_avail matches phys_avail, but phys_avail is modified during boot to provide early memory allocations before the VM system is able to allocate memory."?

jeff edited the test plan for this revision. (Show Details)
jeff added reviewers: br, mhorne, marius, markj.
sys/amd64/include/pmap.h
229

This crept in from a different commit. I will fix before I merge.

markj added inline comments.
sys/mips/mips/machdep.c
144

I think this can actually be PHYS_AVAIL_ENTRIES, but it doesn't really matter.

sys/vm/vm_phys.h
52

Extra newline.

This revision is now accepted and ready to land.Aug 13 2019, 7:32 PM

(assuming Mark and John notes are handled)