|
Sound Open Firmware
|


Go to the source code of this file.
Data Structures | |
| struct | module_param |
| Module TLV parameters container - used for both config types. More... | |
| struct | module_resources |
| module resources block - used for module allocation records The allocations are recorded so that they can be automatically freed when the module unloads. More... | |
| struct | module_resource |
| module memory container - used for every memory allocated by module More... | |
| struct | module_processing_data |
| Processing data shared between particular module & module_adapter. More... | |
Macros | |
| #define | IS_PROCESSING_MODE_AUDIO_STREAM(mod) |
| #define | IS_PROCESSING_MODE_RAW_DATA(mod) |
| #define | IS_PROCESSING_MODE_SINK_SOURCE(mod) |
| #define | DECLARE_MODULE_ADAPTER(adapter, uuid, tr) |
| #define | SOF_MODULE_API_PRIVATE |
| #define | mod_balloc_align z_impl_mod_balloc_align |
| #define | mod_alloc_ext z_impl_mod_alloc_ext |
| #define | mod_free z_impl_mod_free |
| #define | mod_free_all z_impl_mod_free_all |
Enumerations | |
| enum | module_state { MODULE_DISABLED , MODULE_INITIALIZED , MODULE_IDLE , MODULE_PROCESSING } |
| Module-specific states. More... | |
| enum | mod_resource_type { MOD_RES_UNINITIALIZED = 0 , MOD_RES_HEAP , MOD_RES_BLOB_HANDLER , MOD_RES_FAST_GET } |
Functions | |
| int | module_load_config (struct comp_dev *dev, const void *cfg, size_t size) |
| int | module_init (struct processing_module *mod) |
| void * | z_impl_mod_balloc_align (struct processing_module *mod, size_t size, size_t alignment) |
| void | mod_resource_init (struct processing_module *mod) |
| void | mod_heap_info (struct processing_module *mod, size_t *size, uintptr_t *start) |
| void * | z_impl_mod_alloc_ext (struct processing_module *mod, uint32_t flags, size_t size, size_t alignment) |
| int | z_impl_mod_free (struct processing_module *mod, const void *ptr) |
| void | z_impl_mod_free_all (struct processing_module *mod) |
| static void * | mod_alloc_align (struct processing_module *mod, size_t size, size_t alignment) |
| Allocates aligned memory block for module. | |
| static void * | mod_balloc (struct processing_module *mod, size_t size) |
| static void * | mod_alloc (struct processing_module *mod, size_t size) |
| static void * | mod_zalloc (struct processing_module *mod, size_t size) |
| int | module_prepare (struct processing_module *mod, struct sof_source **sources, int num_of_sources, struct sof_sink **sinks, int num_of_sinks) |
| static bool | generic_module_is_ready_to_process (struct processing_module *mod, struct sof_source **sources, int num_of_sources, struct sof_sink **sinks, int num_of_sinks) |
| static bool | module_is_ready_to_process (struct processing_module *mod, struct sof_source **sources, int num_of_sources, struct sof_sink **sinks, int num_of_sinks) |
| int | module_process_sink_src (struct processing_module *mod, struct sof_source **sources, int num_of_sources, struct sof_sink **sinks, int num_of_sinks) |
| int | module_process_legacy (struct processing_module *mod, struct input_stream_buffer *input_buffers, int num_input_buffers, struct output_stream_buffer *output_buffers, int num_output_buffers) |
| int | module_reset (struct processing_module *mod) |
| int | module_free (struct processing_module *mod) |
| int | module_set_configuration (struct processing_module *mod, uint32_t config_id, enum module_cfg_fragment_position pos, size_t data_offset_size, const uint8_t *fragment, size_t fragment_size, uint8_t *response, size_t response_size) |
| int | module_bind (struct processing_module *mod, const struct bind_info *bind_data) |
| int | module_unbind (struct processing_module *mod, const struct bind_info *unbind_data) |
| struct comp_dev * | module_adapter_new (const struct comp_driver *drv, const struct comp_ipc_config *config, const void *spec) |
| struct comp_dev * | module_adapter_new_ext (const struct comp_driver *drv, const struct comp_ipc_config *config, const void *spec, void *mod_priv, struct userspace_context *user_ctx, const struct module_interface *ops) |
| int | module_adapter_prepare (struct comp_dev *dev) |
| int | module_adapter_params (struct comp_dev *dev, struct sof_ipc_stream_params *params) |
| int | module_adapter_copy (struct comp_dev *dev) |
| int | module_adapter_cmd (struct comp_dev *dev, int cmd, void *data, int max_data_size) |
| int | module_adapter_trigger (struct comp_dev *dev, int cmd) |
| void | module_adapter_free (struct comp_dev *dev) |
| int | module_adapter_reset (struct comp_dev *dev) |
| size_t | module_adapter_heap_usage (struct processing_module *mod, size_t *hwm) |
| int | module_set_large_config (struct comp_dev *dev, uint32_t param_id, bool first_block, bool last_block, uint32_t data_offset, const char *data) |
| int | module_get_large_config (struct comp_dev *dev, uint32_t param_id, bool first_block, bool last_block, uint32_t *data_offset, char *data) |
| int | module_adapter_get_attribute (struct comp_dev *dev, uint32_t type, void *value) |
| int | module_adapter_set_attribute (struct comp_dev *dev, uint32_t type, void *value) |
| int | module_adapter_bind (struct comp_dev *dev, const struct bind_info *bind_data) |
| int | module_adapter_unbind (struct comp_dev *dev, const struct bind_info *unbind_data) |
| uint64_t | module_adapter_get_total_data_processed (struct comp_dev *dev, uint32_t stream_no, bool input) |
| static int | module_process_endpoint (struct processing_module *mod, struct input_stream_buffer *input_buffers, int num_input_buffers, struct output_stream_buffer *output_buffers, int num_output_buffers) |
| int | module_adapter_get_hw_params (struct comp_dev *dev, struct sof_ipc_stream_params *params, int dir) |
| int | module_adapter_position (struct comp_dev *dev, struct sof_ipc_stream_posn *posn) |
| int | module_adapter_ts_config_op (struct comp_dev *dev) |
| int | module_adapter_ts_start_op (struct comp_dev *dev) |
| int | module_adapter_ts_stop_op (struct comp_dev *dev) |
| int | module_adapter_ts_get_op (struct comp_dev *dev, struct timestamp_data *tsd) |
| void | module_update_buffer_position (struct input_stream_buffer *input_buffers, struct output_stream_buffer *output_buffers, uint32_t frames) |
| static int | module_ext_init_decode (const struct comp_driver *drv, struct module_ext_init_data *ext_data, struct ipc_config_process *spec) |
| int | module_adapter_init_data (struct comp_dev *dev, struct module_config *dst, const struct comp_ipc_config *config, const void *spec) |
| void | module_adapter_reset_data (struct module_config *dst) |
| void | module_adapter_check_data (struct processing_module *mod, struct comp_dev *dev, struct comp_buffer *sink) |
| void | module_adapter_set_params (struct processing_module *mod, struct sof_ipc_stream_params *params) |
| int | module_adapter_set_state (struct processing_module *mod, struct comp_dev *dev, int cmd) |
| int | module_adapter_sink_src_prepare (struct comp_dev *dev) |
| uint32_t | module_get_deadline (struct processing_module *mod) |
| Get a deadline based on current LFT reported by all sinks it returns a value >= UINT32_MAX / 2 in case the deadline cannot be calculated: | |
| static uint32_t | module_get_lpt (struct processing_module *mod) |
| Get a Longest Processing Time estimation for the module, in us It is either. | |
| #define DECLARE_MODULE_ADAPTER | ( | adapter, | |
| uuid, | |||
| tr ) |
| #define IS_PROCESSING_MODE_AUDIO_STREAM | ( | mod | ) |
| #define IS_PROCESSING_MODE_RAW_DATA | ( | mod | ) |
| #define IS_PROCESSING_MODE_SINK_SOURCE | ( | mod | ) |
| #define mod_alloc_ext z_impl_mod_alloc_ext |
| #define mod_balloc_align z_impl_mod_balloc_align |
| #define mod_free z_impl_mod_free |
| #define mod_free_all z_impl_mod_free_all |
| #define SOF_MODULE_API_PRIVATE |
| enum mod_resource_type |
| enum module_state |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
Allocates aligned memory block for module.
| mod | Pointer to the module this memory block is allocated for. |
| size | Size in bytes. |
| alignment | Alignment in bytes. |
The allocated memory is automatically freed when the module is unloaded.
|
inlinestatic |
| void mod_heap_info | ( | struct processing_module * | mod, |
| size_t * | size, | ||
| uintptr_t * | start ) |
| void mod_resource_init | ( | struct processing_module * | mod | ) |
|
inlinestatic |
| void module_adapter_check_data | ( | struct processing_module * | mod, |
| struct comp_dev * | dev, | ||
| struct comp_buffer * | sink ) |
| int module_adapter_cmd | ( | struct comp_dev * | dev, |
| int | cmd, | ||
| void * | data, | ||
| int | max_data_size ) |
| int module_adapter_copy | ( | struct comp_dev * | dev | ) |
| void module_adapter_free | ( | struct comp_dev * | dev | ) |
| int module_adapter_get_attribute | ( | struct comp_dev * | dev, |
| uint32_t | type, | ||
| void * | value ) |
| int module_adapter_get_hw_params | ( | struct comp_dev * | dev, |
| struct sof_ipc_stream_params * | params, | ||
| int | dir ) |
| uint64_t module_adapter_get_total_data_processed | ( | struct comp_dev * | dev, |
| uint32_t | stream_no, | ||
| bool | input ) |
| size_t module_adapter_heap_usage | ( | struct processing_module * | mod, |
| size_t * | hwm ) |
| int module_adapter_init_data | ( | struct comp_dev * | dev, |
| struct module_config * | dst, | ||
| const struct comp_ipc_config * | config, | ||
| const void * | spec ) |
| struct comp_dev * module_adapter_new | ( | const struct comp_driver * | drv, |
| const struct comp_ipc_config * | config, | ||
| const void * | spec ) |
| struct comp_dev * module_adapter_new_ext | ( | const struct comp_driver * | drv, |
| const struct comp_ipc_config * | config, | ||
| const void * | spec, | ||
| void * | mod_priv, | ||
| struct userspace_context * | user_ctx, | ||
| const struct module_interface * | ops ) |
| int module_adapter_params | ( | struct comp_dev * | dev, |
| struct sof_ipc_stream_params * | params ) |
| int module_adapter_position | ( | struct comp_dev * | dev, |
| struct sof_ipc_stream_posn * | posn ) |
| int module_adapter_prepare | ( | struct comp_dev * | dev | ) |
| int module_adapter_reset | ( | struct comp_dev * | dev | ) |
| void module_adapter_reset_data | ( | struct module_config * | dst | ) |
| int module_adapter_set_attribute | ( | struct comp_dev * | dev, |
| uint32_t | type, | ||
| void * | value ) |
| void module_adapter_set_params | ( | struct processing_module * | mod, |
| struct sof_ipc_stream_params * | params ) |
| int module_adapter_set_state | ( | struct processing_module * | mod, |
| struct comp_dev * | dev, | ||
| int | cmd ) |
| int module_adapter_sink_src_prepare | ( | struct comp_dev * | dev | ) |
| int module_adapter_trigger | ( | struct comp_dev * | dev, |
| int | cmd ) |
| int module_adapter_ts_config_op | ( | struct comp_dev * | dev | ) |
| int module_adapter_ts_get_op | ( | struct comp_dev * | dev, |
| struct timestamp_data * | tsd ) |
| int module_adapter_ts_start_op | ( | struct comp_dev * | dev | ) |
| int module_adapter_ts_stop_op | ( | struct comp_dev * | dev | ) |
| int module_bind | ( | struct processing_module * | mod, |
| const struct bind_info * | bind_data ) |
|
inlinestatic |
| int module_free | ( | struct processing_module * | mod | ) |
| uint32_t module_get_deadline | ( | struct processing_module * | mod | ) |
Get a deadline based on current LFT reported by all sinks it returns a value >= UINT32_MAX / 2 in case the deadline cannot be calculated:
| int module_get_large_config | ( | struct comp_dev * | dev, |
| uint32_t | param_id, | ||
| bool | first_block, | ||
| bool | last_block, | ||
| uint32_t * | data_offset, | ||
| char * | data ) |
|
inlinestatic |
Get a Longest Processing Time estimation for the module, in us It is either.
| int module_init | ( | struct processing_module * | mod | ) |
|
inlinestatic |
| int module_load_config | ( | struct comp_dev * | dev, |
| const void * | cfg, | ||
| size_t | size ) |
| int module_prepare | ( | struct processing_module * | mod, |
| struct sof_source ** | sources, | ||
| int | num_of_sources, | ||
| struct sof_sink ** | sinks, | ||
| int | num_of_sinks ) |
|
inlinestatic |
| int module_process_legacy | ( | struct processing_module * | mod, |
| struct input_stream_buffer * | input_buffers, | ||
| int | num_input_buffers, | ||
| struct output_stream_buffer * | output_buffers, | ||
| int | num_output_buffers ) |
| int module_process_sink_src | ( | struct processing_module * | mod, |
| struct sof_source ** | sources, | ||
| int | num_of_sources, | ||
| struct sof_sink ** | sinks, | ||
| int | num_of_sinks ) |
| int module_reset | ( | struct processing_module * | mod | ) |
| int module_set_configuration | ( | struct processing_module * | mod, |
| uint32_t | config_id, | ||
| enum module_cfg_fragment_position | pos, | ||
| size_t | data_offset_size, | ||
| const uint8_t * | fragment, | ||
| size_t | fragment_size, | ||
| uint8_t * | response, | ||
| size_t | response_size ) |
| int module_set_large_config | ( | struct comp_dev * | dev, |
| uint32_t | param_id, | ||
| bool | first_block, | ||
| bool | last_block, | ||
| uint32_t | data_offset, | ||
| const char * | data ) |
| int module_unbind | ( | struct processing_module * | mod, |
| const struct bind_info * | unbind_data ) |
| void module_update_buffer_position | ( | struct input_stream_buffer * | input_buffers, |
| struct output_stream_buffer * | output_buffers, | ||
| uint32_t | frames ) |
| void * z_impl_mod_alloc_ext | ( | struct processing_module * | mod, |
| uint32_t | flags, | ||
| size_t | size, | ||
| size_t | alignment ) |
| void * z_impl_mod_balloc_align | ( | struct processing_module * | mod, |
| size_t | size, | ||
| size_t | alignment ) |
| int z_impl_mod_free | ( | struct processing_module * | mod, |
| const void * | ptr ) |
| void z_impl_mod_free_all | ( | struct processing_module * | mod | ) |