Use separate function for making FF-A calls to EL3.
smc_forward was being abused. Also add some more comments.
Change-Id: I0f24b89b7e0d2f56c75d7314ceda5a8bc647c410
diff --git a/src/arch/aarch64/hypervisor/handler.c b/src/arch/aarch64/hypervisor/handler.c
index 10caf40..28625fb 100644
--- a/src/arch/aarch64/hypervisor/handler.c
+++ b/src/arch/aarch64/hypervisor/handler.c
@@ -466,12 +466,14 @@
* The FF-A call is handled and ffa_next is null which hints
* the result shall be passed to the other world.
*/
- *ret = smc_forward(ret->func, ret->arg1, ret->arg2, ret->arg3,
- ret->arg4, ret->arg5, ret->arg6, ret->arg7);
+ *ret = smc_ffa_call(*ret);
/*
- * Returned from EL3 thus next FF-A call is from
- * physical FF-A instance.
+ * Returned from EL3, thus *ret contains an FF-A call from the
+ * physical FF-A instance. Handle it. At this point ffa_next is
+ * NULL, which means that we will return the result of the call
+ * back to EL3 unless the API handler sets ffa_next to something
+ * different.
*/
handled = ffa_handler(ret, other_world_vcpu, &ffa_next);
}