Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

basefw: Add handling of IPC4_DMA_CONTROL messages #9156

Merged

Commits on Aug 9, 2024

  1. lib: dai: Expose Zephyr DAI device retrieval function

    This patch exposes the function to retrieve a pointer to the Zephyr
    device structure for a DAI of a given type and index. Previously, the
    function `dai_get_zephyr_device` was static and only usable within
    `dai.c`. By introducing `dai_get_device`, other parts of the SOF
    codebase can now access the Zephyr DAI device pointers, facilitating
    integration with Zephyr native DAI drivers.
    
    Signed-off-by: Tomasz Leman <tomasz.m.leman@intel.com>
    tmleman committed Aug 9, 2024
    Configuration menu
    Copy the full SHA
    397196a View commit details
    Browse the repository at this point in the history
  2. audio: base_fw: Implement IPC4_DMA_CONTROL message handling

    This patch introduces handling for the IPC4_DMA_CONTROL message type in
    the base firmware. The implementation includes a new function
    `basefw_vendor_dma_control` to process the DMA Control configuration for
    any DAI type.
    
    The `basefw_dma_control` function has been added to handle the
    IPC4_DMA_CONTROL message. It ensures the message is atomic and contains
    all necessary information before casting the data buffer to the
    `ipc4_dma_control` structure and processing it. The function also calls
    `basefw_vendor_dma_control` to apply the DMA Control configuration to
    the hardware.
    
    The `basefw_set_large_config` function in `src/audio/base_fw.c` has been
    updated to call `basefw_dma_control` when an IPC4_DMA_CONTROL message is
    received. If the `dai_config_update` operation is not implemented by the
    DAI driver, the function will return `-ENOSYS`.
    
    This change allows the base firmware to initialize or modify DMA gateway
    configurations dynamically, improving the flexibility of DMA management
    in response to IPC messages.
    
    Signed-off-by: Tomasz Leman <tomasz.m.leman@intel.com>
    tmleman committed Aug 9, 2024
    Configuration menu
    Copy the full SHA
    3fa5277 View commit details
    Browse the repository at this point in the history