Skip to content

Commit ac608e9

Browse files
committed
audio: eq_fir: Remove unnecessary COMP_TRIGGER_RESET in prepare()
When the module's prepare() returns an error, the module adapter propagates the error to the pipeline without advancing the component state past READY. There is nothing to reset, so the explicit comp_set_state(dev, COMP_TRIGGER_RESET) on the error paths in eq_fir_prepare() is redundant. Drop it to match eq_iir and the other modules. Signed-off-by: Seppo Ingalsuo <seppo.ingalsuo@linux.intel.com>
1 parent abf857f commit ac608e9

1 file changed

Lines changed: 1 addition & 6 deletions

File tree

src/audio/eq_fir/eq_fir.c

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -449,10 +449,8 @@ static int eq_fir_prepare(struct processing_module *mod,
449449
}
450450

451451
ret = eq_fir_params(mod);
452-
if (ret < 0) {
453-
comp_set_state(dev, COMP_TRIGGER_RESET);
452+
if (ret < 0)
454453
return ret;
455-
}
456454

457455
eq_fir_set_alignment(&sourceb->stream);
458456
channels = audio_stream_get_channels(&sinkb->stream);
@@ -473,9 +471,6 @@ static int eq_fir_prepare(struct processing_module *mod,
473471
comp_dbg(dev, "pass-through");
474472
}
475473

476-
if (ret < 0)
477-
comp_set_state(dev, COMP_TRIGGER_RESET);
478-
479474
/* Ensure concurrent changes don't mess with the playback */
480475
comp_data_blob_set_validator(cd->model_handler, eq_fir_validator);
481476

0 commit comments

Comments
 (0)