fix(ff-a): FFA_RUN checking of vcpu index
FFA_RUN in the secure world, does not check that the vCPU index provided
is the same as the physical CPU index. Per the FF-A specification, all
MP partitions are pinned to a physical cpu and if this is not checked,
FFA_RUN can be successfully called on an arbitrary vCPU..
Signed-off-by: Raghu Krishnamurthy <raghu.ncstate@gmail.com>
Change-Id: I4edb02e1624efa54d3eee5a36eba4f9fed26e580
diff --git a/src/api.c b/src/api.c
index bb9c79e..8ce4136 100644
--- a/src/api.c
+++ b/src/api.c
@@ -877,7 +877,7 @@
struct vcpu *vcpu;
struct ffa_value ret = ffa_error(FFA_INVALID_PARAMETERS);
- if (!plat_ffa_run_checks(current, vm_id, &ret, next)) {
+ if (!plat_ffa_run_checks(current, vm_id, vcpu_idx, &ret, next)) {
return ret;
}