regmap: core: Split out in place value parsing

Currently the value parsing operations both return the parsed value and
modify the passed buffer. This precludes their use in places like the cache
code so split out the in place modification into a new parse_inplace()
operation.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
This commit is contained in:
Mark Brown
2013-03-04 09:04:51 +08:00
parent 325acab447
commit 8a819ff8ab
2 changed files with 38 additions and 17 deletions

View File

@@ -38,7 +38,8 @@ struct regmap_format {
unsigned int reg, unsigned int val);
void (*format_reg)(void *buf, unsigned int reg, unsigned int shift);
void (*format_val)(void *buf, unsigned int val, unsigned int shift);
unsigned int (*parse_val)(void *buf);
unsigned int (*parse_val)(const void *buf);
void (*parse_inplace)(void *buf);
};
struct regmap_async {