Skip to content

Commit

Permalink
ASoC: fsl_micfil: Drop unused register read
Browse files Browse the repository at this point in the history
In get_pdm_clk() REG_MICFIL_CTRL2 is read, but the result is never used.
Drop the unused code.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Acked-by: Shengjiu Wang <shengjiu.wang@gmail.com>
Link: https://lore.kernel.org/r/20220414162249.3934543-3-s.hauer@pengutronix.de
Signed-off-by: Mark Brown <broonie@kernel.org>
  • Loading branch information
Sascha Hauer authored and Mark Brown committed Apr 19, 2022
1 parent c808e27 commit 384672e
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions sound/soc/fsl/fsl_micfil.c
Original file line number Diff line number Diff line change
Expand Up @@ -148,12 +148,9 @@ static inline int get_pdm_clk(struct fsl_micfil *micfil,
static inline int get_clk_div(struct fsl_micfil *micfil,
unsigned int rate)
{
u32 ctrl2_reg;
long mclk_rate;
int clk_div;

regmap_read(micfil->regmap, REG_MICFIL_CTRL2, &ctrl2_reg);

mclk_rate = clk_get_rate(micfil->mclk);

clk_div = mclk_rate / (get_pdm_clk(micfil, rate) * 2);
Expand Down

0 comments on commit 384672e

Please sign in to comment.