On Wed, Jan 9, 2019 at 1:33 AM Dave Hansen <dave.hansen@xxxxxxxxx> wrote: > > On 1/7/19 10:13 PM, Pingfan Liu wrote: > > On Tue, Jan 8, 2019 at 1:42 AM Dave Hansen <dave.hansen@xxxxxxxxx> wrote: > >> Why is this 0x100000 open-coded? Why is this needed *now*? > >> > > > > Memory under 1MB should be used by BIOS. For x86_64, after > > e820__memblock_setup(), the memblock allocator has already been ready > > to work. But there are two factors to in order to > > set_alloc_range(0x100000, end). The major one is to be compatible with > > x86_32, please refer to alloc_low_pages->memblock_find_in_range() uses > > [min_pfn_mapped, max_pfn_mapped] to limit the range, which is ready to > > be allocated from. The minor one is to prevent unexpected allocation > > from memblock allocator through allow_low_pages() at very early stage. > > Wow, that's a ton of critical information which was neither commented > upon or referenced in the changelog. Can you fix this up in the next > version, please? Sure. Thanks, Pingfan