Skip to content

Commit c7c7a46

Browse files
lyakhlgirdwood
authored andcommitted
audio: remove function names from logging calls (6/8)
Remove verbatim function names for mfcc, rtnr, mux, src, module_adapter. Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
1 parent 0597626 commit c7c7a46

17 files changed

Lines changed: 144 additions & 144 deletions

File tree

src/audio/mfcc/mfcc.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -96,15 +96,15 @@ static int mfcc_init(struct processing_module *mod)
9696
md->private = cd;
9797
cd->model_handler = comp_data_blob_handler_new(dev);
9898
if (!cd->model_handler) {
99-
comp_err(dev, "mfcc_init(): comp_data_blob_handler_new() failed.");
99+
comp_err(dev, "comp_data_blob_handler_new() failed.");
100100
ret = -ENOMEM;
101101
goto err;
102102
}
103103

104104
/* Get configuration data */
105105
ret = comp_init_data_blob(cd->model_handler, bs, cfg->init_data);
106106
if (ret < 0) {
107-
comp_err(mod->dev, "mfcc_init(): comp_init_data_blob() failed.");
107+
comp_err(mod->dev, "comp_init_data_blob() failed.");
108108
goto err_init;
109109
}
110110

@@ -207,7 +207,7 @@ static int mfcc_prepare(struct processing_module *mod,
207207
comp_info(dev, "mfcc_prepare(), source_format = %d, sink_format = %d",
208208
source_format, sink_format);
209209
if (audio_stream_get_size(&sinkb->stream) < sink_period_bytes) {
210-
comp_err(dev, "mfcc_prepare(): sink buffer size %d is insufficient < %d",
210+
comp_err(dev, "sink buffer size %d is insufficient < %d",
211211
audio_stream_get_size(&sinkb->stream), sink_period_bytes);
212212
ret = -ENOMEM;
213213
goto err;

src/audio/mfcc/mfcc_setup.c

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -112,19 +112,19 @@ int mfcc_setup(struct processing_module *mod, int max_frames, int sample_rate, i
112112

113113
/* Check size */
114114
if (config->size != sizeof(struct sof_mfcc_config)) {
115-
comp_err(dev, "mfcc_setup(): Illegal configuration size %d.", config->size);
115+
comp_err(dev, "Illegal configuration size %d.", config->size);
116116
return -EINVAL;
117117
}
118118

119119
/* Check currently hard-coded features to match configuration request */
120120
if (!config->round_to_power_of_two || !config->snip_edges ||
121121
config->subtract_mean || config->use_energy) {
122-
comp_err(dev, "mfcc_setup(): Can't change currently hard-coded features");
122+
comp_err(dev, "Can't change currently hard-coded features");
123123
return -EINVAL;
124124
}
125125

126126
if (config->sample_frequency != sample_rate) {
127-
comp_err(dev, "mfcc_setup(): Config sample_frequency does not match stream");
127+
comp_err(dev, "Config sample_frequency does not match stream");
128128
return -EINVAL;
129129
}
130130

@@ -133,14 +133,14 @@ int mfcc_setup(struct processing_module *mod, int max_frames, int sample_rate, i
133133
state->low_freq = config->low_freq;
134134
state->high_freq = (config->high_freq == 0) ? (sample_rate >> 1) : config->high_freq;
135135
if (state->low_freq > state->high_freq) {
136-
comp_err(dev, "mfcc_setup(): Config high_freq must be larger than low_freq");
136+
comp_err(dev, "Config high_freq must be larger than low_freq");
137137
return -EINVAL;
138138
}
139139

140140
comp_info(dev, "mfcc_setup(), source_channel = %d, stream_channels = %d",
141141
config->channel, channels);
142142
if (config->channel >= channels) {
143-
comp_err(dev, "mfcc_setup(): Illegal channel");
143+
comp_err(dev, "Illegal channel");
144144
return -EINVAL;
145145
}
146146

@@ -174,7 +174,7 @@ int mfcc_setup(struct processing_module *mod, int max_frames, int sample_rate, i
174174
state->buffers = rzalloc(SOF_MEM_FLAG_USER,
175175
state->sample_buffers_size);
176176
if (!state->buffers) {
177-
comp_err(dev, "mfcc_setup(): Failed buffer allocate");
177+
comp_err(dev, "Failed buffer allocate");
178178
ret = -ENOMEM;
179179
goto exit;
180180
}
@@ -191,14 +191,14 @@ int mfcc_setup(struct processing_module *mod, int max_frames, int sample_rate, i
191191
#endif
192192
fft->fft_buf = rzalloc(SOF_MEM_FLAG_USER, fft->fft_buffer_size);
193193
if (!fft->fft_buf) {
194-
comp_err(dev, "mfcc_setup(): Failed FFT buffer allocate");
194+
comp_err(dev, "Failed FFT buffer allocate");
195195
ret = -ENOMEM;
196196
goto free_buffers;
197197
}
198198

199199
fft->fft_out = rzalloc(SOF_MEM_FLAG_USER, fft->fft_buffer_size);
200200
if (!fft->fft_out) {
201-
comp_err(dev, "mfcc_setup(): Failed FFT output allocate");
201+
comp_err(dev, "Failed FFT output allocate");
202202
ret = -ENOMEM;
203203
goto free_fft_buf;
204204
}
@@ -209,7 +209,7 @@ int mfcc_setup(struct processing_module *mod, int max_frames, int sample_rate, i
209209
fft->fft_plan = fft_plan_new(fft->fft_buf, fft->fft_out, fft->fft_padded_size,
210210
MFCC_FFT_BITS);
211211
if (!fft->fft_plan) {
212-
comp_err(dev, "mfcc_setup(): Failed FFT init");
212+
comp_err(dev, "Failed FFT init");
213213
ret = -EINVAL;
214214
goto free_fft_out;
215215
}
@@ -222,7 +222,7 @@ int mfcc_setup(struct processing_module *mod, int max_frames, int sample_rate, i
222222
/* Setup window */
223223
ret = mfcc_get_window(state, config->window);
224224
if (ret < 0) {
225-
comp_err(dev, "mfcc_setup(): Failed Window function");
225+
comp_err(dev, "Failed Window function");
226226
goto free_fft_out;
227227
}
228228

@@ -244,7 +244,7 @@ int mfcc_setup(struct processing_module *mod, int max_frames, int sample_rate, i
244244
fb->scratch_length2 = fft->fft_buffer_size / sizeof(int16_t);
245245
ret = psy_get_mel_filterbank(fb);
246246
if (ret < 0) {
247-
comp_err(dev, "mfcc_setup(): Failed Mel filterbank");
247+
comp_err(dev, "Failed Mel filterbank");
248248
goto free_fft_out;
249249
}
250250

@@ -255,15 +255,15 @@ int mfcc_setup(struct processing_module *mod, int max_frames, int sample_rate, i
255255
dct->ortho = true;
256256
ret = dct_initialize_16(dct);
257257
if (ret < 0) {
258-
comp_err(dev, "mfcc_setup(): Failed DCT init");
258+
comp_err(dev, "Failed DCT init");
259259
goto free_melfb_data;
260260
}
261261

262262
state->lifter.num_ceps = config->num_ceps;
263263
state->lifter.cepstral_lifter = config->cepstral_lifter; /* Q7.9 max 64.0*/
264264
ret = mfcc_get_cepstral_lifter(&state->lifter);
265265
if (ret < 0) {
266-
comp_err(dev, "mfcc_setup(): Failed cepstral lifter");
266+
comp_err(dev, "Failed cepstral lifter");
267267
goto free_dct_matrix;
268268
}
269269

src/audio/module_adapter/module/cadence.c

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ static int cadence_codec_resolve_api(struct processing_module *mod)
117117

118118
/* For ipc4 protocol codec parameters has to be retrieved from configuration */
119119
if (!codec->cfg.data) {
120-
comp_err(dev, "cadence_codec_resolve_api(): could not find cadence config");
120+
comp_err(dev, "could not find cadence config");
121121
return -EINVAL;
122122
}
123123
param = codec->cfg.data;
@@ -133,7 +133,7 @@ static int cadence_codec_resolve_api(struct processing_module *mod)
133133

134134
/* Verify API assignment */
135135
if (!api) {
136-
comp_err(dev, "cadence_codec_resolve_api(): could not find API function for id %x",
136+
comp_err(dev, "could not find API function for id %x",
137137
api_id);
138138
return -EINVAL;
139139
}
@@ -193,7 +193,7 @@ static int cadence_codec_resolve_api(struct processing_module *mod)
193193

194194
/* Verify API assignment */
195195
if (!api) {
196-
comp_err(dev, "cadence_codec_resolve_api(): could not find API function for id %x",
196+
comp_err(dev, "could not find API function for id %x",
197197
api_id);
198198
return -EINVAL;
199199
}
@@ -237,11 +237,11 @@ static int cadence_codec_post_init(struct processing_module *mod)
237237
/* Allocate space for codec object */
238238
cd->self = rballoc(SOF_MEM_FLAG_USER, obj_size);
239239
if (!cd->self) {
240-
comp_err(dev, "cadence_codec_init(): failed to allocate space for lib object");
240+
comp_err(dev, "failed to allocate space for lib object");
241241
return -ENOMEM;
242242
}
243243

244-
comp_dbg(dev, "cadence_codec_post_init(): allocated %d bytes for lib object", obj_size);
244+
comp_dbg(dev, "allocated %d bytes for lib object", obj_size);
245245

246246
/* Set all params to their default values */
247247
API_CALL(cd, XA_API_CMD_INIT, XA_CMD_TYPE_INIT_API_PRE_CONFIG_PARAMS,
@@ -270,7 +270,7 @@ static int cadence_codec_init(struct processing_module *mod)
270270

271271
cd = rzalloc(SOF_MEM_FLAG_USER, sizeof(struct cadence_codec_data));
272272
if (!cd) {
273-
comp_err(dev, "cadence_codec_init(): failed to allocate memory for cadence codec data");
273+
comp_err(dev, "failed to allocate memory for cadence codec data");
274274
return -ENOMEM;
275275
}
276276

@@ -287,7 +287,7 @@ static int cadence_codec_init(struct processing_module *mod)
287287
setup_cfg->data = rmalloc(SOF_MEM_FLAG_USER,
288288
cfg->param_size);
289289
if (!setup_cfg->data) {
290-
comp_err(dev, "cadence_codec_init(): failed to alloc setup config");
290+
comp_err(dev, "failed to alloc setup config");
291291
ret = -ENOMEM;
292292
goto free;
293293
}
@@ -296,7 +296,7 @@ static int cadence_codec_init(struct processing_module *mod)
296296
codec->cfg.data = rmalloc(SOF_MEM_FLAG_USER,
297297
cfg->param_size);
298298
if (!codec->cfg.data) {
299-
comp_err(dev, "cadence_codec_init(): failed to alloc runtime setup config");
299+
comp_err(dev, "failed to alloc runtime setup config");
300300
ret = -ENOMEM;
301301
goto free_cfg;
302302
}
@@ -305,7 +305,7 @@ static int cadence_codec_init(struct processing_module *mod)
305305
ret = memcpy_s(codec->cfg.data, codec->cfg.size,
306306
cfg->param, cfg->param_size);
307307
if (ret) {
308-
comp_err(dev, "cadence_codec_init(): failed to init runtime config %d",
308+
comp_err(dev, "failed to init runtime config %d",
309309
ret);
310310
goto free_cfg2;
311311
}
@@ -315,7 +315,7 @@ static int cadence_codec_init(struct processing_module *mod)
315315
ret = memcpy_s(setup_cfg->data, setup_cfg->size,
316316
cfg->param, cfg->param_size);
317317
if (ret) {
318-
comp_err(dev, "cadence_codec_init(): failed to copy setup config %d", ret);
318+
comp_err(dev, "failed to copy setup config %d", ret);
319319
goto free_cfg2;
320320
}
321321
setup_cfg->avail = true;
@@ -347,7 +347,7 @@ static int cadence_codec_init(struct processing_module *mod)
347347

348348
cd = rzalloc(SOF_MEM_FLAG_USER, sizeof(struct cadence_codec_data));
349349
if (!cd) {
350-
comp_err(dev, "cadence_codec_init(): failed to allocate memory for cadence codec data");
350+
comp_err(dev, "failed to allocate memory for cadence codec data");
351351
return -ENOMEM;
352352
}
353353

@@ -362,7 +362,7 @@ static int cadence_codec_init(struct processing_module *mod)
362362
setup_cfg->data = rmalloc(SOF_MEM_FLAG_USER,
363363
codec->cfg.size);
364364
if (!setup_cfg->data) {
365-
comp_err(dev, "cadence_codec_init(): failed to alloc setup config");
365+
comp_err(dev, "failed to alloc setup config");
366366
ret = -ENOMEM;
367367
goto free;
368368
}
@@ -372,7 +372,7 @@ static int cadence_codec_init(struct processing_module *mod)
372372
ret = memcpy_s(setup_cfg->data, setup_cfg->size,
373373
codec->cfg.init_data, setup_cfg->size);
374374
if (ret) {
375-
comp_err(dev, "cadence_codec_init(): failed to copy setup config %d", ret);
375+
comp_err(dev, "failed to copy setup config %d", ret);
376376
goto free_cfg;
377377
}
378378
setup_cfg->avail = true;
@@ -447,12 +447,12 @@ static int cadence_codec_apply_config(struct processing_module *mod)
447447
param->data, ret);
448448
if (ret != LIB_NO_ERROR) {
449449
if (LIB_IS_FATAL_ERROR(ret)) {
450-
comp_err(dev, "cadence_codec_apply_config(): failed to apply parameter: %d value: %d error: %#x",
450+
comp_err(dev, "failed to apply parameter: %d value: %d error: %#x",
451451
param->id, *(int32_t *)param->data, ret);
452452

453453
return ret;
454454
}
455-
comp_warn(dev, "cadence_codec_apply_config(): applied parameter %d value %d with return code: %#x",
455+
comp_warn(dev, "applied parameter %d value %d with return code: %#x",
456456
param->id, *(int32_t *)param->data, ret);
457457
}
458458
/* Obtain next parameter, it starts right after the preceding one */
@@ -694,7 +694,7 @@ static int cadence_codec_prepare(struct processing_module *mod,
694694
return -ENOMEM;
695695
}
696696

697-
comp_dbg(dev, "cadence_codec_prepare(): allocated %d bytes for memtabs", mem_tabs_size);
697+
comp_dbg(dev, "allocated %d bytes for memtabs", mem_tabs_size);
698698

699699
API_CALL(cd, XA_API_CMD_SET_MEMTABS_PTR, 0, cd->mem_tabs, ret);
700700
if (ret != LIB_NO_ERROR) {
@@ -757,7 +757,7 @@ cadence_codec_process(struct processing_module *mod,
757757

758758
/* Proceed only if we have enough data to fill the module buffer completely */
759759
if (input_buffers[0].size < codec->mpd.in_buff_size) {
760-
comp_dbg(dev, "cadence_codec_process(): not enough data to process");
760+
comp_dbg(dev, "not enough data to process");
761761
return -ENODATA;
762762
}
763763

@@ -896,12 +896,12 @@ cadence_codec_set_configuration(struct processing_module *mod, uint32_t config_i
896896
/* whole configuration received, apply it now */
897897
ret = cadence_codec_apply_config(mod);
898898
if (ret) {
899-
comp_err(dev, "cadence_codec_set_configuration(): error %x: runtime config apply failed",
899+
comp_err(dev, "error %x: runtime config apply failed",
900900
ret);
901901
return ret;
902902
}
903903

904-
comp_dbg(dev, "cadence_codec_set_configuration(): config applied");
904+
comp_dbg(dev, "config applied");
905905

906906
return 0;
907907
}

0 commit comments

Comments
 (0)