fix(ff-a): harden ffa_secondary_ep_register abi
Add more verbose comments with references to the specification for the
FFA_SECONDARY_EP_REGISTER ABI implementation.
Add FFA_FEATURES response to FFA_SECONDARY_EP_REGISTER ABI
for the SPMC case.
Add check whether ABI is called in context of Hypervisor or SPMC.
Reject the call in the former case.
Reject the FFA_SECONDARY_EP_REGISTER call for UP partitions.
Reject the FFA_SECONDARY_EP_REGISTER call after partition has
initialized.
Change-Id: I3ce723fc6cdde6f27709b664abfe2c7929e9d9b2
Signed-off-by: Olivier Deprez <olivier.deprez@arm.com>
diff --git a/inc/hf/arch/plat/ffa.h b/inc/hf/arch/plat/ffa.h
index f4f916a..fb830e4 100644
--- a/inc/hf/arch/plat/ffa.h
+++ b/inc/hf/arch/plat/ffa.h
@@ -250,3 +250,9 @@
size_t fdt_allocated_size,
const struct manifest_vm *manifest_vm,
struct mpool *ppool);
+
+/**
+ * Returns true if the FFA_SECONDARY_EP_REGISTER interface is supported at
+ * the virtual FF-A instance.
+ */
+bool plat_ffa_is_secondary_ep_register_supported(void);