From f7dddc2c29cf4a113d16fb1b63acdd8d4104bb2a Mon Sep 17 00:00:00 2001 From: Guennadi Liakhovetski Date: Tue, 12 Aug 2025 10:23:21 +0200 Subject: [PATCH 1/5] audio: module-adapter: remove more function names from logs Remove left-over function names in log prints in generic.c, also remove component ID prints in comp_*() calls because they print the ID automatically. Signed-off-by: Guennadi Liakhovetski --- src/audio/module_adapter/module/generic.c | 61 +++++++++-------------- 1 file changed, 24 insertions(+), 37 deletions(-) diff --git a/src/audio/module_adapter/module/generic.c b/src/audio/module_adapter/module/generic.c index 929098d9903e..f95299f952d8 100644 --- a/src/audio/module_adapter/module/generic.c +++ b/src/audio/module_adapter/module/generic.c @@ -35,7 +35,7 @@ int module_load_config(struct comp_dev *dev, const void *cfg, size_t size) struct processing_module *mod = comp_mod(dev); struct module_data *md = &mod->priv; - comp_dbg(dev, "module_load_config() start"); + comp_dbg(dev, "entry"); if (!cfg || !size) { comp_err(dev, "wrong input params! dev %zx, cfg %zx size %zu", @@ -67,7 +67,7 @@ int module_load_config(struct comp_dev *dev, const void *cfg, size_t size) dst->size = size; dst->avail = true; - comp_dbg(dev, "module_load_config() done"); + comp_dbg(dev, "done"); return ret; } @@ -78,7 +78,7 @@ int module_init(struct processing_module *mod) struct comp_dev *dev = mod->dev; const struct module_interface *const interface = dev->drv->adapter_ops; - comp_dbg(dev, "module_init() start"); + comp_dbg(dev, "entry"); #if CONFIG_IPC_MAJOR_3 if (mod->priv.state == MODULE_INITIALIZED) @@ -87,8 +87,7 @@ int module_init(struct processing_module *mod) return -EPERM; #endif if (!interface) { - comp_err(dev, "module interface not defined for comp id %#x", - dev_comp_id(dev)); + comp_err(dev, "module interface not defined"); return -EIO; } @@ -96,8 +95,7 @@ int module_init(struct processing_module *mod) if (!interface->init || (!!interface->process + !!interface->process_audio_stream + !!interface->process_raw_data < 1)) { - comp_err(dev, "comp %#x is missing mandatory interfaces", - dev_comp_id(dev)); + comp_err(dev, "comp is missing mandatory interfaces"); return -EIO; } @@ -113,12 +111,11 @@ int module_init(struct processing_module *mod) /* Now we can proceed with module specific initialization */ ret = interface->init(mod); if (ret) { - comp_err(dev, "module_init() error %d: module specific init failed, comp id %#x", - ret, dev_comp_id(dev)); + comp_err(dev, "error %d: module specific init failed", ret); return ret; } - comp_dbg(dev, "module_init() done"); + comp_dbg(dev, "done"); #if CONFIG_IPC_MAJOR_3 md->state = MODULE_INITIALIZED; #endif @@ -182,7 +179,7 @@ void *mod_alloc_align(struct processing_module *mod, uint32_t size, uint32_t ali return NULL; if (!size) { - comp_err(mod->dev, "mod_alloc: requested allocation of 0 bytes."); + comp_err(mod->dev, "requested allocation of 0 bytes."); container_put(mod, container); return NULL; } @@ -194,8 +191,7 @@ void *mod_alloc_align(struct processing_module *mod, uint32_t size, uint32_t ali ptr = rballoc(SOF_MEM_FLAG_USER, size); if (!ptr) { - comp_err(mod->dev, "mod_alloc: failed to allocate memory for comp %x.", - dev_comp_id(mod->dev)); + comp_err(mod->dev, "failed to allocate memory."); container_put(mod, container); return NULL; } @@ -368,8 +364,7 @@ int mod_free(struct processing_module *mod, const void *ptr) } } - comp_err(mod->dev, "mod_free: error: could not find memory pointed by %p", - ptr); + comp_err(mod->dev, "error: could not find memory pointed by %p", ptr); return -EINVAL; } @@ -399,7 +394,7 @@ int module_prepare(struct processing_module *mod, struct comp_dev *dev = mod->dev; const struct module_interface *const ops = dev->drv->adapter_ops; - comp_dbg(dev, "module_prepare() start"); + comp_dbg(dev, "entry"); #if CONFIG_IPC_MAJOR_3 if (mod->priv.state == MODULE_IDLE) @@ -411,8 +406,7 @@ int module_prepare(struct processing_module *mod, int ret = ops->prepare(mod, sources, num_of_sources, sinks, num_of_sinks); if (ret) { - comp_err(dev, "module_prepare() error %d: module specific prepare failed, comp_id %d", - ret, dev_comp_id(dev)); + comp_err(dev, "error %d: module specific prepare failed", ret); return ret; } } @@ -429,7 +423,7 @@ int module_prepare(struct processing_module *mod, #if CONFIG_IPC_MAJOR_3 md->state = MODULE_IDLE; #endif - comp_dbg(dev, "module_prepare() done"); + comp_dbg(dev, "done"); return 0; } @@ -443,14 +437,13 @@ int module_process_legacy(struct processing_module *mod, const struct module_interface *const ops = dev->drv->adapter_ops; int ret; - comp_dbg(dev, "module_process_legacy() start"); + comp_dbg(dev, "entry"); #if CONFIG_IPC_MAJOR_3 struct module_data *md = &mod->priv; if (md->state != MODULE_IDLE) { - comp_err(dev, "wrong state of comp_id %x, state %d", - dev_comp_id(dev), md->state); + comp_err(dev, "wrong state %d", md->state); return -EPERM; } @@ -467,12 +460,11 @@ int module_process_legacy(struct processing_module *mod, ret = -EOPNOTSUPP; if (ret && ret != -ENOSPC && ret != -ENODATA) { - comp_err(dev, "module_process() error %d: for comp %#x", - ret, dev_comp_id(dev)); + comp_err(dev, "error %d", ret); return ret; } - comp_dbg(dev, "module_process_legacy() done"); + comp_dbg(dev, "done"); #if CONFIG_IPC_MAJOR_3 /* reset state to idle */ @@ -490,13 +482,12 @@ int module_process_sink_src(struct processing_module *mod, const struct module_interface *const ops = dev->drv->adapter_ops; int ret; - comp_dbg(dev, "module_process sink src() start"); + comp_dbg(dev, "entry"); #if CONFIG_IPC_MAJOR_3 struct module_data *md = &mod->priv; if (md->state != MODULE_IDLE) { - comp_err(dev, "wrong state of comp_id %x, state %d", - dev_comp_id(dev), md->state); + comp_err(dev, "wrong state %d", md->state); return -EPERM; } @@ -507,12 +498,11 @@ int module_process_sink_src(struct processing_module *mod, ret = ops->process(mod, sources, num_of_sources, sinks, num_of_sinks); if (ret && ret != -ENOSPC && ret != -ENODATA) { - comp_err(dev, "module_process() error %d: for comp %#x", - ret, dev_comp_id(dev)); + comp_err(dev, "error %d", ret); return ret; } - comp_dbg(dev, "module_process sink src() done"); + comp_dbg(dev, "done"); #if CONFIG_IPC_MAJOR_3 /* reset state to idle */ @@ -540,8 +530,7 @@ int module_reset(struct processing_module *mod) if (ret) { if (ret != PPL_STATUS_PATH_STOP) comp_err(mod->dev, - "module_reset() error %d: module specific reset() failed for comp %#xd", - ret, dev_comp_id(mod->dev)); + "error %d: module specific reset() failed", ret); return ret; } } @@ -602,8 +591,7 @@ int module_free(struct processing_module *mod) if (ops->free) { ret = ops->free(mod); if (ret) - comp_warn(mod->dev, "error: %d for %d", - ret, dev_comp_id(mod->dev)); + comp_warn(mod->dev, "error: %d", ret); } /* Free all memory shared by module_adapter & module */ @@ -702,8 +690,7 @@ int module_set_configuration(struct processing_module *mod, ret = memcpy_s(dst, md->new_cfg_size - offset, fragment, fragment_size); if (ret < 0) { - comp_err(dev, "error: %d failed to copy fragment", - ret); + comp_err(dev, "error: %d failed to copy fragment", ret); return ret; } From e337840e53f3c09a2d0c85565c1881411c650824 Mon Sep 17 00:00:00 2001 From: Guennadi Liakhovetski Date: Thu, 24 Jul 2025 16:16:14 +0200 Subject: [PATCH 2/5] audio: module-adapter: (cosmetic) remove function names Remove function names from logging and merge needlessly split lines. Signed-off-by: Guennadi Liakhovetski --- src/audio/module_adapter/module_adapter.c | 58 ++++++++++------------- 1 file changed, 24 insertions(+), 34 deletions(-) diff --git a/src/audio/module_adapter/module_adapter.c b/src/audio/module_adapter/module_adapter.c index defba3a3785c..b77f57334401 100644 --- a/src/audio/module_adapter/module_adapter.c +++ b/src/audio/module_adapter/module_adapter.c @@ -66,17 +66,17 @@ struct comp_dev *module_adapter_new_ext(const struct comp_driver *drv, struct module_config *dst; const struct module_interface *const interface = drv->adapter_ops; - comp_cl_dbg(drv, "module_adapter_new() start"); + comp_cl_dbg(drv, "start"); if (!config) { - comp_cl_err(drv, "module_adapter_new(), wrong input params! drv = %zx config = %zx", + comp_cl_err(drv, "wrong input params! drv = %zx config = %zx", (size_t)drv, (size_t)config); return NULL; } dev = comp_alloc(drv, sizeof(*dev)); if (!dev) { - comp_cl_err(drv, "module_adapter_new(), failed to allocate memory for comp_dev"); + comp_cl_err(drv, "failed to allocate memory for comp_dev"); return NULL; } dev->ipc_config = *config; @@ -92,7 +92,7 @@ struct comp_dev *module_adapter_new_ext(const struct comp_driver *drv, mod = module_driver_heap_rzalloc(drv->user_heap, flags, sizeof(*mod)); if (!mod) { - comp_err(dev, "module_adapter_new(), failed to allocate memory for module"); + comp_err(dev, "failed to allocate memory for module"); goto err; } @@ -106,7 +106,7 @@ struct comp_dev *module_adapter_new_ext(const struct comp_driver *drv, ret = module_adapter_init_data(dev, dst, config, spec); if (ret) { - comp_err(dev, "module_adapter_new() %d: module init data failed", + comp_err(dev, "%d: module init data failed", ret); goto err; } @@ -128,7 +128,7 @@ struct comp_dev *module_adapter_new_ext(const struct comp_driver *drv, /* Init processing module */ ret = module_init(mod); if (ret) { - comp_err(dev, "module_adapter_new() %d: module initialization failed", + comp_err(dev, "%d: module initialization failed", ret); goto err; } @@ -152,12 +152,12 @@ struct comp_dev *module_adapter_new_ext(const struct comp_driver *drv, */ ret = module_adapter_params(dev, ¶ms); if (ret) { - comp_err(dev, "module_adapter_new() %d: module params failed", ret); + comp_err(dev, "%d: module params failed", ret); goto err; } #endif - comp_dbg(dev, "module_adapter_new() done"); + comp_dbg(dev, "done"); return dev; err: #if CONFIG_IPC_MAJOR_4 @@ -213,7 +213,7 @@ int module_adapter_prepare(struct comp_dev *dev) int memory_flags; int i = 0; - comp_dbg(dev, "module_adapter_prepare() start"); + comp_dbg(dev, "start"); #if CONFIG_IPC_MAJOR_4 /* * if the stream_params are valid, just update the sink/source buffer params. If not, @@ -249,8 +249,7 @@ int module_adapter_prepare(struct comp_dev *dev) if (ret) { if (ret != PPL_STATUS_PATH_STOP) - comp_err(dev, "module_adapter_prepare() error %x: module prepare failed", - ret); + comp_err(dev, "error %d: module prepare failed", ret); return ret; } @@ -484,7 +483,7 @@ int module_adapter_prepare(struct comp_dev *dev) } } - comp_dbg(dev, "module_adapter_prepare() done"); + comp_dbg(dev, "done"); return 0; @@ -564,9 +563,8 @@ EXPORT_SYMBOL(module_adapter_params); * @buff_size: size of the module input buffer * @bytes: number of bytes available in the source buffer */ -static void -ca_copy_from_source_to_module(const struct audio_stream *source, - void *buff, uint32_t buff_size, size_t bytes) +static void ca_copy_from_source_to_module(const struct audio_stream *source, + void *buff, uint32_t buff_size, size_t bytes) { /* head_size - available data until end of source buffer */ const int without_wrap = audio_stream_bytes_without_wrap(source, @@ -592,9 +590,8 @@ ca_copy_from_source_to_module(const struct audio_stream *source, * @buff: pointer to the module output buffer * @bytes: number of bytes available in the module output buffer */ -static void -ca_copy_from_module_to_sink(const struct audio_stream *sink, - void *buff, size_t bytes) +static void ca_copy_from_module_to_sink(const struct audio_stream *sink, + void *buff, size_t bytes) { /* head_size - free space until end of sink buffer */ const int without_wrap = audio_stream_bytes_without_wrap(sink, audio_stream_get_wptr(sink)); @@ -723,10 +720,9 @@ static void module_adapter_process_output(struct comp_dev *dev) mod->total_data_produced += mod->output_buffers[0].size; } -static uint32_t -module_single_sink_setup(struct comp_dev *dev, - struct comp_buffer **source, - struct comp_buffer **sinks) +static uint32_t module_single_sink_setup(struct comp_dev *dev, + struct comp_buffer **source, + struct comp_buffer **sinks) { struct processing_module *mod = comp_mod(dev); struct list_item *blist; @@ -764,10 +760,9 @@ module_single_sink_setup(struct comp_dev *dev, return num_input_buffers; } -static uint32_t -module_single_source_setup(struct comp_dev *dev, - struct comp_buffer **source, - struct comp_buffer **sinks) +static uint32_t module_single_source_setup(struct comp_dev *dev, + struct comp_buffer **source, + struct comp_buffer **sinks) { struct processing_module *mod = comp_mod(dev); struct list_item *blist; @@ -911,9 +906,7 @@ static int module_adapter_audio_stream_type_copy(struct comp_dev *dev) mod->output_buffers, num_output_buffers); if (ret) { if (ret != -ENOSPC && ret != -ENODATA) { - comp_err(dev, - "module_adapter_audio_stream_type_copy() failed with error: %x", - ret); + comp_err(dev, "failed with error: %d", ret); goto out; } @@ -1052,8 +1045,7 @@ static int module_adapter_sink_source_copy(struct comp_dev *dev) mod->sinks, mod->num_of_sinks); if (ret) - comp_err(dev, "module_adapter_sink_source_copy() process failed with error: %d", - ret); + comp_err(dev, "process failed with error: %d", ret); /* count number of processed data. To be removed in pipeline 2.0 */ for (i = 0; i < mod->num_of_sources; i++) @@ -1114,9 +1106,7 @@ static int module_adapter_raw_data_type_copy(struct comp_dev *dev) mod->output_buffers, mod->num_of_sinks); if (ret) { if (ret != -ENOSPC && ret != -ENODATA) { - comp_err(dev, - "module_adapter_raw_data_type_copy() %x: module processing failed", - ret); + comp_err(dev, "%d: module processing failed", ret); goto out; } From 9aede19cb52b40ea60e2aa7f4dac04f5a5e0ea62 Mon Sep 17 00:00:00 2001 From: Guennadi Liakhovetski Date: Fri, 15 Aug 2025 09:22:05 +0200 Subject: [PATCH 3/5] audio: mixin-mixout: remove function names Remove function names from logging, missed by automation. Signed-off-by: Guennadi Liakhovetski --- src/audio/mixin_mixout/mixin_mixout.c | 32 +++++++++++++-------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/src/audio/mixin_mixout/mixin_mixout.c b/src/audio/mixin_mixout/mixin_mixout.c index 6eaba83aca3b..ec473baf6e58 100644 --- a/src/audio/mixin_mixout/mixin_mixout.c +++ b/src/audio/mixin_mixout/mixin_mixout.c @@ -139,7 +139,7 @@ static int mixin_init(struct processing_module *mod) struct mixin_data *md; int i; - comp_dbg(dev, "mixin_init()"); + comp_dbg(dev, "entry"); md = rzalloc(SOF_MEM_FLAG_USER, sizeof(*md)); if (!md) @@ -166,7 +166,7 @@ static int mixout_init(struct processing_module *mod) struct comp_dev *dev = mod->dev; struct mixout_data *mo_data; - comp_dbg(dev, "mixout_new()"); + comp_dbg(dev, "entry"); mo_data = rzalloc(SOF_MEM_FLAG_USER, sizeof(*mo_data)); if (!mo_data) @@ -320,7 +320,7 @@ static int mixin_process(struct processing_module *mod, int i, ret; struct cir_buf_ptr source_ptr; - comp_dbg(dev, "mixin_process()"); + comp_dbg(dev, "entry"); source_avail_frames = source_get_data_frames_available(sources[0]); sinks_free_frames = INT32_MAX; @@ -526,7 +526,7 @@ static int mixout_process(struct processing_module *mod, struct pending_frames *pending_frames; int i; - comp_dbg(dev, "mixout_process()"); + comp_dbg(dev, "entry"); md = module_get_private_data(mod); @@ -650,7 +650,7 @@ static int mixin_params(struct processing_module *mod) int i; int ret; - comp_dbg(dev, "mixin_params()"); + comp_dbg(dev, "entry"); ipc4_base_module_cfg_to_stream_params(&mod->priv.cfg.base_cfg, params); @@ -717,7 +717,7 @@ static int mixin_prepare(struct processing_module *mod, enum sof_ipc_frame fmt; int ret; - comp_info(dev, "mixin_prepare()"); + comp_info(dev, "entry"); md->eos_delay_configured = false; ret = mixin_params(mod); @@ -753,7 +753,7 @@ static int mixout_params(struct processing_module *mod) enum sof_ipc_frame frame_fmt, valid_fmt; int ret; - comp_dbg(dev, "mixout_params()"); + comp_dbg(dev, "entry"); ipc4_base_module_cfg_to_stream_params(&mod->priv.cfg.base_cfg, params); @@ -790,7 +790,7 @@ static int mixout_prepare(struct processing_module *mod, if (ret < 0) return ret; - comp_dbg(dev, "mixout_prepare()"); + comp_dbg(dev, "entry"); /* * Since mixout sink buffer stream is reset on .prepare(), let's @@ -822,7 +822,7 @@ static int mixout_bind(struct processing_module *mod, struct bind_info *bind_dat mixin = ipc4_get_comp_dev(src_id); if (!mixin) { - comp_err(mod->dev, "mixout_bind: no mixin with ID %d found", src_id); + comp_err(mod->dev, "no mixin with ID %d found", src_id); return -EINVAL; } @@ -860,7 +860,7 @@ static int mixout_unbind(struct processing_module *mod, struct bind_info *unbind int src_id; struct mixout_data *mixout_data; - comp_dbg(mod->dev, "mixout_unbind()"); + comp_dbg(mod->dev, "entry"); bu = unbind_data->ipc4_data; src_id = IPC4_COMP_ID(bu->primary.r.module_id, bu->primary.r.instance_id); @@ -871,7 +871,7 @@ static int mixout_unbind(struct processing_module *mod, struct bind_info *unbind mixin = ipc4_get_comp_dev(src_id); if (!mixin) { - comp_err(mod->dev, "mixout_bind: no mixin with ID %d found", src_id); + comp_err(mod->dev, "no mixin with ID %d found", src_id); return -EINVAL; } @@ -900,30 +900,30 @@ static int mixin_set_config(struct processing_module *mod, uint32_t config_id, uint16_t gain; if (config_id != IPC4_MIXER_MODE) { - comp_err(dev, "mixin_set_config() unsupported param ID: %u", config_id); + comp_err(dev, "unsupported param ID: %u", config_id); return -EINVAL; } if (!(pos & MODULE_CFG_FRAGMENT_SINGLE)) { - comp_err(dev, "mixin_set_config() data is expected to be sent as one chunk"); + comp_err(dev, "data is expected to be sent as one chunk"); return -EINVAL; } /* for a single chunk data, data_offset_size is size */ if (data_offset_size < sizeof(struct ipc4_mixer_mode_config)) { - comp_err(dev, "mixin_set_config() too small data size: %u", data_offset_size); + comp_err(dev, "too small data size: %u", data_offset_size); return -EINVAL; } if (data_offset_size > SOF_IPC_MSG_MAX_SIZE) { - comp_err(dev, "mixin_set_config() too large data size: %u", data_offset_size); + comp_err(dev, "too large data size: %u", data_offset_size); return -EINVAL; } cfg = (const struct ipc4_mixer_mode_config *)fragment; if (cfg->mixer_mode_config_count < 1 || cfg->mixer_mode_config_count > MIXIN_MAX_SINKS) { - comp_err(dev, "mixin_set_config() invalid mixer_mode_config_count: %u", + comp_err(dev, "invalid mixer_mode_config_count: %u", cfg->mixer_mode_config_count); return -EINVAL; } From 70d1ff20c2bbe0c53c7a61d549572a09e0e38d70 Mon Sep 17 00:00:00 2001 From: Guennadi Liakhovetski Date: Fri, 15 Aug 2025 09:43:34 +0200 Subject: [PATCH 4/5] audio: src: remove function names Remove function names from logging, missed by automation. Signed-off-by: Guennadi Liakhovetski --- src/audio/src/src.c | 2 +- src/audio/src/src_common.c | 18 +++++++++--------- src/audio/src/src_ipc3.c | 2 +- src/audio/src/src_ipc4.c | 6 +++--- src/audio/src/src_lite.c | 2 +- 5 files changed, 15 insertions(+), 15 deletions(-) diff --git a/src/audio/src/src.c b/src/audio/src/src.c index c641807c647b..3b1eca197b6a 100644 --- a/src/audio/src/src.c +++ b/src/audio/src/src.c @@ -42,7 +42,7 @@ static int src_prepare(struct processing_module *mod, struct src_param *a = &cd->param; int ret; - comp_info(mod->dev, "src_prepare()"); + comp_info(mod->dev, "entry"); if (num_of_sources != 1 || num_of_sinks != 1) return -EINVAL; diff --git a/src/audio/src/src_common.c b/src/audio/src/src_common.c index 6331a6b9180e..acc178211069 100644 --- a/src/audio/src/src_common.c +++ b/src/audio/src/src_common.c @@ -400,7 +400,7 @@ static int src_verify_params(struct processing_module *mod) struct comp_dev *dev = mod->dev; int ret; - comp_dbg(dev, "src_verify_params()"); + comp_dbg(dev, "entry"); /* check whether params->rate (received from driver) are equal * to src->source_rate (PLAYBACK) or src->sink_rate (CAPTURE) set during @@ -485,7 +485,7 @@ int src_params_general(struct processing_module *mod, int n; int err; - comp_info(dev, "src_params()"); + comp_info(dev, "entry"); err = src_set_params(mod, sink); if (err < 0) { @@ -499,12 +499,12 @@ int src_params_general(struct processing_module *mod, return err; } - comp_info(dev, "src_params(), source_rate = %u, sink_rate = %u", + comp_info(dev, "source_rate = %u, sink_rate = %u", cd->source_rate, cd->sink_rate); - comp_dbg(dev, "src_params(), sample_container_bytes = %d, channels = %u, dev->frames = %u", + comp_dbg(dev, "sample_container_bytes = %d, channels = %u, dev->frames = %u", cd->sample_container_bytes, cd->channels_count, dev->frames); if (!cd->sink_rate) { - comp_err(dev, "src_params(), zero sink rate"); + comp_err(dev, "zero sink rate"); return -EINVAL; } @@ -567,7 +567,7 @@ int src_params_general(struct processing_module *mod, /* This is possibly due to missing coefficients for * requested rates combination. */ - comp_info(dev, "src_params(), missing coefficients for requested rates combination"); + comp_info(dev, "missing coefficients for requested rates combination"); cd->src_func = src_fallback; return -EINVAL; } @@ -660,7 +660,7 @@ int src_process(struct processing_module *mod, { struct comp_data *cd = module_get_private_data(mod); - comp_dbg(mod->dev, "src_process()"); + comp_dbg(mod->dev, "entry"); /* src component needs 1 source and 1 sink */ if (!src_get_copy_limits(cd, sources[0], sinks[0])) { @@ -693,7 +693,7 @@ int src_reset(struct processing_module *mod) { struct comp_data *cd = module_get_private_data(mod); - comp_info(mod->dev, "src_reset()"); + comp_info(mod->dev, "entry"); cd->src_func = src_fallback; src_polyphase_reset(&cd->src); @@ -705,7 +705,7 @@ __cold int src_free(struct processing_module *mod) { assert_can_be_cold(); - comp_info(mod->dev, "src_free()"); + comp_info(mod->dev, "entry"); return 0; } diff --git a/src/audio/src/src_ipc3.c b/src/audio/src/src_ipc3.c index 5964a0cd0167..b161155193fc 100644 --- a/src/audio/src/src_ipc3.c +++ b/src/audio/src/src_ipc3.c @@ -158,7 +158,7 @@ int src_init(struct processing_module *mod) struct comp_dev *dev = mod->dev; struct comp_data *cd = NULL; - comp_dbg(dev, "src_init()"); + comp_dbg(dev, "entry"); if (dev->ipc_config.type != SOF_COMP_SRC) { comp_err(dev, "Wrong IPC config type %u", diff --git a/src/audio/src/src_ipc4.c b/src/audio/src/src_ipc4.c index ea11db129291..1240a86bd48e 100644 --- a/src/audio/src/src_ipc4.c +++ b/src/audio/src/src_ipc4.c @@ -195,7 +195,7 @@ __cold int src_init(struct processing_module *mod) assert_can_be_cold(); - comp_dbg(dev, "src_init()"); + comp_dbg(dev, "entry"); if (!cfg->init_data || cfg->size != sizeof(cd->ipc_config)) { comp_err(dev, "Missing or bad size (%u) init data", @@ -221,10 +221,10 @@ __cold int src_init(struct processing_module *mod) cd->polyphase_func = NULL; src_polyphase_reset(&cd->src); - comp_dbg(dev, "src_init(), channels_count = %d, depth = %d", + comp_dbg(dev, "channels_count = %d, depth = %d", cd->ipc_config.base.audio_fmt.channels_count, cd->ipc_config.base.audio_fmt.depth); - comp_dbg(dev, "src_init(), sampling frequency = %d, sink rate = %d", + comp_dbg(dev, "sampling frequency = %d, sink rate = %d", cd->ipc_config.base.audio_fmt.sampling_frequency, cd->ipc_config.sink_rate); cd->source_rate = cd->ipc_config.base.audio_fmt.sampling_frequency; cd->sink_rate = cd->ipc_config.sink_rate; diff --git a/src/audio/src/src_lite.c b/src/audio/src/src_lite.c index 4cbedea76ad2..cefe60367bfd 100644 --- a/src/audio/src/src_lite.c +++ b/src/audio/src/src_lite.c @@ -27,7 +27,7 @@ static int src_lite_prepare(struct processing_module *mod, struct src_param *a = &cd->param; int ret; - comp_info(mod->dev, "src_prepare()"); + comp_info(mod->dev, "entry"); if (num_of_sources != 1 || num_of_sinks != 1) return -EINVAL; From e3213fa823ca19ec0e58b1d51648f78b107ff1e9 Mon Sep 17 00:00:00 2001 From: Guennadi Liakhovetski Date: Fri, 15 Aug 2025 09:29:20 +0200 Subject: [PATCH 5/5] audio: module-adapter: remove function names Remove function names from logging, missed by automation. Signed-off-by: Guennadi Liakhovetski --- src/audio/module_adapter/module/modules.c | 6 +++--- src/audio/module_adapter/module/passthrough.c | 14 +++++++------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/audio/module_adapter/module/modules.c b/src/audio/module_adapter/module/modules.c index 7d799083d70b..3bb34c449478 100644 --- a/src/audio/module_adapter/module/modules.c +++ b/src/audio/module_adapter/module/modules.c @@ -58,7 +58,7 @@ static int modules_init(struct processing_module *mod) const struct ipc4_base_module_cfg *src_cfg = &md->cfg.base_cfg; /* At this point module resources are allocated and it is moved to L2 memory. */ - comp_info(dev, "modules_init() start"); + comp_info(dev, "entry"); md->mpd.in_buff_size = src_cfg->ibs; md->mpd.out_buff_size = src_cfg->obs; @@ -84,7 +84,7 @@ static int modules_prepare(struct processing_module *mod, { struct comp_dev *dev = mod->dev; - comp_info(dev, "modules_prepare()"); + comp_info(dev, "entry"); return iadk_wrapper_prepare(module_get_private_data(mod)); } @@ -109,7 +109,7 @@ static int modules_free(struct processing_module *mod) struct comp_dev *dev = mod->dev; int ret; - comp_info(dev, "modules_free()"); + comp_info(dev, "entry"); ret = iadk_wrapper_free(module_get_private_data(mod)); if (ret) comp_err(dev, "iadk_wrapper_free failed with error: %d", ret); diff --git a/src/audio/module_adapter/module/passthrough.c b/src/audio/module_adapter/module/passthrough.c index dcb74ef0e469..484e1319ae3a 100644 --- a/src/audio/module_adapter/module/passthrough.c +++ b/src/audio/module_adapter/module/passthrough.c @@ -16,7 +16,7 @@ DECLARE_TR_CTX(passthrough_tr, SOF_UUID(passthrough_uuid), LOG_LEVEL_INFO); static int passthrough_codec_init(struct processing_module *mod) { - comp_info(mod->dev, "passthrough_codec_init() start"); + comp_info(mod->dev, "entry"); return 0; } @@ -28,7 +28,7 @@ static int passthrough_codec_prepare(struct processing_module *mod, struct module_data *codec = &mod->priv; struct comp_buffer *source = comp_dev_get_first_data_producer(dev); - comp_info(dev, "passthrough_codec_prepare()"); + comp_info(dev, "entry"); mod->period_bytes = audio_stream_period_bytes(&source->stream, dev->frames); @@ -55,7 +55,7 @@ static int passthrough_codec_init_process(struct processing_module *mod) struct module_data *codec = &mod->priv; struct comp_dev *dev = mod->dev; - comp_dbg(dev, "passthrough_codec_init_process()"); + comp_dbg(dev, "entry"); codec->mpd.produced = 0; codec->mpd.consumed = 0; @@ -72,6 +72,8 @@ passthrough_codec_process(struct processing_module *mod, struct comp_dev *dev = mod->dev; struct module_data *codec = &mod->priv; + comp_dbg(dev, "entry"); + /* Proceed only if we have enough data to fill the module buffer completely */ if (input_buffers[0].size < codec->mpd.in_buff_size) { comp_dbg(dev, "not enough data to process"); @@ -84,8 +86,6 @@ passthrough_codec_process(struct processing_module *mod, memcpy_s(codec->mpd.in_buff, codec->mpd.in_buff_size, input_buffers[0].data, codec->mpd.in_buff_size); - comp_dbg(dev, "passthrough_codec_process()"); - memcpy_s(codec->mpd.out_buff, codec->mpd.out_buff_size, codec->mpd.in_buff, codec->mpd.in_buff_size); codec->mpd.produced = mod->period_bytes; @@ -104,7 +104,7 @@ static int passthrough_codec_reset(struct processing_module *mod) { struct module_data *codec = &mod->priv; - comp_info(mod->dev, "passthrough_codec_reset()"); + comp_info(mod->dev, "entry"); rfree(codec->mpd.in_buff); rfree(codec->mpd.out_buff); @@ -113,7 +113,7 @@ static int passthrough_codec_reset(struct processing_module *mod) static int passthrough_codec_free(struct processing_module *mod) { - comp_info(mod->dev, "passthrough_codec_free()"); + comp_info(mod->dev, "entry"); /* Nothing to do */ return 0;