Skip to content

Commit 320f4d8

Browse files
Amadeusz Sławińskibroonie
authored andcommitted
ASoC: Intel: avs: Fix avs_path_module::instance_id size
All IPCs using instance_id use 8 bit value. Original commit used 16 bit value because FW reports possible max value in 16 bit field, but in practice FW limits the value to 8 bits. Reviewed-by: Cezary Rojewski <[email protected]> Signed-off-by: Amadeusz Sławiński <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
1 parent 8368551 commit 320f4d8

File tree

4 files changed

+6
-6
lines changed

4 files changed

+6
-6
lines changed

sound/soc/intel/avs/avs.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -283,8 +283,8 @@ void avs_release_firmwares(struct avs_dev *adev);
283283

284284
int avs_dsp_init_module(struct avs_dev *adev, u16 module_id, u8 ppl_instance_id,
285285
u8 core_id, u8 domain, void *param, u32 param_size,
286-
u16 *instance_id);
287-
void avs_dsp_delete_module(struct avs_dev *adev, u16 module_id, u16 instance_id,
286+
u8 *instance_id);
287+
void avs_dsp_delete_module(struct avs_dev *adev, u16 module_id, u8 instance_id,
288288
u8 ppl_instance_id, u8 core_id);
289289
int avs_dsp_create_pipeline(struct avs_dev *adev, u16 req_size, u8 priority,
290290
bool lp, u16 attributes, u8 *instance_id);

sound/soc/intel/avs/dsp.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,7 @@ static int avs_dsp_put_core(struct avs_dev *adev, u32 core_id)
225225

226226
int avs_dsp_init_module(struct avs_dev *adev, u16 module_id, u8 ppl_instance_id,
227227
u8 core_id, u8 domain, void *param, u32 param_size,
228-
u16 *instance_id)
228+
u8 *instance_id)
229229
{
230230
struct avs_module_entry mentry;
231231
bool was_loaded = false;
@@ -272,7 +272,7 @@ int avs_dsp_init_module(struct avs_dev *adev, u16 module_id, u8 ppl_instance_id,
272272
return ret;
273273
}
274274

275-
void avs_dsp_delete_module(struct avs_dev *adev, u16 module_id, u16 instance_id,
275+
void avs_dsp_delete_module(struct avs_dev *adev, u16 module_id, u8 instance_id,
276276
u8 ppl_instance_id, u8 core_id)
277277
{
278278
struct avs_module_entry mentry;

sound/soc/intel/avs/path.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ struct avs_path_pipeline {
3737

3838
struct avs_path_module {
3939
u16 module_id;
40-
u16 instance_id;
40+
u8 instance_id;
4141
union avs_gtw_attributes gtw_attrs;
4242

4343
struct avs_tplg_module *template;

sound/soc/intel/avs/probes.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ static int avs_dsp_init_probe(struct avs_dev *adev, union avs_connector_node_id
1818
{
1919
struct avs_probe_cfg cfg = {{0}};
2020
struct avs_module_entry mentry;
21-
u16 dummy;
21+
u8 dummy;
2222

2323
avs_get_module_entry(adev, &AVS_PROBE_MOD_UUID, &mentry);
2424

0 commit comments

Comments
 (0)