efi/esrt: Use efi_mem_reserve() and avoid a kmalloc()
authorMatt Fleming <matt@codeblueprint.co.uk>
Tue, 1 Mar 2016 23:08:03 +0000 (23:08 +0000)
committerMatt Fleming <matt@codeblueprint.co.uk>
Fri, 9 Sep 2016 15:08:37 +0000 (16:08 +0100)
commit8e80632fb23f021ce5a6957f2edcdae4645a7030
tree02613c2a9158598641fb36dbf8bb12eaa60cca10
parent31ce8cc68180803aa481c0c1daac29d8eaceca9d
efi/esrt: Use efi_mem_reserve() and avoid a kmalloc()

We can use the new efi_mem_reserve() API to mark the ESRT table as
reserved forever and save ourselves the trouble of copying the data
out into a kmalloc buffer.

The added advantage is that now the ESRT driver will work across
kexec reboot.

Tested-by: Dave Young <dyoung@redhat.com> [kexec/kdump]
Tested-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> [arm]
Acked-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Cc: Leif Lindholm <leif.lindholm@linaro.org>
Cc: Peter Jones <pjones@redhat.com>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Mark Rutland <mark.rutland@arm.com>
Signed-off-by: Matt Fleming <matt@codeblueprint.co.uk>
drivers/firmware/efi/esrt.c