feat(ff-a): save partitions version during ffa_version

This will be useful later when we may need to consider the version
of a partition when structuring a response to certain FF-A functions.

Also add a call to FFA_VERSION during initialization of the hypervisor
so the SPMC knows the hypervisors implemented version.

Signed-off-by: Daniel Boulby <daniel.boulby@arm.com>
Change-Id: Ia8f5f8a9589300311a1e129536acce0948d5a6bc
diff --git a/inc/hf/api.h b/inc/hf/api.h
index aae2298..640c980 100644
--- a/inc/hf/api.h
+++ b/inc/hf/api.h
@@ -56,7 +56,8 @@
 struct ffa_value api_ffa_rxtx_unmap(ffa_vm_id_t allocator_id,
 				    struct vcpu *current);
 struct ffa_value api_yield(struct vcpu *current, struct vcpu **next);
-struct ffa_value api_ffa_version(uint32_t requested_version);
+struct ffa_value api_ffa_version(struct vcpu *current,
+				 uint32_t requested_version);
 struct ffa_value api_ffa_partition_info_get(struct vcpu *current,
 					    const struct ffa_uuid *uuid);
 struct ffa_value api_ffa_id_get(const struct vcpu *current);
diff --git a/inc/hf/vm.h b/inc/hf/vm.h
index a2ebc25..7469113 100644
--- a/inc/hf/vm.h
+++ b/inc/hf/vm.h
@@ -168,6 +168,7 @@
 struct vm {
 	ffa_vm_id_t id;
 	struct ffa_uuid uuid;
+	uint32_t ffa_version;
 	struct smc_whitelist smc_whitelist;
 
 	/** See api.c for the partial ordering on locks. */