Skip to content

Commit

Permalink
sof: audio: eq_fir: Fix GCC-specific check
Browse files Browse the repository at this point in the history
Currently, the check to prevent too large filters from being loaded on
GCC builds of SOF does not work correctly. This commit changes where the
lengths that are being checked are read from, so that the check works
correctly.

Fixes: c0b9b40 ("EQ FIR: Add support for runtime reconfiguration")

Signed-off-by: Paul Olaru <[email protected]>
  • Loading branch information
Paul Olaru authored and lgirdwood committed Feb 20, 2023
1 parent e6baebd commit 465e6d0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/audio/eq_fir/eq_fir.c
Original file line number Diff line number Diff line change
Expand Up @@ -313,7 +313,7 @@ static int eq_fir_init_coef(struct comp_dev *dev, struct sof_eq_fir_config *conf
}

#if defined FIR_MAX_LENGTH_BUILD_SPECIFIC
if (fir[i].taps * nch > FIR_MAX_LENGTH_BUILD_SPECIFIC) {
if (eq->length * nch > FIR_MAX_LENGTH_BUILD_SPECIFIC) {
comp_err(dev, "Filter length %d exceeds limitation for build.",
fir[i].taps);
return -EINVAL;
Expand Down

0 comments on commit 465e6d0

Please sign in to comment.