summaryrefslogtreecommitdiffstats
path: root/ArmPkg
diff options
context:
space:
mode:
authorArd Biesheuvel <ardb@kernel.org>2025-01-16 15:41:31 +0100
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>2025-01-17 18:37:27 +0000
commitec5bb8f95334de73c872a4d071a9800d688efb83 (patch)
tree3c454f3d27f3577934747d13805484bb412e1ed2 /ArmPkg
parent555bbc6643eaef7192f948391e5d16fae439a8c2 (diff)
downloadedk2-ec5bb8f95334de73c872a4d071a9800d688efb83.tar.gz
ArmPkg/ArmGic: drop ArmGicEnableInterruptInterface from ArmGicLib
The ArmGicLib API exposes ArmGicEnableInterruptInterface () and ArmGicDisableInterruptInterface (), but only the former is actually used, and only from the GICv2 driver. So drop the API entirely, and invoke the v2 version of the underlying interface directly. Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
Diffstat (limited to 'ArmPkg')
-rw-r--r--ArmPkg/Drivers/ArmGic/ArmGicLib.c36
-rw-r--r--ArmPkg/Drivers/ArmGic/GicV2/ArmGicV2Dxe.c2
-rw-r--r--ArmPkg/Include/Library/ArmGicLib.h12
3 files changed, 1 insertions, 49 deletions
diff --git a/ArmPkg/Drivers/ArmGic/ArmGicLib.c b/ArmPkg/Drivers/ArmGic/ArmGicLib.c
index 5daca3fde7..206ad2e581 100644
--- a/ArmPkg/Drivers/ArmGic/ArmGicLib.c
+++ b/ArmPkg/Drivers/ArmGic/ArmGicLib.c
@@ -356,39 +356,3 @@ ArmGicDisableDistributor (
// Disable Gic Distributor
MmioWrite32 (GicDistributorBase + ARM_GIC_ICDDCR, 0x0);
}
-
-VOID
-EFIAPI
-ArmGicEnableInterruptInterface (
- IN UINTN GicInterruptInterfaceBase
- )
-{
- ARM_GIC_ARCH_REVISION Revision;
-
- Revision = ArmGicGetSupportedArchRevision ();
- if (Revision == ARM_GIC_ARCH_REVISION_2) {
- ArmGicV2EnableInterruptInterface (GicInterruptInterfaceBase);
- } else if (Revision == ARM_GIC_ARCH_REVISION_3) {
- ArmGicV3EnableInterruptInterface ();
- } else {
- ASSERT_EFI_ERROR (EFI_UNSUPPORTED);
- }
-}
-
-VOID
-EFIAPI
-ArmGicDisableInterruptInterface (
- IN UINTN GicInterruptInterfaceBase
- )
-{
- ARM_GIC_ARCH_REVISION Revision;
-
- Revision = ArmGicGetSupportedArchRevision ();
- if (Revision == ARM_GIC_ARCH_REVISION_2) {
- ArmGicV2DisableInterruptInterface (GicInterruptInterfaceBase);
- } else if (Revision == ARM_GIC_ARCH_REVISION_3) {
- ArmGicV3DisableInterruptInterface ();
- } else {
- ASSERT_EFI_ERROR (EFI_UNSUPPORTED);
- }
-}
diff --git a/ArmPkg/Drivers/ArmGic/GicV2/ArmGicV2Dxe.c b/ArmPkg/Drivers/ArmGic/GicV2/ArmGicV2Dxe.c
index cd65cf06d7..ef48177ee5 100644
--- a/ArmPkg/Drivers/ArmGic/GicV2/ArmGicV2Dxe.c
+++ b/ArmPkg/Drivers/ArmGic/GicV2/ArmGicV2Dxe.c
@@ -451,7 +451,7 @@ GicV2DxeInitialize (
MmioWrite32 (mGicInterruptInterfaceBase + ARM_GIC_ICCPMR, 0xff);
// Enable gic cpu interface
- ArmGicEnableInterruptInterface (mGicInterruptInterfaceBase);
+ ArmGicV2EnableInterruptInterface (mGicInterruptInterfaceBase);
// Enable gic distributor
ArmGicEnableDistributor (mGicDistributorBase);
diff --git a/ArmPkg/Include/Library/ArmGicLib.h b/ArmPkg/Include/Library/ArmGicLib.h
index 2874ea2b0b..32807c213b 100644
--- a/ArmPkg/Include/Library/ArmGicLib.h
+++ b/ArmPkg/Include/Library/ArmGicLib.h
@@ -135,18 +135,6 @@ ArmGicSetSecureInterrupts (
VOID
EFIAPI
-ArmGicEnableInterruptInterface (
- IN UINTN GicInterruptInterfaceBase
- );
-
-VOID
-EFIAPI
-ArmGicDisableInterruptInterface (
- IN UINTN GicInterruptInterfaceBase
- );
-
-VOID
-EFIAPI
ArmGicEnableDistributor (
IN UINTN GicDistributorBase
);