|
Sound Open Firmware
|
Data Structures | |
| struct | bind_info |
| struct | comp_ops |
| Audio component operations. More... | |
| struct | comp_driver |
| Audio component base driver "class". More... | |
| struct | comp_driver_info |
| Holds constant pointer to component driver. More... | |
| struct | comp_ipc_config |
| Audio component base configuration from IPC at creation. More... | |
| struct | comp_perf_data |
| struct | comp_dev |
| Audio component base device "class". More... | |
Macros | |
| #define | COMP_PROCESSING_DOMAIN_LL 0 |
| #define | COMP_PROCESSING_DOMAIN_DP 1 |
| #define | comp_dev_for_each_producer(_dev, _producer) |
| #define | comp_dev_for_each_producer_safe(_dev, _producer, _next_producer) |
| #define | comp_dev_for_each_consumer(_dev, _consumer) |
| #define | comp_dev_for_each_consumer_safe(_dev, _consumer, _next_consumer) |
Enumerations | |
| enum | comp_endpoint_type { COMP_ENDPOINT_HOST , COMP_ENDPOINT_DAI , COMP_ENDPOINT_NODE } |
| Type of endpoint this component is connected to in a pipeline. More... | |
| enum | comp_copy_type { COMP_COPY_INVALID = -1 , COMP_COPY_NORMAL = 0 , COMP_COPY_BLOCKING , COMP_COPY_ONE_SHOT } |
| Type of next dma copy mode, changed on runtime. More... | |
| enum | bind_type { COMP_BIND_TYPE_SOURCE , COMP_BIND_TYPE_SINK } |
Functions | |
| static struct comp_buffer * | comp_dev_get_first_data_producer (struct comp_dev *component) |
| Get a pointer to the first comp_buffer object providing data to the component The function will return NULL if there's no data provider. | |
| static struct comp_buffer * | comp_dev_get_next_data_producer (struct comp_dev *component, struct comp_buffer *producer) |
| Get a pointer to the next comp_buffer object providing data to the component The function will return NULL if there're no more data providers _save version also checks if producer != NULL. | |
| static struct comp_buffer * | comp_dev_get_next_data_producer_safe (struct comp_dev *component, struct comp_buffer *producer) |
| static struct comp_buffer * | comp_dev_get_first_data_consumer (struct comp_dev *component) |
| Get a pointer to the first comp_buffer object receiving data from the component The function will return NULL if there's no data consumers. | |
| static struct comp_buffer * | comp_dev_get_next_data_consumer (struct comp_dev *component, struct comp_buffer *consumer) |
| Get a pointer to the next comp_buffer object receiving data from the component The function will return NULL if there're no more data consumers _safe version also checks if consumer is != NULL. | |
| static struct comp_buffer * | comp_dev_get_next_data_consumer_safe (struct comp_dev *component, struct comp_buffer *consumer) |
Standard Component Stream Commands | |
TODO: use IPC versions after 1.1 Most component stream commands match one-to-one IPC stream trigger commands. However we add two PRE_ and two POST_ commands to the set. They are issued internally without matching IPC commands. A single START IPC command is translated into a sequence of PRE_START and START component commands, etc. POST_* commands aren't used so far. | |
| enum | { COMP_TRIGGER_STOP , COMP_TRIGGER_START , COMP_TRIGGER_PAUSE , COMP_TRIGGER_RELEASE , COMP_TRIGGER_RESET , COMP_TRIGGER_PREPARE , COMP_TRIGGER_XRUN , COMP_TRIGGER_PRE_START , COMP_TRIGGER_PRE_RELEASE , COMP_TRIGGER_POST_STOP , COMP_TRIGGER_POST_PAUSE , COMP_TRIGGER_NO_ACTION } |
Audio Component States | |
| #define | COMP_STATE_NOT_EXIST 0 |
| Component does not exist. | |
| #define | COMP_STATE_INIT 1 |
| Component being initialised. | |
| #define | COMP_STATE_READY 2 |
| Component inactive, but ready. | |
| #define | COMP_STATE_SUSPEND 3 |
| Component suspended. | |
| #define | COMP_STATE_PREPARE 4 |
| Component prepared. | |
| #define | COMP_STATE_PAUSED 5 |
| Component paused. | |
| #define | COMP_STATE_ACTIVE 6 |
| Component active. | |
| #define | COMP_STATE_PRE_ACTIVE 7 |
| Component after early initialisation. | |
Standard Component Control Commands | |
"Value" commands are standard ones, known to the driver while "Data" commands are opaque blobs transferred by the driver. TODO: see also: ref to ipc data structures for commands. | |
| #define | COMP_CMD_SET_VALUE 100 |
| Set value to component. | |
| #define | COMP_CMD_GET_VALUE 101 |
| Get value from component. | |
| #define | COMP_CMD_SET_DATA 102 |
| Set data to component. | |
| #define | COMP_CMD_GET_DATA 103 |
| Get data from component. | |
MMAP IPC status | |
| #define | COMP_CMD_IPC_MMAP_RPOS 200 |
| Host read position. | |
| #define | COMP_CMD_IPC_MMAP_PPOS 201 |
| DAI presentation position. | |
| #define | COMP_CMD_IPC_MMAP_VOL(chan) |
| Volume. | |
Component status | |
| #define | COMP_STATUS_STATE_ALREADY_SET 1 |
| Comp set state status. | |
Component attribute types | |
| #define | COMP_ATTR_COPY_TYPE 0 |
| Comp copy type attribute. | |
| #define | COMP_ATTR_HOST_BUFFER 1 |
| Comp host buffer attribute. | |
| #define | COMP_ATTR_COPY_DIR 2 |
| Comp copy direction. | |
| #define | COMP_ATTR_VDMA_INDEX 3 |
| Comp index of the virtual DMA at the gateway. | |
| #define | COMP_ATTR_BASE_CONFIG 4 |
| Component base config. | |
| #define | COMP_ATTR_IPC4_CONFIG 5 |
| Component ipc4 set/get config. | |
Trace macros | |
| #define | trace_comp_drv_get_tr_ctx(drv_p) |
| Retrieves trace context from the component driver. | |
| #define | trace_comp_drv_get_id(drv_p) |
| Retrieves id (-1 = undefined) from the component driver. | |
| #define | trace_comp_drv_get_subid(drv_p) |
| Retrieves subid (-1 = undefined) from the component driver. | |
| #define | trace_comp_get_tr_ctx(comp_p) |
| Retrieves trace context from the component device. | |
| #define | trace_comp_get_id(comp_p) |
| Retrieves id (pipe id) from the component device. | |
| #define | trace_comp_get_subid(comp_p) |
| Retrieves subid (comp id) from the component device. | |
| #define | comp_cl_err(drv_p, __e, ...) |
| Trace error message from component driver (no comp instance). | |
| #define | comp_cl_warn(drv_p, __e, ...) |
| Trace warning message from component driver (no comp instance). | |
| #define | comp_cl_info(drv_p, __e, ...) |
| Trace info message from component driver (no comp instance). | |
| #define | comp_cl_dbg(drv_p, __e, ...) |
| Trace debug message from component driver (no comp instance). | |
| #define | comp_err(comp_p, __e, ...) |
| Trace error message from component device. | |
| #define | comp_warn(comp_p, __e, ...) |
| Trace warning message from component device. | |
| #define | comp_info(comp_p, __e, ...) |
| Trace info message from component device. | |
| #define | comp_dbg(comp_p, __e, ...) |
| Trace debug message from component device. | |
| #define | comp_perf_info(pcd, comp_p) |
| #define | comp_perf_avg_info(pcd, comp_p) |
| #define COMP_ATTR_BASE_CONFIG 4 |
Component base config.
| #define COMP_ATTR_COPY_DIR 2 |
Comp copy direction.
| #define COMP_ATTR_COPY_TYPE 0 |
Comp copy type attribute.
| #define COMP_ATTR_HOST_BUFFER 1 |
Comp host buffer attribute.
| #define COMP_ATTR_IPC4_CONFIG 5 |
Component ipc4 set/get config.
| #define COMP_ATTR_VDMA_INDEX 3 |
Comp index of the virtual DMA at the gateway.
| #define comp_cl_dbg | ( | drv_p, | |
| __e, | |||
| ... ) |
Trace debug message from component driver (no comp instance).
| #define comp_cl_err | ( | drv_p, | |
| __e, | |||
| ... ) |
Trace error message from component driver (no comp instance).
| #define comp_cl_info | ( | drv_p, | |
| __e, | |||
| ... ) |
Trace info message from component driver (no comp instance).
| #define comp_cl_warn | ( | drv_p, | |
| __e, | |||
| ... ) |
Trace warning message from component driver (no comp instance).
| #define COMP_CMD_GET_DATA 103 |
Get data from component.
| #define COMP_CMD_GET_VALUE 101 |
Get value from component.
| #define COMP_CMD_IPC_MMAP_PPOS 201 |
DAI presentation position.
| #define COMP_CMD_IPC_MMAP_RPOS 200 |
Host read position.
| #define COMP_CMD_IPC_MMAP_VOL | ( | chan | ) |
Volume.
| #define COMP_CMD_SET_DATA 102 |
Set data to component.
| #define COMP_CMD_SET_VALUE 100 |
Set value to component.
| #define comp_dbg | ( | comp_p, | |
| __e, | |||
| ... ) |
Trace debug message from component device.
| #define comp_dev_for_each_consumer | ( | _dev, | |
| _consumer ) |
| #define comp_dev_for_each_consumer_safe | ( | _dev, | |
| _consumer, | |||
| _next_consumer ) |
| #define comp_dev_for_each_producer | ( | _dev, | |
| _producer ) |
| #define comp_dev_for_each_producer_safe | ( | _dev, | |
| _producer, | |||
| _next_producer ) |
| #define comp_err | ( | comp_p, | |
| __e, | |||
| ... ) |
Trace error message from component device.
| #define comp_info | ( | comp_p, | |
| __e, | |||
| ... ) |
Trace info message from component device.
| #define comp_perf_avg_info | ( | pcd, | |
| comp_p ) |
| #define comp_perf_info | ( | pcd, | |
| comp_p ) |
| #define COMP_PROCESSING_DOMAIN_DP 1 |
| #define COMP_PROCESSING_DOMAIN_LL 0 |
| #define COMP_STATE_ACTIVE 6 |
Component active.
| #define COMP_STATE_INIT 1 |
Component being initialised.
| #define COMP_STATE_NOT_EXIST 0 |
Component does not exist.
| #define COMP_STATE_PAUSED 5 |
Component paused.
| #define COMP_STATE_PRE_ACTIVE 7 |
Component after early initialisation.
| #define COMP_STATE_PREPARE 4 |
Component prepared.
| #define COMP_STATE_READY 2 |
Component inactive, but ready.
| #define COMP_STATE_SUSPEND 3 |
Component suspended.
| #define COMP_STATUS_STATE_ALREADY_SET 1 |
Comp set state status.
| #define comp_warn | ( | comp_p, | |
| __e, | |||
| ... ) |
Trace warning message from component device.
| #define trace_comp_drv_get_id | ( | drv_p | ) |
Retrieves id (-1 = undefined) from the component driver.
| #define trace_comp_drv_get_subid | ( | drv_p | ) |
Retrieves subid (-1 = undefined) from the component driver.
| #define trace_comp_drv_get_tr_ctx | ( | drv_p | ) |
Retrieves trace context from the component driver.
| #define trace_comp_get_id | ( | comp_p | ) |
Retrieves id (pipe id) from the component device.
| #define trace_comp_get_subid | ( | comp_p | ) |
Retrieves subid (comp id) from the component device.
| #define trace_comp_get_tr_ctx | ( | comp_p | ) |
Retrieves trace context from the component device.
| anonymous enum |
| enum bind_type |
| enum comp_copy_type |
Type of next dma copy mode, changed on runtime.
Supported by host as COMP_ATTR_COPY_TYPE parameter to comp_set_attribute().
| Enumerator | |
|---|---|
| COMP_COPY_INVALID | Invalid. |
| COMP_COPY_NORMAL | Normal. |
| COMP_COPY_BLOCKING | Blocking. |
| COMP_COPY_ONE_SHOT | One-shot. |
| enum comp_endpoint_type |
|
inlinestatic |
Get a pointer to the first comp_buffer object receiving data from the component The function will return NULL if there's no data consumers.
|
inlinestatic |
Get a pointer to the first comp_buffer object providing data to the component The function will return NULL if there's no data provider.
|
inlinestatic |
Get a pointer to the next comp_buffer object receiving data from the component The function will return NULL if there're no more data consumers _safe version also checks if consumer is != NULL.
|
inlinestatic |
|
inlinestatic |
Get a pointer to the next comp_buffer object providing data to the component The function will return NULL if there're no more data providers _save version also checks if producer != NULL.
|
inlinestatic |