On Mon, Jan 21, 2019 at 6:49 PM Wei Yang <richardw.yang(a)linux.intel.com> wrote:
There are two places to calculate npfns in nd_pfn_init(), while they use
difference size to calculate.
Use PAGE_SIZE would be more proper for calculation.
No, this would make the kernel have different output based on
PAGE_SIZE. It should be possible for a PAGE_SIZE==64K system to create
a valid info-block for PAGE_SIZE==4K system. This would need to encode
the PAGE_SIZE in the info-block if it were to ever support non-4K
Another consideration is that a PAGE_SIZE==4K infoblock is compatible
with a PAGE_SIZE==64K system. All that happens is that the memmap
reserve area is oversized and portions go unused. The reverse is not