| #
5a5d1173 |
| 01-Sep-2023 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: add release_state to struct ts_ops
Adds the optional function pointer release_state() to struct ts_ops. This callback will be called when a TA has panicked and as many resources as possible ne
core: add release_state to struct ts_ops
Adds the optional function pointer release_state() to struct ts_ops. This callback will be called when a TA has panicked and as many resources as possible need to be released early. release_state() is a subset of the destroy() callback. When the destroy() is called eventually it will free the entire state of the TA regardless if release_state() has been called before or not. This allows freeing resources while there are still open sessions to the TA.
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org> Acked-by: Etienne Carriere <etienne.carriere@foss.st.com>
show more ...
|
| #
ab5363c6 |
| 19-Dec-2022 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: introduce scall layer from svc parts
Introduces a scall layer by renaming various thread_svc* names and _*handle_svc() functions and function pointers as a first step in doing architecture neu
core: introduce scall layer from svc parts
Introduces a scall layer by renaming various thread_svc* names and _*handle_svc() functions and function pointers as a first step in doing architecture neutral syscall processing.
The name scall is used instead of syscall since the syscall_ prefix is reserved for the functions implementing the actual syscall. While scall is the infrastructure used to reach the syscall functions.
No files are renamed and removed at this stage. This patch doesn't change any behaviour.
Reviewed-by: Etienne Carriere <etienne.carriere@linaro.org> Acked-by: Jerome Forissier <jerome.forissier@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| #
cb94c145 |
| 21-Oct-2022 |
Weizhao Jiang <weizhaoj@amazon.com> |
core: implement a method to dump user TA runtime status
This patch is to dump user TA runtime status for debug purposes. The change includes: 1. Add new command (STATS_CMD_TA_STATS) in the stats PTA
core: implement a method to dump user TA runtime status
This patch is to dump user TA runtime status for debug purposes. The change includes: 1. Add new command (STATS_CMD_TA_STATS) in the stats PTA. 2. Add tee_ta_dump_stats() to scan all ongoing TA instance and sessions and snapshot their status. 3. Add new function: entry_dump_memstats() to __utee_entry() to get TA heap statistics. 4. Add new compile option (CFG_TA_STATS, default n) to enable this feature.
Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org> Reviewed-by: Etienne Carriere <etienne.carriere@linaro.org> Tested-by: Weizhao Jiang <weizhaoj@amazon.com> Signed-off-by: Weizhao Jiang <weizhaoj@amazon.com> [jf: edit commit message] Signed-off-by: Jerome Forissier <jerome.forissier@linaro.org>
show more ...
|
| #
0a971fdb |
| 11-Dec-2020 |
Balint Dobszay <balint.dobszay@arm.com> |
core: invoke SVC handler through struct ts_session
Store the current SVC handler function pointer in struct ts_session, and invoke the handler through this. Enables changing the SVC handler for a se
core: invoke SVC handler through struct ts_session
Store the current SVC handler function pointer in struct ts_session, and invoke the handler through this. Enables changing the SVC handler for a session without modifying the ts_ops defined in the session context.
Acked-by: Etienne Carriere <etienne.carriere@linaro.org> Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org> Reviewed-by: Jerome Forissier <jerome@forissier.org> Signed-off-by: Balint Dobszay <balint.dobszay@arm.com>
show more ...
|
| #
36bb435f |
| 11-Dec-2020 |
Balint Dobszay <balint.dobszay@arm.com> |
core: move user_ctx field to struct ts_session
The user_ctx field in struct tee_ta_session is used by PTAs to keep track of session specific information. Move it to struct ts_session to make it gene
core: move user_ctx field to struct ts_session
The user_ctx field in struct tee_ta_session is used by PTAs to keep track of session specific information. Move it to struct ts_session to make it generic and reachable for all sessions, not just TAs. This enables extracting ldelf related code from system PTA.
Acked-by: Etienne Carriere <etienne.carriere@linaro.org> Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org> Reviewed-by: Jerome Forissier <jerome@forissier.org> Signed-off-by: Balint Dobszay <balint.dobszay@arm.com>
show more ...
|
| #
f802ab52 |
| 01-Sep-2020 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: add gprof_set_status() to struct ts_ops
Adds gprof_set_status() to struct ts_ops to allow generic gprof handling in thread_svc_handler().
Reviewed-by: Etienne Carriere <etienne.carriere@linar
core: add gprof_set_status() to struct ts_ops
Adds gprof_set_status() to struct ts_ops to allow generic gprof handling in thread_svc_handler().
Reviewed-by: Etienne Carriere <etienne.carriere@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| #
82061b8d |
| 01-Sep-2020 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: store TA params in session struct
Stores TA params and error origin in struct tee_ta_session instead of passing them as parameters to enter_open_session() and enter_invoke_cmd() in struct ts_o
core: store TA params in session struct
Stores TA params and error origin in struct tee_ta_session instead of passing them as parameters to enter_open_session() and enter_invoke_cmd() in struct ts_ops. This makes struct ts_ops less TA specific.
Reviewed-by: Etienne Carriere <etienne.carriere@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| #
ab242291 |
| 01-Sep-2020 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: add struct ts_ops
Adds struct ts_ops replacing the previous struct tee_ta_ops.
Reviewed-by: Etienne Carriere <etienne.carriere@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro
core: add struct ts_ops
Adds struct ts_ops replacing the previous struct tee_ta_ops.
Reviewed-by: Etienne Carriere <etienne.carriere@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| #
3560d990 |
| 01-Sep-2020 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: add generic struct ts_ctx
Adds the generic struct ts_ctx to be used instead of struct tee_ta_ctx where generic context operations are performed.
struct tee_ta_ctx adds a field with struct ts_
core: add generic struct ts_ctx
Adds the generic struct ts_ctx to be used instead of struct tee_ta_ctx where generic context operations are performed.
struct tee_ta_ctx adds a field with struct ts_ctx for conversion to struct ts_ctx where needed.
The struct ts_session is updated to keep a pointer to a struct ts_ctx instead of the previous struct tee_ta_ctx.
Reviewed-by: Etienne Carriere <etienne.carriere@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| #
00b3b9a2 |
| 31-Aug-2020 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: add generic struct ts_session
As a step in making room for Secure Partitions (SPs) running at S-EL0 add a Trusted Service (TS) abstraction. Both TAs and SPs is a TS.
Adds the generic struct t
core: add generic struct ts_session
As a step in making room for Secure Partitions (SPs) running at S-EL0 add a Trusted Service (TS) abstraction. Both TAs and SPs is a TS.
Adds the generic struct ts_session. All future sessions structs (currently only struct tee_ta_session exists) should add this struct to allow generic session operations.
With this struct comes new functions replacing previous struct tee_ta_session oriented functions. The following functions are replaced as: tee_ta_get_current_session() -> ts_get_current_session() tee_ta_push_current_session() -> ts_push_current_session() tee_ta_pop_current_session() -> ts_pop_current_session() tee_ta_get_calling_session() -> ts_get_calling_session()
ts_get_current_session() is changed compared to its predecessor to panic() in case of failure to return a valid pointer.
A new function ts_get_current_session_may_fail() is added to handle an eventual case where a return NULL session may be handled.
Reviewed-by: Etienne Carriere <etienne.carriere@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|