From fcd1ad8d4e04995fbc75c2c0968c484a0dc5255c Mon Sep 17 00:00:00 2001 From: Soren Brinkmann Date: Sun, 12 Apr 2015 20:24:24 -0700 Subject: [PATCH] xilpm example: Remove gic_setup_handler() The function is just a trivial wrapper and used once only. Just inline it. Signed-off-by: Soren Brinkmann --- lib/sw_services/xilpm/examples/gic_setup.c | 22 +--------------------- lib/sw_services/xilpm/examples/gic_setup.h | 2 -- 2 files changed, 1 insertion(+), 23 deletions(-) diff --git a/lib/sw_services/xilpm/examples/gic_setup.c b/lib/sw_services/xilpm/examples/gic_setup.c index 482aa4d4..f43e8373 100644 --- a/lib/sw_services/xilpm/examples/gic_setup.c +++ b/lib/sw_services/xilpm/examples/gic_setup.c @@ -38,27 +38,7 @@ #include "gic_setup.h" XScuGic GicInst; -/** - * GicSetupHandler() - Connect interrupt Handler to the specified interrupt number - * @IntId Interrupt id - * @PeriphInstPtr Pointer to the peripheral driver - * @Handler Interrupt Handler that for the specified peripheral - * - * @return Status of operation success (XST_* from xstatus.h) - */ -int32_t GicSetupHandler(uint32_t IntId, void *PeriphInstPtr, Xil_ExceptionHandler Handler) -{ - int32_t status; - /* - * Connect a device driver Handler that will be called when an - * interrupt for the device occurs, the device driver Handler - * performs the specific interrupt processing for the device - */ - status = XScuGic_Connect(&GicInst, IntId, Handler, PeriphInstPtr); - - return status; -} /** * GicEnableInterrupt() - Enable interrupt in gic */ @@ -115,7 +95,7 @@ int32_t GicSetupInterruptSystem(uint32_t IntId, if(XST_SUCCESS != Status) return Status; - Status = GicSetupHandler(IntId, PeriphInstPtr, Handler); + Status = XScuGic_Connect(&GicInst, IntId, Handler, PeriphInstPtr); if(XST_SUCCESS != Status) return Status; diff --git a/lib/sw_services/xilpm/examples/gic_setup.h b/lib/sw_services/xilpm/examples/gic_setup.h index 46794133..c2f22287 100644 --- a/lib/sw_services/xilpm/examples/gic_setup.h +++ b/lib/sw_services/xilpm/examples/gic_setup.h @@ -39,8 +39,6 @@ extern XScuGic GicInst; -int32_t GicSetupHandler(uint32_t IntId, void *PeriphInstPtr, Xil_ExceptionHandler Handler); - void GicEnableInterrupt(uint32_t IntId); int32_t GicSetupInterruptSystem(uint32_t IntId,