aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorStephen Warren <swarren@nvidia.com>2012-04-04 17:48:31 -0400
committerMark Brown <broonie@opensource.wolfsonmicro.com>2012-04-06 05:47:35 -0400
commit45f5ff8107a845854b1d1812ab1d9c5541f08b4d (patch)
treed0d532ba060e3f3db9c7e376d90d1fcb34035c04 /include
parentbacdbe077342ecc9e7b3e374cc5a41995116706a (diff)
regmap: add MMIO bus support
This is a basic memory-mapped-IO bus for regmap. It has the following features and limitations: * Registers themselves may be 8, 16, 32, or 64-bit. 64-bit is only supported on 64-bit platforms. * Register offsets are limited to precisely 32-bit. * IO is performed using readl/writel, with no provision for using the __raw_readl or readl_relaxed variants. Signed-off-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'include')
-rw-r--r--include/linux/regmap.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/linux/regmap.h b/include/linux/regmap.h
index f14588a96eaf..f6abc8d33d64 100644
--- a/include/linux/regmap.h
+++ b/include/linux/regmap.h
@@ -137,6 +137,9 @@ struct regmap *regmap_init_i2c(struct i2c_client *i2c,
137 const struct regmap_config *config); 137 const struct regmap_config *config);
138struct regmap *regmap_init_spi(struct spi_device *dev, 138struct regmap *regmap_init_spi(struct spi_device *dev,
139 const struct regmap_config *config); 139 const struct regmap_config *config);
140struct regmap *regmap_init_mmio(struct device *dev,
141 void __iomem *regs,
142 const struct regmap_config *config);
140 143
141struct regmap *devm_regmap_init(struct device *dev, 144struct regmap *devm_regmap_init(struct device *dev,
142 const struct regmap_bus *bus, 145 const struct regmap_bus *bus,
@@ -146,6 +149,9 @@ struct regmap *devm_regmap_init_i2c(struct i2c_client *i2c,
146 const struct regmap_config *config); 149 const struct regmap_config *config);
147struct regmap *devm_regmap_init_spi(struct spi_device *dev, 150struct regmap *devm_regmap_init_spi(struct spi_device *dev,
148 const struct regmap_config *config); 151 const struct regmap_config *config);
152struct regmap *devm_regmap_init_mmio(struct device *dev,
153 void __iomem *regs,
154 const struct regmap_config *config);
149 155
150void regmap_exit(struct regmap *map); 156void regmap_exit(struct regmap *map);
151int regmap_reinit_cache(struct regmap *map, 157int regmap_reinit_cache(struct regmap *map,