diff options
author | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2011-07-20 22:35:37 +0100 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2011-08-08 15:56:50 +0900 |
commit | 93de91245b66f20dd387c2745744950a11a5c436 (patch) | |
tree | 82601d13bfc2b4c678618bf55be0e05671299338 /drivers/base/regmap/regmap.c | |
parent | 73304781274200c341996f65220d36b3cda8e217 (diff) |
regmap: Use a local header for API internals
Allowing the implementation to be multi-file.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'drivers/base/regmap/regmap.c')
-rw-r--r-- | drivers/base/regmap/regmap.c | 29 |
1 files changed, 1 insertions, 28 deletions
diff --git a/drivers/base/regmap/regmap.c b/drivers/base/regmap/regmap.c index e57f10f485a..f51efeb091c 100644 --- a/drivers/base/regmap/regmap.c +++ b/drivers/base/regmap/regmap.c @@ -15,37 +15,10 @@ #include <linux/mutex.h> #include <linux/err.h> -#include <linux/regmap.h> - #define CREATE_TRACE_POINTS #include <trace/events/regmap.h> -struct regmap; - -struct regmap_format { - size_t buf_size; - size_t reg_bytes; - size_t val_bytes; - void (*format_write)(struct regmap *map, - unsigned int reg, unsigned int val); - void (*format_reg)(void *buf, unsigned int reg); - void (*format_val)(void *buf, unsigned int val); - unsigned int (*parse_val)(void *buf); -}; - -struct regmap { - struct mutex lock; - - struct device *dev; /* Device we do I/O on */ - void *work_buf; /* Scratch buffer used to format I/O */ - struct regmap_format format; /* Buffer format */ - const struct regmap_bus *bus; - - unsigned int max_register; - bool (*writeable_reg)(struct device *dev, unsigned int reg); - bool (*readable_reg)(struct device *dev, unsigned int reg); - bool (*volatile_reg)(struct device *dev, unsigned int reg); -}; +#include "internal.h" static void regmap_format_4_12_write(struct regmap *map, unsigned int reg, unsigned int val) |