Core: Change buffer address type to const void * in memory access check

Change buffer base address type to const void * in
tfm_memory_check() and tfm_core_has_write_access_to_region().
Remove unnecessary explicit type casts.

Change-Id: I59d03871d35837c1deebe095aa88c255f120c111
Signed-off-by: David Hu <david.hu@arm.com>
diff --git a/secure_fw/spm/spm_api.h b/secure_fw/spm/spm_api.h
index 7f95339..02c5dbf 100644
--- a/secure_fw/spm/spm_api.h
+++ b/secure_fw/spm/spm_api.h
@@ -638,7 +638,7 @@
  * \retval IPC_ERROR_BAD_PARAMETERS  Bad parameters input
  * \retval IPC_ERROR_MEMORY_CHECK    Check failed
  */
-int32_t tfm_memory_check(void *buffer, size_t len, int32_t ns_caller,
+int32_t tfm_memory_check(const void *buffer, size_t len, int32_t ns_caller,
                          enum tfm_memory_access_e access,
                          uint32_t privileged);