ipc4-priv.h (a5d0147ac9f8ea6c08d00b28f0468c9cb3fdfde8) ipc4-priv.h (f4ea22f7aa7536560097d765be56445933d07e0d)
1/* SPDX-License-Identifier: (GPL-2.0-only OR BSD-3-Clause) */
2/*
3 * This file is provided under a dual BSD/GPLv2 license. When using or
4 * redistributing this file, you may do so under either license.
5 *
6 * Copyright(c) 2022 Intel Corporation. All rights reserved.
7 */
8
9#ifndef __SOUND_SOC_SOF_IPC4_PRIV_H
10#define __SOUND_SOC_SOF_IPC4_PRIV_H
11
12#include <linux/idr.h>
13#include <sound/sof/ext_manifest4.h>
14#include "sof-priv.h"
15
16/* The DSP window indices are fixed */
17#define SOF_IPC4_OUTBOX_WINDOW_IDX 1
18#define SOF_IPC4_DEBUG_WINDOW_IDX 2
19
1/* SPDX-License-Identifier: (GPL-2.0-only OR BSD-3-Clause) */
2/*
3 * This file is provided under a dual BSD/GPLv2 license. When using or
4 * redistributing this file, you may do so under either license.
5 *
6 * Copyright(c) 2022 Intel Corporation. All rights reserved.
7 */
8
9#ifndef __SOUND_SOC_SOF_IPC4_PRIV_H
10#define __SOUND_SOC_SOF_IPC4_PRIV_H
11
12#include <linux/idr.h>
13#include <sound/sof/ext_manifest4.h>
14#include "sof-priv.h"
15
16/* The DSP window indices are fixed */
17#define SOF_IPC4_OUTBOX_WINDOW_IDX 1
18#define SOF_IPC4_DEBUG_WINDOW_IDX 2
19
20enum sof_ipc4_mtrace_type {
21 SOF_IPC4_MTRACE_NOT_AVAILABLE = 0,
22 SOF_IPC4_MTRACE_INTEL_CAVS_1_5,
23 SOF_IPC4_MTRACE_INTEL_CAVS_1_8,
24 SOF_IPC4_MTRACE_INTEL_CAVS_2,
25};
26
20/**
21 * struct sof_ipc4_fw_data - IPC4-specific data
22 * @manifest_fw_hdr_offset: FW header offset in the manifest
23 * @num_fw_modules : Number of modules in base FW
24 * @fw_modules: Array of base FW modules
25 * @nhlt: NHLT table either from the BIOS or the topology manifest
27/**
28 * struct sof_ipc4_fw_data - IPC4-specific data
29 * @manifest_fw_hdr_offset: FW header offset in the manifest
30 * @num_fw_modules : Number of modules in base FW
31 * @fw_modules: Array of base FW modules
32 * @nhlt: NHLT table either from the BIOS or the topology manifest
33 * @mtrace_type: mtrace type supported on the booted platform
34 * @mtrace_log_bytes: log bytes as reported by the firmware via fw_config reply
26 */
27struct sof_ipc4_fw_data {
28 u32 manifest_fw_hdr_offset;
29 int num_fw_modules;
30 void *fw_modules;
31 void *nhlt;
35 */
36struct sof_ipc4_fw_data {
37 u32 manifest_fw_hdr_offset;
38 int num_fw_modules;
39 void *fw_modules;
40 void *nhlt;
41 enum sof_ipc4_mtrace_type mtrace_type;
42 u32 mtrace_log_bytes;
32};
33
34/**
35 * struct sof_ipc4_fw_module - IPC4 module info
36 * @sof_man4_module : Module info
37 * @m_ida: Module instance identifier
38 * @bss_size: Module object size
39 * @private: Module private data

--- 4 unchanged lines hidden (view full) ---

44 u32 bss_size;
45 void *private;
46};
47
48extern const struct sof_ipc_fw_loader_ops ipc4_loader_ops;
49extern const struct sof_ipc_tplg_ops ipc4_tplg_ops;
50extern const struct sof_ipc_tplg_control_ops tplg_ipc4_control_ops;
51extern const struct sof_ipc_pcm_ops ipc4_pcm_ops;
43};
44
45/**
46 * struct sof_ipc4_fw_module - IPC4 module info
47 * @sof_man4_module : Module info
48 * @m_ida: Module instance identifier
49 * @bss_size: Module object size
50 * @private: Module private data

--- 4 unchanged lines hidden (view full) ---

55 u32 bss_size;
56 void *private;
57};
58
59extern const struct sof_ipc_fw_loader_ops ipc4_loader_ops;
60extern const struct sof_ipc_tplg_ops ipc4_tplg_ops;
61extern const struct sof_ipc_tplg_control_ops tplg_ipc4_control_ops;
62extern const struct sof_ipc_pcm_ops ipc4_pcm_ops;
63extern const struct sof_ipc_fw_tracing_ops ipc4_mtrace_ops;
52
53int sof_ipc4_set_pipeline_state(struct snd_sof_dev *sdev, u32 id, u32 state);
64
65int sof_ipc4_set_pipeline_state(struct snd_sof_dev *sdev, u32 id, u32 state);
54
66int sof_ipc4_mtrace_update_pos(struct snd_sof_dev *sdev, int core);
55#endif
67#endif