]> git.baikalelectronics.ru Git - kernel.git/commit
x86/boot/64: Round memory hole size up to next PMD page
authorSteve Wahl <steve.wahl@hpe.com>
Tue, 24 Sep 2019 21:04:31 +0000 (16:04 -0500)
committerBorislav Petkov <bp@suse.de>
Fri, 11 Oct 2019 16:47:23 +0000 (18:47 +0200)
commit57de37258141963bc148e7895be8125564f080ba
tree45e006fe7f33b91aa6423c3438beefebac8f25e9
parentbffe6a3edc6bb9919df5b70bb36594c0ae048e4b
x86/boot/64: Round memory hole size up to next PMD page

The kernel image map is created using PMD pages, which can include
some extra space beyond what's actually needed.  Round the size of the
memory hole we search for up to the next PMD boundary, to be certain
all of the space to be mapped is usable RAM and includes no reserved
areas.

Signed-off-by: Steve Wahl <steve.wahl@hpe.com>
Signed-off-by: Borislav Petkov <bp@suse.de>
Acked-by: Dave Hansen <dave.hansen@linux.intel.com>
Acked-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>
Cc: Baoquan He <bhe@redhat.com>
Cc: Brijesh Singh <brijesh.singh@amd.com>
Cc: dimitri.sivanich@hpe.com
Cc: Feng Tang <feng.tang@intel.com>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Jordan Borgner <mail@jordan-borgner.de>
Cc: Juergen Gross <jgross@suse.com>
Cc: mike.travis@hpe.com
Cc: russ.anderson@hpe.com
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: x86-ml <x86@kernel.org>
Cc: Zhenzhong Duan <zhenzhong.duan@oracle.com>
Link: https://lkml.kernel.org/r/df4f49f05c0c27f108234eb93db5c613d09ea62e.1569358539.git.steve.wahl@hpe.com
arch/x86/boot/compressed/misc.c