commit | f094fea68f0575286c55c06141cc89ffd0049024 | [log] [tgz] |
---|---|---|
author | Mark Brown <broonie@opensource.wolfsonmicro.com> | Tue Oct 04 22:05:47 2011 +0100 |
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | Sun Oct 09 12:36:56 2011 +0100 |
tree | 6e6ff489fd8e445ff3b1e1a33e7488395d841e1b | |
parent | 0eef6b0415f58ed16aff95af8c92514ce5c01258 [diff] |
regmap: Use bsearch() to search the register defaults Rather than open coding a binary search use the standard bsearch() using the comparison function we're already using for sort() on insert. This fixes a lockup I was observing due to iterating on min <= max rather than min < max when we fail to look up. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Dimitris Papastamos <dp@opensource.wolfsonmicro.com>