]> git.baikalelectronics.ru Git - kernel.git/commit
regmap: Add the LZO cache support
authorDimitris Papastamos <dp@opensource.wolfsonmicro.com>
Mon, 19 Sep 2011 13:34:03 +0000 (14:34 +0100)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Mon, 19 Sep 2011 18:06:33 +0000 (19:06 +0100)
commit0cd512b0b849d0cbb95cd300c33bba75229cc7fd
tree43fca4dcf12a9d2c4690977096d88c873bef9100
parentac34f91fab5fd3ac97975928cdd56c1eeca54c75
regmap: Add the LZO cache support

This patch adds support for LZO compression when storing the register
cache.

For a typical device whose register map would normally occupy 25kB or 50kB
by using the LZO compression technique, one can get down to ~5-7kB.  There
might be a performance penalty associated with each individual read/write
due to decompressing/compressing the underlying cache, however that should not
be noticeable.  These memory benefits depend on whether the target architecture
can get rid of the memory occupied by the original register defaults cache
which is marked as __devinitconst.  Nevertheless there will be some memory
gain even if the target architecture can't get rid of the original register
map, this should be around ~30-32kB instead of 50kB.

Signed-off-by: Dimitris Papastamos <dp@opensource.wolfsonmicro.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
drivers/base/regmap/Kconfig
drivers/base/regmap/Makefile
drivers/base/regmap/internal.h
drivers/base/regmap/regcache-lzo.c [new file with mode: 0644]
drivers/base/regmap/regcache.c
include/linux/regmap.h