ArmPkg/ArmGic: Introduced support for GicV2 to ArmGicLib
The support for GIcV2 was already existing. This change separate the GicV2 specific functions from the common Gic code (in preparation for GicV3 support). Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Olivier Martin <olivier.martin@arm.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15626 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
committed by
oliviermartin
parent
60775c51a5
commit
793ca69f50
@@ -16,6 +16,8 @@
|
||||
#include <Library/ArmGicLib.h>
|
||||
#include <Library/IoLib.h>
|
||||
|
||||
#include "GicV2/ArmGicV2Lib.h"
|
||||
|
||||
UINTN
|
||||
EFIAPI
|
||||
ArmGicGetInterfaceIdentification (
|
||||
@@ -53,8 +55,7 @@ ArmGicAcknowledgeInterrupt (
|
||||
IN UINTN GicInterruptInterfaceBase
|
||||
)
|
||||
{
|
||||
// Read the Interrupt Acknowledge Register
|
||||
return MmioRead32 (GicInterruptInterfaceBase + ARM_GIC_ICCIAR);
|
||||
return ArmGicV2AcknowledgeInterrupt (GicInterruptInterfaceBase);
|
||||
}
|
||||
|
||||
VOID
|
||||
@@ -64,7 +65,7 @@ ArmGicEndOfInterrupt (
|
||||
IN UINTN Source
|
||||
)
|
||||
{
|
||||
MmioWrite32 (GicInterruptInterfaceBase + ARM_GIC_ICCEIOR, Source);
|
||||
ArmGicV2EndOfInterrupt (GicInterruptInterfaceBase, Source);
|
||||
}
|
||||
|
||||
VOID
|
||||
@@ -129,3 +130,21 @@ ArmGicDisableDistributor (
|
||||
// Disable Gic Distributor
|
||||
MmioWrite32 (GicDistributorBase + ARM_GIC_ICDDCR, 0x0);
|
||||
}
|
||||
|
||||
VOID
|
||||
EFIAPI
|
||||
ArmGicEnableInterruptInterface (
|
||||
IN INTN GicInterruptInterfaceBase
|
||||
)
|
||||
{
|
||||
return ArmGicV2EnableInterruptInterface (GicInterruptInterfaceBase);
|
||||
}
|
||||
|
||||
VOID
|
||||
EFIAPI
|
||||
ArmGicDisableInterruptInterface (
|
||||
IN INTN GicInterruptInterfaceBase
|
||||
)
|
||||
{
|
||||
return ArmGicV2DisableInterruptInterface (GicInterruptInterfaceBase);
|
||||
}
|
||||
|
Reference in New Issue
Block a user