My Project
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
Functions | Variables
dispatcher_task.c File Reference
#include <sw_types.h>
#include <sw_debug.h>
#include <sw_string_functions.h>
#include <sw_mem_functions.h>
#include <cpu_data.h>
#include <sw_cpu_helper.h>
#include <global.h>
#include <task.h>
#include <sw_buddy.h>
#include <otz_common.h>
#include <otz_id.h>
#include <smc_id.h>
#include <cpu.h>
#include <dispatcher_task.h>
#include <secure_api.h>
#include <secure_exception.h>


void dispatch_task (long cur_task_id)
 Dispatcher task entry point. More...
void set_secure_api_ret (int ret_val)
 Task return value notification. More...
int dispatch_task_init (sa_config_t *psa_config)
 Dispatcher task init. More...
int dispatch_task_exit (void *data)
 Dispatcher task exit. More...


struct dispatch_globalg_dispatch_data

Function Documentation

void dispatch_task ( long  cur_task_id)

Dispatcher task entry point.

Dispatcher task exit.

This task will process the smc commands and helps in creating the service tasks and calls the service task functions.

  1. On arrival of API command invocation "valid params flag" got set. Based on the flag, it process the command by invoking the appropriate task.
  2. At the completion of processing, the corresponding task sets the return value of the command result in the dispatcher private data.
  3. Based on the result and the source, it returns to non-secure world or originated task in case of IPI.
cur_task_id- Dispatcher task identifier
int dispatch_task_exit ( void *  data)

Dispatcher task exit.

Exit function for the dispatcher task.

This function gets called before the task deletion

dataPrivate data which need to be freed.
otz_return_t: OTZ_OK
int dispatch_task_init ( sa_config_t psa_config)

Dispatcher task init.

This function initializes dispatcher task parameters and its get called before the task creation

psa_configConfiguration parameter for the task
otz_return_t: OTZ_OK
void set_secure_api_ret ( int  ret_val)

Task return value notification.

This function gets called after the API completion to notify the dispatcher task and it also sets the return value of API.

ret_valAPI return value

Variable Documentation

struct dispatch_global* g_dispatch_data