• Jeffrey Hugo's avatar
    x86/efi: Use efi_exit_boot_services() · 9a11360e
    Jeffrey Hugo authored
    commit d6493401 upstream.
    
    The eboot code directly calls ExitBootServices.  This is inadvisable as the
    UEFI spec details a complex set of errors, race conditions, and API
    interactions that the caller of ExitBootServices must get correct.  The
    eboot code attempts allocations after calling ExitBootSerives which is
    not permitted per the spec.  Call the efi_exit_boot_services() helper
    intead, which handles the allocation scenario properly.
    Signed-off-by: default avatarJeffrey Hugo <jhugo@codeaurora.org>
    Cc: Ard Biesheuvel <ard.biesheuvel@linaro.org>
    Cc: Mark Rutland <mark.rutland@arm.com>
    Cc: Leif Lindholm <leif.lindholm@linaro.org>
    Cc: Ingo Molnar <mingo@kernel.org>
    Signed-off-by: default avatarMatt Fleming <matt@codeblueprint.co.uk>
    Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
    9a11360e
eboot.c 29.6 KB