Skip to content

Commit

Permalink
ASoC: SOF: IPC4: add fw_image_flags support
Browse files Browse the repository at this point in the history
Driver gets fw_image_flags fw manifest and adopts features based on
this flag.

Signed-off-by: Rander Wang <[email protected]>
  • Loading branch information
RanderWang committed Oct 27, 2023
1 parent 180286d commit 0a3fb4f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
2 changes: 2 additions & 0 deletions sound/soc/sof/ipc4-loader.c
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,8 @@ static ssize_t sof_ipc4_fw_parse_ext_man(struct snd_sof_dev *sdev,
dev_dbg(sdev->dev, "Header length: %u, module count: %u\n",
fw_header->len, fw_header->num_module_entries);

ipc4_data->fw_image_flags = fw_header->fw_image_flags;

fw_lib->modules = devm_kmalloc_array(sdev->dev, fw_header->num_module_entries,
sizeof(*fw_module), GFP_KERNEL);
if (!fw_lib->modules)
Expand Down
3 changes: 3 additions & 0 deletions sound/soc/sof/ipc4-priv.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@
#define SOF_IPC4_OUTBOX_WINDOW_IDX 1
#define SOF_IPC4_DEBUG_WINDOW_IDX 2

#define SOF_IPC4_LIBRARY_RELOAD BIT(0)

enum sof_ipc4_mtrace_type {
SOF_IPC4_MTRACE_NOT_AVAILABLE = 0,
SOF_IPC4_MTRACE_INTEL_CAVS_1_5,
Expand Down Expand Up @@ -81,6 +83,7 @@ struct sof_ipc4_fw_data {
u32 mtrace_log_bytes;
int max_num_pipelines;
u32 max_libs_count;
u32 fw_image_flags;

int (*load_library)(struct snd_sof_dev *sdev,
struct sof_ipc4_fw_library *fw_lib, bool reload);
Expand Down

0 comments on commit 0a3fb4f

Please sign in to comment.