summaryrefslogtreecommitdiff
path: root/sound/soc/intel/avs/messages.h
diff options
context:
space:
mode:
authorCezary Rojewski <cezary.rojewski@intel.com>2022-03-11 18:35:32 +0300
committerMark Brown <broonie@kernel.org>2022-03-11 19:23:56 +0300
commitcb1eb6b5be42799d23f81ffde84ee3537365b0ed (patch)
tree9882034afc13a040a3a2514f6f45148d6c04fda8 /sound/soc/intel/avs/messages.h
parent2879516fcd6d7ec5972762dbd94859d9221e70d8 (diff)
downloadlinux-cb1eb6b5be42799d23f81ffde84ee3537365b0ed.tar.xz
ASoC: Intel: avs: Add code loading requests
Before firmware and its modules can be used, they have to be loaded. Code loading process is complex and is a combination of DMA and IPC operations. Here, IPC part is being added and accounts for CLDMA and HDA mechanisms both. Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com> Signed-off-by: Cezary Rojewski <cezary.rojewski@intel.com> Link: https://lore.kernel.org/r/20220311153544.136854-6-cezary.rojewski@intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/intel/avs/messages.h')
-rw-r--r--sound/soc/intel/avs/messages.h22
1 files changed, 22 insertions, 0 deletions
diff --git a/sound/soc/intel/avs/messages.h b/sound/soc/intel/avs/messages.h
index becf336578d7..5e16aabfb6f4 100644
--- a/sound/soc/intel/avs/messages.h
+++ b/sound/soc/intel/avs/messages.h
@@ -24,6 +24,9 @@ enum avs_msg_direction {
};
enum avs_global_msg_type {
+ AVS_GLB_LOAD_MULTIPLE_MODULES = 15,
+ AVS_GLB_UNLOAD_MULTIPLE_MODULES = 16,
+ AVS_GLB_LOAD_LIBRARY = 24,
AVS_GLB_NOTIFICATION = 27,
};
@@ -38,6 +41,16 @@ union avs_global_msg {
u32 msg_direction:1;
u32 msg_target:1;
};
+ /* module loading */
+ struct {
+ u32 mod_cnt:8;
+ } load_multi_mods;
+ /* library loading */
+ struct {
+ u32 dma_id:5;
+ u32 rsvd:11;
+ u32 lib_id:4;
+ } load_lib;
};
union {
u32 val;
@@ -84,6 +97,10 @@ union avs_reply_msg {
};
union {
u32 val;
+ /* module loading */
+ struct {
+ u32 err_mod_id:16;
+ } load_multi_mods;
} ext;
};
} __packed;
@@ -167,4 +184,9 @@ struct avs_notify_mod_data {
u32 data[];
} __packed;
+/* Code loading messages */
+int avs_ipc_load_modules(struct avs_dev *adev, u16 *mod_ids, u32 num_mod_ids);
+int avs_ipc_unload_modules(struct avs_dev *adev, u16 *mod_ids, u32 num_mod_ids);
+int avs_ipc_load_library(struct avs_dev *adev, u32 dma_id, u32 lib_id);
+
#endif /* __SOUND_SOC_INTEL_AVS_MSGS_H */