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)
Dec 20 2023, 7:10 AM
Unknown Object (File)
Dec 3 2023, 2:31 AM
Unknown Object (File)
Nov 28 2023, 10:54 PM
Unknown Object (File)
Oct 10 2023, 12:54 AM
Unknown Object (File)
Aug 13 2023, 4:54 PM
Unknown Object (File)
Aug 2 2023, 4:56 PM
Unknown Object (File)
Aug 2 2023, 4:53 PM
Unknown Object (File)
Aug 1 2023, 10:13 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)