Add mod_align_size to specify the size of alignment. This controls how
md_align aligns things, thus controlling the alignment of
modules. Normally, you'd leave this unset. But if you have a 16k
PAGE_SIZE kernel on an architecture that defaults to 4k page size for
userland, then you'd set mod_align_size=16384 in your loader.conf. This
must be greater than or equal to the page size, less than 32,768 times
the page size (4k -> 128K on x86) and a power of two.
While it doesn't hurt to set this too big, it does waste memory. Setting
too small can lead to writeable text segments in the kernel... One
usually never sets it, though, since non-default pagesize kernels are a
specialty item still.
Future work would include having the page_size exported from the kernel
and some automation to find it when we first load the ELF kernel (which
typically is loaded with a 2MB alignmet), but not today.
Sponsored by: Netflix