Skip to content

Commit eba1e44

Browse files
author
Marc Zyngier
committed
irqchip/gic-v3-its: Skip HP notifier when no ITS is registered
We have some systems out there that have both LPI support and an ITS, but that don't expose the ITS in their firmware tables (either because it is broken or because they run under a hypervisor that hides it...). Is such a configuration, we still register the HP notifier to free the allocated tables if needed, resulting in a warning as there is no memory to free (nothing was allocated the first place). Fix it by keying the HP notifier on the presence of at least one sucessfully probed ITS. Fixes: d23bc2b ("irqchip/gic-v3-its: Postpone LPI pending table freeing and memreserve") Reported-by: Steev Klimaszewski <[email protected]> Tested-by: Steev Klimaszewski <[email protected]> Signed-off-by: Marc Zyngier <[email protected]> Cc: Valentin Schneider <[email protected]> Link: https://lore.kernel.org/r/[email protected]
1 parent 26291c5 commit eba1e44

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

drivers/irqchip/irq-gic-v3-its.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5517,6 +5517,9 @@ int __init its_lpi_memreserve_init(void)
55175517
if (!efi_enabled(EFI_CONFIG_TABLES))
55185518
return 0;
55195519

5520+
if (list_empty(&its_nodes))
5521+
return 0;
5522+
55205523
gic_rdists->cpuhp_memreserve_state = CPUHP_INVALID;
55215524
state = cpuhp_setup_state(CPUHP_AP_ONLINE_DYN,
55225525
"irqchip/arm/gicv3/memreserve:online",

0 commit comments

Comments
 (0)