Skip to content

Commit

Permalink
Audio: Simplify multiband_drc_setup return logic
Browse files Browse the repository at this point in the history
Replaces intermediate variable and redundant comments with a direct
call to return multiband_drc_init_coef function.

Signed-off-by: Shriram Shastry <[email protected]>
  • Loading branch information
ShriramShastry authored and cujomalainey committed Jun 28, 2024
1 parent e138709 commit 8d1eea2
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions src/audio/multiband_drc/multiband_drc.c
Original file line number Diff line number Diff line change
Expand Up @@ -198,17 +198,12 @@ static int multiband_drc_init_coef(struct processing_module *mod, int16_t nch, u
static int multiband_drc_setup(struct processing_module *mod, int16_t channels, uint32_t rate)
{
struct multiband_drc_comp_data *cd = module_get_private_data(mod);
int ret;

/* Reset any previous state */
multiband_drc_reset_state(&cd->state);

/* Setup Crossover, Emphasis EQ, Deemphasis EQ, and DRC */
ret = multiband_drc_init_coef(mod, channels, rate);
if (ret < 0)
return ret;

return 0;
return multiband_drc_init_coef(mod, channels, rate);
}

/*
Expand Down

0 comments on commit 8d1eea2

Please sign in to comment.