Commit dd4d71f5 authored by Ben Horgan's avatar Ben Horgan Committed by Catalin Marinas
Browse files

arm64/efi: Don't fail check current_in_efi() if preemptible



As EFI runtime services can now be run without disabling preemption remove
the check for non preemptible in current_in_efi(). Without this change,
firmware errors that were previously recovered from by
__efi_runtime_kernel_fixup_exception() will lead to a kernel oops.

Fixes: a5baf582 ("arm64/efi: Call EFI runtime services without disabling preemption")
Signed-off-by: default avatarBen Horgan <ben.horgan@arm.com>
Reviewed-by: default avatarYeoreum Yun <yeoreum.yun@arm.com>
Acked-by: default avatarArd Biesheuvel <ardb@kernel.org>
Reviewed-by: default avatarRichard Lyu <richard.lyu@suse.com>
Signed-off-by: default avatarCatalin Marinas <catalin.marinas@arm.com>
parent f4ea8e05
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -45,7 +45,7 @@ void arch_efi_call_virt_teardown(void);
 * switching to the EFI runtime stack.
 */
#define current_in_efi()						\
	(!preemptible() && efi_rt_stack_top != NULL &&			\
	(efi_rt_stack_top != NULL &&					\
	 on_task_stack(current, READ_ONCE(efi_rt_stack_top[-1]), 1))

#define ARCH_EFI_IRQ_FLAGS_MASK (PSR_D_BIT | PSR_A_BIT | PSR_I_BIT | PSR_F_BIT)