Core: Merge IPC model SP data into library model

Merges the necessary secure partition data for IPC model into library
model. Prepare a common partition data structure for optimization.

Change-Id: I88939faa337588f14f351c284e5a9d625af37fa5
Signed-off-by: Edison Ai <edison.ai@arm.com>
diff --git a/secure_fw/spm/spm_db.h b/secure_fw/spm/spm_db.h
index 8b1a00b..7b74aba 100644
--- a/secure_fw/spm/spm_db.h
+++ b/secure_fw/spm/spm_db.h
@@ -39,6 +39,7 @@
  * phase.
  */
 struct spm_partition_static_data_t {
+    int32_t index;                      /* Partition index */
     uint32_t partition_id;
     uint32_t partition_flags;
     uint32_t partition_priority;
@@ -64,7 +65,9 @@
 struct spm_partition_db_t {
     uint32_t is_init;
     uint32_t partition_count;
+#ifndef TFM_PSA_API
     uint32_t running_partition_idx;
+#endif /* !defined(TFM_PSA_API) */
     struct spm_partition_desc_t *partitions;
 };