Lines Matching defs:rate
1203 dev_err(codec_dai->dev, "Failed to set clock rate %d\n",
1478 "Failed to set TDM BCLK rate %lu: %d\n",
1509 unsigned long rate)
1513 switch (rate) {
1616 * the BCLK rate automatically.
1627 * Rounding the rate here avoids failure trying to set a
1628 * new rate on an already enabled bclk. In that
1629 * instance this will just set the same rate as is
1631 * problem, as long as the BCLK rate is suitable for the
1637 "BCLK rate mismatch against frame size");
1644 "Failed to set BCLK rate %lu: %d\n",
1980 static long da7219_wclk_round_rate(struct clk_hw *hw, unsigned long rate,
1990 if (rate < 11025)
1992 else if (rate < 12000)
1994 else if (rate < 16000)
1996 else if (rate < 22050)
1998 else if (rate < 24000)
2000 else if (rate < 32000)
2002 else if (rate < 44100)
2004 else if (rate < 48000)
2006 else if (rate < 88200)
2008 else if (rate < 96000)
2014 static int da7219_wclk_set_rate(struct clk_hw *hw, unsigned long rate,
2025 return da7219_set_sr(component, rate);
2052 static unsigned long da7219_bclk_get_factor(unsigned long rate,
2057 factor = rate / parent_rate;
2068 static long da7219_bclk_round_rate(struct clk_hw *hw, unsigned long rate,
2080 * We don't allow changing the parent rate as some BCLK rates can be
2083 * parent WCLK rate set and find the appropriate multiplier of BCLK to
2086 factor = da7219_bclk_get_factor(rate, *parent_rate);
2091 static int da7219_bclk_set_rate(struct clk_hw *hw, unsigned long rate,
2103 factor = da7219_bclk_get_factor(rate, parent_rate);