summaryrefslogtreecommitdiff
path: root/arch/mips/boot
diff options
context:
space:
mode:
authorNikesh Oswal <Nikesh.Oswal@wolfsonmicro.com>2015-10-21 16:16:14 +0300
committerMark Brown <broonie@kernel.org>2015-11-16 12:44:59 +0300
commit6399aea629b02a23364efcb6eea1319b8e9d1abf (patch)
tree279b4753273ad1b976fe789d5a63d10bd9d2e7fd /arch/mips/boot
parent8005c49d9aea74d382f474ce11afbbc7d7130bec (diff)
downloadlinux-6399aea629b02a23364efcb6eea1319b8e9d1abf.tar.xz
regmap: rbtree: When adding a reg do a bsearch for target node
A binary search is much more efficient rather than iterating over the rbtree in ascending order which the current code is doing. During initialisation the reg defaults are written to the cache in a large chunk and these are always sorted in the ascending order so for this situation ideally we should have iterated the rbtree in descending order. But at runtime the drivers may write into the cache in any random order so this patch selects to use a bsearch to give an optimal runtime performance and also at initialisation time when reg defaults are written the performance of binary search would be much better than iterating in ascending order which the current code was doing. Signed-off-by: Nikesh Oswal <Nikesh.Oswal@wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'arch/mips/boot')
0 files changed, 0 insertions, 0 deletions