Core: Apply core memory functions

- Use core memory functions instead of standard C
  runtime library for core and spm.

Change-Id: Iad8037c77676a5418d9fec3626bb51dd3cead425
Signed-off-by: Mingyang Sun <mingyang.sun@arm.com>
diff --git a/secure_fw/spm/spm_api_ipc.c b/secure_fw/spm/spm_api_ipc.c
index 2b701ed..70980f2 100644
--- a/secure_fw/spm/spm_api_ipc.c
+++ b/secure_fw/spm/spm_api_ipc.c
@@ -27,6 +27,7 @@
 #include "region_defs.h"
 #include "tfm_nspm.h"
 #include "tfm_memory_utils.h"
+#include "tfm_core_utils.h"
 
 #include "secure_fw/services/tfm_service_list.inc"
 
@@ -298,7 +299,7 @@
     TFM_ASSERT(in_len + out_len <= PSA_MAX_IOVEC);
 
     /* Clear message buffer before using it */
-    tfm_memset(msg, 0, sizeof(struct tfm_msg_body_t));
+    tfm_core_util_memset(msg, 0, sizeof(struct tfm_msg_body_t));
 
     tfm_event_init(&msg->ack_evnt);
     msg->magic = TFM_MSG_MAGIC;