TF-M Reference Manual  1.2.0
TrustedFirmware-M
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
tfm_spe_mailbox.c File Reference
#include "cmsis_compiler.h"
#include "psa/error.h"
#include "tfm_core_utils.h"
#include "utilities.h"
#include "tfm_spe_mailbox.h"
#include "tfm_rpc.h"
Include dependency graph for tfm_spe_mailbox.c:

Go to the source code of this file.

Macros

#define NS_CALLER_FLAG   (true)
 

Functions

__STATIC_INLINE void set_spe_queue_empty_status (uint8_t idx)
 
__STATIC_INLINE void clear_spe_queue_empty_status (uint8_t idx)
 
__STATIC_INLINE bool get_spe_queue_empty_status (uint8_t idx)
 
__STATIC_INLINE
mailbox_queue_status_t 
get_nspe_queue_pend_status (const struct ns_mailbox_queue_t *ns_queue)
 
__STATIC_INLINE void set_nspe_queue_replied_status (struct ns_mailbox_queue_t *ns_queue, mailbox_queue_status_t mask)
 
__STATIC_INLINE void clear_nspe_queue_pend_status (struct ns_mailbox_queue_t *ns_queue, mailbox_queue_status_t mask)
 
__STATIC_INLINE int32_t get_spe_mailbox_msg_handle (uint8_t idx, mailbox_msg_handle_t *handle)
 
__STATIC_INLINE int32_t get_spe_mailbox_msg_idx (mailbox_msg_handle_t handle, uint8_t *idx)
 
__STATIC_INLINE struct
mailbox_reply_t
get_nspe_reply_addr (uint8_t idx)
 
__STATIC_INLINE int32_t check_mailbox_msg (const struct mailbox_msg_t *msg)
 
int32_t tfm_mailbox_handle_msg (void)
 Handle mailbox message(s) from NSPE. More...
 
int32_t tfm_mailbox_reply_msg (mailbox_msg_handle_t handle, int32_t reply)
 Return PSA client call return result to NSPE. More...
 
int32_t tfm_mailbox_init (void)
 SPE mailbox initialization. More...
 

Macro Definition Documentation

#define NS_CALLER_FLAG   (true)

Definition at line 16 of file tfm_spe_mailbox.c.

Function Documentation

__STATIC_INLINE int32_t check_mailbox_msg ( const struct mailbox_msg_t msg)

Definition at line 173 of file tfm_spe_mailbox.c.

Here is the caller graph for this function:

__STATIC_INLINE void clear_nspe_queue_pend_status ( struct ns_mailbox_queue_t ns_queue,
mailbox_queue_status_t  mask 
)

Definition at line 100 of file tfm_spe_mailbox.c.

Here is the caller graph for this function:

__STATIC_INLINE void clear_spe_queue_empty_status ( uint8_t  idx)

Definition at line 70 of file tfm_spe_mailbox.c.

Here is the caller graph for this function:

__STATIC_INLINE mailbox_queue_status_t get_nspe_queue_pend_status ( const struct ns_mailbox_queue_t ns_queue)

Definition at line 87 of file tfm_spe_mailbox.c.

Here is the caller graph for this function:

__STATIC_INLINE struct mailbox_reply_t* get_nspe_reply_addr ( uint8_t  idx)

Definition at line 142 of file tfm_spe_mailbox.c.

__STATIC_INLINE int32_t get_spe_mailbox_msg_handle ( uint8_t  idx,
mailbox_msg_handle_t handle 
)

Definition at line 107 of file tfm_spe_mailbox.c.

Here is the caller graph for this function:

__STATIC_INLINE int32_t get_spe_mailbox_msg_idx ( mailbox_msg_handle_t  handle,
uint8_t *  idx 
)

Definition at line 119 of file tfm_spe_mailbox.c.

Here is the caller graph for this function:

__STATIC_INLINE bool get_spe_queue_empty_status ( uint8_t  idx)

Definition at line 77 of file tfm_spe_mailbox.c.

Here is the caller graph for this function:

__STATIC_INLINE void set_nspe_queue_replied_status ( struct ns_mailbox_queue_t ns_queue,
mailbox_queue_status_t  mask 
)

Definition at line 93 of file tfm_spe_mailbox.c.

Here is the caller graph for this function:

__STATIC_INLINE void set_spe_queue_empty_status ( uint8_t  idx)

Definition at line 63 of file tfm_spe_mailbox.c.

int32_t tfm_mailbox_handle_msg ( void  )

Handle mailbox message(s) from NSPE.

Return values
MAILBOX_SUCCESSSuccessfully get PSA client call return result.
Otherreturn code Operation failed with an error code.

Definition at line 183 of file tfm_spe_mailbox.c.

Here is the call graph for this function:

int32_t tfm_mailbox_init ( void  )

SPE mailbox initialization.

Return values
MAILBOX_SUCCESSOperation succeeded.
Otherreturn code Operation failed with an error code.

Definition at line 376 of file tfm_spe_mailbox.c.

Here is the call graph for this function:

Here is the caller graph for this function:

int32_t tfm_mailbox_reply_msg ( mailbox_msg_handle_t  handle,
int32_t  reply 
)

Return PSA client call return result to NSPE.

Parameters
[in]handleThe handle to the mailbox message
[in]replyPSA client call return result to be written to NSPE.
Return values
MAILBOX_SUCCESSOperation succeeded.
Otherreturn code Operation failed with an error code.

Definition at line 294 of file tfm_spe_mailbox.c.

Here is the call graph for this function: