FreeRTOS port on GAP8/RISC-V
|
Functions | |
pi_task_t * | __pi_task_block (pi_task_t *task) |
Prepare a blocking event task. More... | |
pi_task_t * | __pi_task_callback (pi_task_t *callback_task, void(*func)(void *), void *arg) |
Prepare an event task with callback. More... | |
void | __pi_task_wait_on (pi_task_t *task) |
Wait on an event task. More... | |
void | __pi_task_push (pi_task_t *task) |
Push an event task. More... | |
void | __pi_task_destroy (pi_task_t *task) |
Delete an event task. More... | |
void | pi_task_delayed_fifo_enqueue (struct pi_task *task, uint32_t delay_us) |
Enqueue a delayed task. More... | |
static pi_task_t * | pi_task_block (pi_task_t *task) |
static pi_task_t * | pi_task_callback (pi_task_t *task, void(*callback)(void *), void *arg) |
static void | pi_task_wait_on (pi_task_t *task) |
static void | pi_task_push (pi_task_t *task) |
static void | pi_task_destroy (pi_task_t *task) |
static void | pi_task_timeout_set (pi_task_t *task, uint32_t timeout_us) |
static int32_t | pi_task_transfer_end_result_get (pi_task_t *task) |
static void | pi_task_timeout_callback_set (pi_task_t *task, pi_callback_func_t func, void *arg) |
This function initializes an instance of event task. A semaphore will be initialized.
task | Pointer to event task. |
References pi_task_t::core_id, pi_task_t::done, pi_task_t::id, pi_task_t::next, pi_sem_init(), pi_task_t::timeout, and pi_task_t::wait_on.
Referenced by pi_task_block().
This function initializes an instance of event task. This event task executes the callback given in argument.
callback_task | Pointer to event task. |
func | Callback function. |
arg | Callback function argument. |
Referenced by pi_task_callback().
void __pi_task_destroy | ( | pi_task_t * | task | ) |
This function removes an event task. It will delete the semaphore if it has been allocated.
task | Pointer to event task. |
References hal_compiler_barrier(), pi_sem_deinit(), and pi_task_t::wait_on.
Referenced by __pi_task_wait_on(), and pi_task_destroy().
void __pi_task_push | ( | pi_task_t * | task | ) |
This function is used to push an event task to the event kernel.
task | Pointer to event task. |
References disable_irq(), pmsis_event_get_default_scheduler(), pmsis_event_push(), and restore_irq().
Referenced by pi_task_push().
void __pi_task_wait_on | ( | pi_task_t * | task | ) |
This function allows to wait on an event task until the event occurs.
task | Pointer to event task. |
References __pi_task_destroy(), DEBUG_PRINTF, pi_task_t::done, hal_compiler_barrier(), pi_sem_take(), and pi_task_t::wait_on.
Referenced by pi_task_wait_on().
References __pi_task_block().
Referenced by __pi_pmu_regulator_state_change(), pi_aes_decrypt(), pi_aes_encrypt(), pi_asrc_convert(), pi_cluster_send_task_to_cl(), pi_cpi_capture(), pi_dmacpy_copy(), pi_ffc_convert(), pi_hyper_read(), pi_hyper_read_2d(), pi_hyper_write(), pi_hyper_write_2d(), pi_i2c_detect(), pi_i2c_read(), pi_i2c_read_timeout(), pi_i2c_write(), pi_i2c_write_read(), pi_i2c_write_timeout(), pi_i2s_channel_read(), pi_i2s_channel_write(), pi_i2s_read(), pi_i2s_write(), pi_octospi_read(), pi_octospi_read_2d(), pi_octospi_write(), pi_octospi_write_2d(), pi_spi_copy(), pi_spi_copy_2d(), pi_spi_receive(), pi_spi_receive_with_ucode(), pi_spi_send(), pi_spi_send_with_ucode(), pi_spi_transfer(), pi_uart_read(), pi_uart_read_byte(), pi_uart_read_timeout(), pi_uart_write(), pi_uart_write_byte(), pi_uart_write_timeout(), and pi_udma_datamove_copy().
|
inlinestatic |
References __pi_task_callback().
Referenced by __pi_rtc_handler(), and pi_task_callback_no_mutex().
void pi_task_delayed_fifo_enqueue | ( | struct pi_task * | task, |
uint32_t | delay_us | ||
) |
This function is used to pushed a delayed event task to event kernel.
task | Pointer to event task. |
delay_us | Delay to wait for execution of the event task. |
References pi_task_delayed_s::fifo_head, pi_task_delayed_s::fifo_tail, and portTICK_PERIOD_MS.
Referenced by pi_task_push_delayed_us().
|
inlinestatic |
References __pi_task_destroy().
Referenced by pi_cluster_send_task_to_cl(), pi_cpi_capture(), pi_dmacpy_copy(), pi_ffc_convert(), pi_hyper_read(), pi_hyper_read_2d(), pi_hyper_write(), pi_hyper_write_2d(), pi_i2c_detect(), pi_i2c_read(), pi_i2c_read_timeout(), pi_i2c_write(), pi_i2c_write_read(), pi_i2c_write_timeout(), pi_spi_copy(), pi_spi_copy_2d(), pi_spi_receive(), pi_spi_receive_with_ucode(), pi_spi_send(), pi_spi_send_with_ucode(), pi_spi_transfer(), pi_uart_read(), pi_uart_read_byte(), pi_uart_read_timeout(), pi_uart_write(), pi_uart_write_byte(), pi_uart_write_timeout(), and pi_udma_datamove_copy().
|
inlinestatic |
|
inlinestatic |
References pi_task_t::arg.
Referenced by __pi_i2c_timeout_config_set(), and __pi_uart_copy_exec().
|
inlinestatic |
References pi_task_t::timeout.
Referenced by pi_i2c_read_timeout(), pi_i2c_write_timeout(), pi_uart_read_timeout(), and pi_uart_write_timeout().
|
inlinestatic |
References pi_task_t::arg.
Referenced by pi_i2c_read_timeout(), pi_i2c_write_timeout(), pi_uart_read_timeout(), and pi_uart_write_timeout().
|
inlinestatic |
References __pi_task_wait_on().
Referenced by __pi_pmu_regulator_state_change(), pi_aes_decrypt(), pi_aes_encrypt(), pi_asrc_convert(), pi_cluster_send_task_to_cl(), pi_cpi_capture(), pi_dmacpy_copy(), pi_ffc_convert(), pi_hyper_read(), pi_hyper_read_2d(), pi_hyper_write(), pi_hyper_write_2d(), pi_i2c_detect(), pi_i2c_read(), pi_i2c_read_timeout(), pi_i2c_write(), pi_i2c_write_read(), pi_i2c_write_timeout(), pi_i2s_channel_read(), pi_i2s_channel_write(), pi_i2s_read(), pi_i2s_write(), pi_octospi_read(), pi_octospi_read_2d(), pi_octospi_write(), pi_octospi_write_2d(), pi_spi_copy(), pi_spi_copy_2d(), pi_spi_receive(), pi_spi_receive_with_ucode(), pi_spi_send(), pi_spi_send_with_ucode(), pi_spi_transfer(), pi_uart_read(), pi_uart_read_byte(), pi_uart_read_timeout(), pi_uart_write(), pi_uart_write_byte(), pi_uart_write_timeout(), and pi_udma_datamove_copy().