efi: stub: use high allocation for converted command line
authorArd Biesheuvel <ard.biesheuvel@linaro.org>
Mon, 11 Jan 2016 10:47:49 +0000 (11:47 +0100)
committerAlex Shi <alex.shi@linaro.org>
Wed, 11 May 2016 15:21:17 +0000 (23:21 +0800)
commit4a9c1460b2b904c4a9b6438a14d10c56e0e9ab78
tree53f1dbea23639fa1e540023652bdca88cd551f0c
parent0f01a865b4feb17ff014717ed2745a845e0c0ee3
efi: stub: use high allocation for converted command line

Before we can move the command line processing before the allocation
of the kernel, which is required for detecting the 'nokaslr' option
which controls that allocation, move the converted command line higher
up in memory, to prevent it from interfering with the kernel itself.

Since x86 needs the address to fit in 32 bits, use UINT_MAX as the upper
bound there. Otherwise, use ULONG_MAX (i.e., no limit)

Reviewed-by: Matt Fleming <matt@codeblueprint.co.uk>
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
(cherry picked from commit 48fcb2d0216103d15306caa4814e2381104df6d8)
Signed-off-by: Alex Shi <alex.shi@linaro.org>
arch/x86/include/asm/efi.h
drivers/firmware/efi/libstub/efi-stub-helper.c