refactor(interrupts): remove api_interrupt_inject

api_interrupt_inject and vcpu_interrupt_inject were performing the
same function, as the next argument was never being used. So just
use vcpu_interrupt_inject.

Also remove unnecessary if statement from vcpu_interrupt_inject.

Signed-off-by: Daniel Boulby <daniel.boulby@arm.com>
Change-Id: I36c5157b7961e5a85b3e485f0a309b5dddf7c21a
diff --git a/src/arch/aarch64/hypervisor/handler.c b/src/arch/aarch64/hypervisor/handler.c
index 2328d41..854138b 100644
--- a/src/arch/aarch64/hypervisor/handler.c
+++ b/src/arch/aarch64/hypervisor/handler.c
@@ -1134,7 +1134,6 @@
 #if SECURE_WORLD == 1
 	struct vcpu_locked current_locked;
 	struct vcpu *current_vcpu = current();
-	int64_t ret;
 	uint32_t intid;
 
 	intid = get_highest_pending_g0_interrupt_id();
@@ -1166,12 +1165,7 @@
 
 		current_locked = vcpu_lock(current_vcpu);
 		current_vcpu->prev_interrupt_priority = pmr;
-		ret = api_interrupt_inject_locked(current_locked,
-						  HF_MANAGED_EXIT_INTID,
-						  current_locked, NULL);
-		if (ret != 0) {
-			panic("Failed to inject managed exit interrupt\n");
-		}
+		vcpu_interrupt_inject(current_locked, HF_MANAGED_EXIT_INTID);
 
 		/* Entering managed exit sequence. */
 		current_vcpu->processing_managed_exit = true;
diff --git a/src/arch/fake/hypervisor/ffa.c b/src/arch/fake/hypervisor/ffa.c
index b01e967..66cee73 100644
--- a/src/arch/fake/hypervisor/ffa.c
+++ b/src/arch/fake/hypervisor/ffa.c
@@ -354,11 +354,9 @@
 }
 
 bool ffa_interrupts_inject_notification_pending_interrupt(
-	struct vcpu_locked target_locked, struct vcpu_locked current_locked,
-	struct vm_locked receiver_locked)
+	struct vcpu_locked target_locked, struct vm_locked receiver_locked)
 {
 	(void)target_locked;
-	(void)current_locked;
 	(void)receiver_locked;
 
 	return false;