Introduce interrupt registration framework in BL3-1
This patch introduces a framework for registering interrupts routed to
EL3. The interrupt routing model is governed by the SCR_EL3.IRQ and
FIQ bits and the security state an interrupt is generated in. The
framework recognizes three type of interrupts depending upon which
exception level and security state they should be handled in
i.e. Secure EL1 interrupts, Non-secure interrupts and EL3
interrupts. It provides an API and macros that allow a runtime service
to register an handler for a type of interrupt and specify the routing
model. The framework validates the routing model and uses the context
management framework to ensure that it is applied to the SCR_EL3 prior
to entry into the target security state. It saves the handler in
internal data structures. An API is provided to retrieve the handler
when an interrupt of a particular type is asserted. Registration is
expected to be done once by the primary CPU. The same handler and
routing model is used for all CPUs.

Support for EL3 interrupts will be added to the framework in the
future. A makefile flag has been added to allow the FVP port choose
between ARM GIC v2 and v3 support in EL3. The latter version is
currently unsupported.

A framework for handling interrupts in BL3-1 will be introduced in
subsequent patches. The default routing model in the absence of any
handlers expects no interrupts to be routed to EL3.

Change-Id: Idf7c023b34fcd4800a5980f2bef85e4b5c29e649
1 parent c429b5e commit e1333f753f2760499ceed5c2d8f816574c3feb02
@Achin Gupta Achin Gupta authored on 9 May 2014
Showing 10 changed files
View
bl31/bl31.mk
View
bl31/context_mgmt.c
View
bl31/interrupt_mgmt.c 0 → 100644
View
docs/user-guide.md
View
drivers/arm/gic/gic_v2.c
View
include/bl31/interrupt_mgmt.h 0 → 100644
View
include/drivers/arm/gic_v2.h
View
plat/fvp/plat_gic.c
View
plat/fvp/platform.h
View
plat/fvp/platform.mk