Page MenuHomeFreeBSD

Move kernel vmem arena initialization to vm_kern.c.
ClosedPublic

Authored by markj on Sep 19 2018, 5:20 PM.
Tags
None
Referenced Files
F152635548: D17247.id48229.diff
Thu, Apr 16, 4:18 AM
F152611397: D17247.diff
Thu, Apr 16, 12:05 AM
Unknown Object (File)
Wed, Apr 15, 9:17 AM
Unknown Object (File)
Sun, Apr 12, 12:21 AM
Unknown Object (File)
Sat, Apr 11, 5:49 AM
Unknown Object (File)
Sun, Apr 5, 11:19 AM
Unknown Object (File)
Thu, Mar 26, 3:51 AM
Unknown Object (File)
Tue, Mar 24, 4:36 AM
Subscribers

Details

Summary

The details of this initialization belong in vm_kern.c anyway, and allow
me to use KVA_QUANTUM in vm_kern.c without defining it in a header.

No functional change intended.

Diff Detail

Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 19680
Build 19247: arc lint + arc unit

Event Timeline

alc added inline comments.
sys/vm/vm_kern.c
745–747

It's not clear to me that using vmem_alloc() as the import function guarantees alignment. I fear that we are only guaranteed that the size is a multiple of KVA_QUANTUM.

This revision is now accepted and ready to land.Sep 19 2018, 5:54 PM
markj added inline comments.
sys/vm/vm_kern.c
745–747

I think you're right, and the problem is only hidden as a result of the current kernel arena usage patterns. In particular, vmem freelist entries aren't necessarily size-aligned.

This revision was automatically updated to reflect the committed changes.