aboutsummaryrefslogtreecommitdiff
path: root/secure_fw/include
diff options
context:
space:
mode:
authorKevin Peng <kevin.peng@arm.com>2021-05-08 13:42:56 +0800
committerKevin Peng <kevin.peng@arm.com>2021-05-20 04:03:39 +0200
commitfc7b7717aebe7c5d00ba581bb9968af23fd8279e (patch)
tree3098fcc59f2e3a611e458640458ba064d158bd61 /secure_fw/include
parent211f5d6a6b1d766eaa1dc1deba32304e91665b5b (diff)
downloadtrusted-firmware-m-fc7b7717aebe7c5d00ba581bb9968af23fd8279e.tar.gz
SPM: Convert SVC number to uint8_t
SVC number encoded in SVC instruction is 8-bit long. Currently it relies on the short-enum compiler option to have a 8-bit long SVC number type. This patch converts the enum to uint8_t for SVC number and divids the SVC numbers to two parts for IPC model: - 0x0 ~ 0x7F for SVC calls only allowed from Thread Mode - 0x80 ~ 0xFF for SVC calls only allowed from interrupt handling Note: For library model, the SVC numbers have no restrictions. Since the requirements for SVC number assignment are different, this patch also split the SVC number header for IPC and Library models. Change-Id: I0fb4dd110be6bab05e1c4b9a8fc55e1b8bfbc0eb Signed-off-by: Kevin Peng <kevin.peng@arm.com>
Diffstat (limited to 'secure_fw/include')
-rw-r--r--secure_fw/include/tfm/tfm_core_svc.h60
1 files changed, 0 insertions, 60 deletions
diff --git a/secure_fw/include/tfm/tfm_core_svc.h b/secure_fw/include/tfm/tfm_core_svc.h
deleted file mode 100644
index 74ad157fac..0000000000
--- a/secure_fw/include/tfm/tfm_core_svc.h
+++ /dev/null
@@ -1,60 +0,0 @@
-/*
- * Copyright (c) 2017-2021, Arm Limited. All rights reserved.
- *
- * SPDX-License-Identifier: BSD-3-Clause
- *
- */
-
-#ifndef __TFM_CORE_SVC_H__
-#define __TFM_CORE_SVC_H__
-
-#include "tfm_hal_device_header.h"
-#include "tfm_spm_log.h"
-
-typedef enum {
- TFM_SVC_SFN_REQUEST = 0,
- TFM_SVC_SFN_RETURN,
- TFM_SVC_GET_CALLER_CLIENT_ID,
- TFM_SVC_SPM_REQUEST,
- TFM_SVC_GET_BOOT_DATA,
- TFM_SVC_DEPRIV_REQ,
- TFM_SVC_DEPRIV_RET,
-#ifndef TFM_PSA_API
- TFM_SVC_ENABLE_IRQ,
- TFM_SVC_DISABLE_IRQ,
-#endif
- TFM_SVC_PSA_WAIT,
- TFM_SVC_PSA_EOI,
- TFM_SVC_HANDLER_MODE,
-#ifdef TFM_PSA_API
- /* PSA Client SVC */
- TFM_SVC_PSA_FRAMEWORK_VERSION,
- TFM_SVC_PSA_VERSION,
- TFM_SVC_PSA_CONNECT,
- TFM_SVC_PSA_CALL,
- TFM_SVC_PSA_CLOSE,
- /* PSA Service SVC */
- TFM_SVC_PSA_GET,
- TFM_SVC_PSA_SET_RHANDLE,
- TFM_SVC_PSA_READ,
- TFM_SVC_PSA_SKIP,
- TFM_SVC_PSA_WRITE,
- TFM_SVC_PSA_REPLY,
- TFM_SVC_PSA_NOTIFY,
- TFM_SVC_PSA_CLEAR,
- TFM_SVC_PSA_PANIC,
- TFM_SVC_PSA_LIFECYCLE,
-#endif
-#if (TFM_SPM_LOG_LEVEL > TFM_SPM_LOG_LEVEL_SILENCE)
- TFM_SVC_OUTPUT_UNPRIV_STRING,
-#endif
- /* Secure Partition API for interrupt control */
- TFM_SVC_PSA_IRQ_ENABLE,
- TFM_SVC_PSA_IRQ_DISABLE,
-
- TFM_SVC_PLATFORM_BASE = 50 /* leave room for additional Core handlers */
-} tfm_svc_number_t;
-
-#define SVC(code) __ASM volatile("svc %0" : : "I" (code))
-
-#endif /* __TFM_CORE_SVC_H__ */