• Ard Biesheuvel's avatar
    efi/runtime-wrappers: Run UEFI Runtime Services with interrupts enabled · fe324494
    Ard Biesheuvel authored
    The UEFI spec allows Runtime Services to be invoked with interrupts
    enabled. The only reason we were disabling interrupts was to prevent
    recursive calls into the services on the same CPU, which will lead to
    deadlock. However, the only context where such invocations may occur
    legally is from efi-pstore via efivars, and that code has been updated
    to call a non-blocking alternative when invoked from a non-interruptible
    context.
    
    So instead, update the ordinary, blocking UEFI Runtime Services wrappers
    to execute with interrupts enabled. This aims to prevent excessive interrupt
    latencies on uniprocessor platforms with slow variable stores.
    
    Note that other OSes such as Windows call UEFI Runtime Services with
    interrupts enabled as well.
    Signed-off-by: default avatarArd Biesheuvel <ard.biesheuvel@linaro.org>
    Signed-off-by: default avatarMatt Fleming <matt@codeblueprint.co.uk>
    Cc: Andy Lutomirski <luto@amacapital.net>
    Cc: Linus Torvalds <torvalds@linux-foundation.org>
    Cc: Peter Zijlstra <peterz@infradead.org>
    Cc: Sai Praneeth Prakhya <sai.praneeth.prakhya@intel.com>
    Cc: Thomas Gleixner <tglx@linutronix.de>
    Cc: linux-efi@vger.kernel.org
    Link: http://lkml.kernel.org/r/1455712566-16727-3-git-send-email-matt@codeblueprint.co.ukSigned-off-by: default avatarIngo Molnar <mingo@kernel.org>
    fe324494
runtime-wrappers.c 7.84 KB