[PATCH v3 21/44] efi/runtime-wrappers: Permit architectures to override IRQ flags checks

Vladimir Murzin vladimir.murzin at arm.com
Thu Dec 3 06:00:35 PST 2026


On 12/2/26 21:34, Ashok Raj wrote:
> On Mon, Nov 30, 2026 at 03:54:43PM +0000, Vladimir Murzin wrote:
>> diff --git a/drivers/firmware/efi/runtime-wrappers.c b/drivers/firmware/efi/runtime-wrappers.c
>> index 20d63d028922..4b633132f707 100644
>> --- a/drivers/firmware/efi/runtime-wrappers.c
>> +++ b/drivers/firmware/efi/runtime-wrappers.c
>> @@ -151,6 +151,28 @@ static bool efi_rts_abandoned;
>>  #define arch_efi_restore_flags(state_flags)	local_irq_restore(state_flags)
>>  #endif
>>  
>> +#ifndef arch_efi_check_flags
>> +#define arch_efi_check_flags(state_flags, caller) 							\
>> +do {													\
>> +	unsigned long cur_flags, mismatch;								\
>> +													\
>> +	cur_flags = efi_call_virt_save_flags();								\
>> +													\
>> +	mismatch = (flags ^ cur_flags) & ARCH_EFI_IRQ_FLAGS_MASK;					\
> Should the above use state_flags instead of flags?
> 

Nice catch! Surely it works only because it used in context where
flags is defined, which also explains why build did not fail.

Thanks!
Vladimir



More information about the linux-arm-kernel mailing list