commit | c08604b8ae72b4fa1843a76fc7b403ddec49f8f4 | [log] [tgz] |
---|---|---|
author | Dimitris Papastamos <dp@opensource.wolfsonmicro.com> | Mon Oct 03 10:50:14 2011 +0100 |
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | Mon Oct 03 11:50:53 2011 +0100 |
tree | 64de79de1019dbc3fd7862693a245bb29bf25e4b | |
parent | ac77a765cb6e3b5aa41c186ad9f37db7fdad7dbe [diff] |
regmap: Optimize the lookup path to use binary search Since there are more lookups than insertions in a typical scenario, optimize the linear search into a binary search. For this to work, we need to keep reg_defaults sorted upon insertions, for now be lazy and use sort(). Signed-off-by: Dimitris Papastamos <dp@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>