Skip to content

Commit a72c6bd

Browse files
author
Jyri Sarha
committed
modules: Better mod_alloc_align() failure prints
Remove the remains of function name from the prints and in case of heap allocation failure, print all available related parameters. Signed-off-by: Jyri Sarha <jyri.sarha@linux.intel.com>
1 parent 05cd1f0 commit a72c6bd

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/audio/module_adapter/module/generic.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ void *mod_alloc_align(struct processing_module *mod, uint32_t size, uint32_t ali
182182
return NULL;
183183

184184
if (!size) {
185-
comp_err(mod->dev, "mod_alloc: requested allocation of 0 bytes.");
185+
comp_err(mod->dev, "requested allocation of 0 bytes.");
186186
container_put(mod, container);
187187
return NULL;
188188
}
@@ -191,8 +191,8 @@ void *mod_alloc_align(struct processing_module *mod, uint32_t size, uint32_t ali
191191
ptr = rmalloc_align(SOF_MEM_FLAG_USER, size, alignment);
192192

193193
if (!ptr) {
194-
comp_err(mod->dev, "mod_alloc: failed to allocate memory for comp %x.",
195-
dev_comp_id(mod->dev));
194+
comp_err(mod->dev, "Failed to alloc %d bytes %d alignment for comp %x.",
195+
size, alignment, dev_comp_id(mod->dev));
196196
container_put(mod, container);
197197
return NULL;
198198
}

0 commit comments

Comments
 (0)