Skip to content

Commit 25d0f01

Browse files
committed
dmic: fix mem alloc for dmic params
The dmic params struct should be allocated in RZONE_RUNTIME instead of RZONE_SYS so that it can be freed. This fixes the DSP panic caused while it is freed after setting the DMIC config. Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
1 parent 66bd59b commit 25d0f01

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/drivers/intel/cavs/dmic.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1118,7 +1118,7 @@ static int dmic_set_config(struct dai *dai, struct sof_ipc_dai_config *config)
11181118
*/
11191119
size = sizeof(*prm) + DMIC_HW_CONTROLLERS
11201120
* sizeof(struct sof_ipc_dai_dmic_pdm_ctrl);
1121-
prm = rzalloc(RZONE_SYS, SOF_MEM_CAPS_RAM, size);
1121+
prm = rzalloc(RZONE_RUNTIME, SOF_MEM_CAPS_RAM, size);
11221122
if (!prm) {
11231123
trace_dmic_error("eac");
11241124
return -ENOMEM;

0 commit comments

Comments
 (0)