refactor(gic): make the concept of SGI generic
Software generated interrupts (SGIs) are a GICv2/3/4 concept. However,
they are deeply embedded in how TFTF handles wake ups. This patch
promotes the SGI to an abstract concept that can be performed
independently of the interrupt controller, largely the same as it is
used today. To do that the interrupt interface for an SGI is separated
from the general IRQ and each SGI is assigned a linear index from 0
onwards. Translating from SGI to IRQ is done via a hook in arm_gic.c
that will be multiplexed to the appropriate driver. For GIC <= v3 this
is a thin wrapper around the identity mapping as SGIs map to INTIDs from
0 through 15. For GICv5 the mapping is different and an SGI is an LPI
and calculated as recommended by chapter 2.5 in the spec.
Additionally, the definitions of SGI numbers are made generic as no
platform has utilised the difference.
Change-Id: I7e6a5fbe655098c5e235b98f6dda8a14619a5904
Signed-off-by: Boyan Karatotev <boyan.karatotev@arm.com>
36 files changed