]> git.baikalelectronics.ru Git - kernel.git/commit
ASoC: sta32x: Optimize the array work to find rate_min and rate_max
authorAxel Lin <axel.lin@gmail.com>
Sun, 1 Jan 2012 10:36:14 +0000 (18:36 +0800)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Tue, 3 Jan 2012 21:18:32 +0000 (21:18 +0000)
commitefd85ac2a04c9d29aafdfa1fc15d4f03a80939c6
tree0769a57dd4077484e4bdb91fa52bfa14322407da
parentcf50744fe3bf76b3500c70a5e9ba0b091cade8b6
ASoC: sta32x: Optimize the array work to find rate_min and rate_max

For a given ir and fs, there is at most one possible match for the case
mclk_ratios[ir][j].ratio * fs == freq.
Thus we can break from the inner loop once a match is found.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Johannes Stezenbach <js@sig21.net>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
sound/soc/codecs/sta32x.c