regmap: debugfs: Optimize seeking within blocks of registers
authorDimitris Papastamos <dp@opensource.wolfsonmicro.com>
Fri, 8 Feb 2013 12:47:20 +0000 (12:47 +0000)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Mon, 11 Feb 2013 11:25:33 +0000 (11:25 +0000)
commitcf57d6071f0610c99856c006ac06eb98a151f485
tree18a88144112ef72369b89b0c0b4b991eea593102
parentc2c1ee66016a45477f58f0fd30907b1e959ca76b
regmap: debugfs: Optimize seeking within blocks of registers

Optimize this so that we can better guess where to start scanning
from.  We know the length of the register field format, therefore
given the file pointer position align to the nearest register
field and scan from there onwards.  We round down in this calculation
and we let the rest of the code figure out where to start scanning
from.

Signed-off-by: Dimitris Papastamos <dp@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
drivers/base/regmap/regmap-debugfs.c