diff options
author | Josh Cartwright <joshc@codeaurora.org> | 2014-02-12 14:44:27 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-02-15 14:55:28 -0500 |
commit | c9afbb05a9ffbef0976242ab1135af6814ccff0f (patch) | |
tree | 2fc72c3dabe1bf6963661cdf6797a434464dfe1f /include/linux/regmap.h | |
parent | 2c9e577d979b87b1c500a736b68319830a984a2f (diff) |
regmap: spmi: support base and extended register spaces
SPMI states that a slave may contain two register spaces, the Base
register space is a 5-bit byte-addressable space accessed via the
Register Read/Write and Register Zero Write command sequences, and the
Extended register space: a 16-bit byte-addressable space accessed via
the Extended Read/Write and Extended Read/Write Long command sequences.
Provide support for accessing both of these spaces, taking advantage of
the more bandwidth-efficient commands ('Register 0 Write' vs 'Register
Write', and 'Extended Register Read/Write' vs 'Extended Register
Read/Write Long') when possible.
Signed-off-by: Josh Cartwright <joshc@codeaurora.org>
Acked-by: Mark Brown <broonie@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include/linux/regmap.h')
-rw-r--r-- | include/linux/regmap.h | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/include/linux/regmap.h b/include/linux/regmap.h index 4149f1a9b003..8cc73ac6f888 100644 --- a/include/linux/regmap.h +++ b/include/linux/regmap.h | |||
@@ -321,8 +321,10 @@ struct regmap *regmap_init_i2c(struct i2c_client *i2c, | |||
321 | const struct regmap_config *config); | 321 | const struct regmap_config *config); |
322 | struct regmap *regmap_init_spi(struct spi_device *dev, | 322 | struct regmap *regmap_init_spi(struct spi_device *dev, |
323 | const struct regmap_config *config); | 323 | const struct regmap_config *config); |
324 | struct regmap *regmap_init_spmi(struct spmi_device *dev, | 324 | struct regmap *regmap_init_spmi_base(struct spmi_device *dev, |
325 | const struct regmap_config *config); | 325 | const struct regmap_config *config); |
326 | struct regmap *regmap_init_spmi_ext(struct spmi_device *dev, | ||
327 | const struct regmap_config *config); | ||
326 | struct regmap *regmap_init_mmio_clk(struct device *dev, const char *clk_id, | 328 | struct regmap *regmap_init_mmio_clk(struct device *dev, const char *clk_id, |
327 | void __iomem *regs, | 329 | void __iomem *regs, |
328 | const struct regmap_config *config); | 330 | const struct regmap_config *config); |
@@ -335,8 +337,10 @@ struct regmap *devm_regmap_init_i2c(struct i2c_client *i2c, | |||
335 | const struct regmap_config *config); | 337 | const struct regmap_config *config); |
336 | struct regmap *devm_regmap_init_spi(struct spi_device *dev, | 338 | struct regmap *devm_regmap_init_spi(struct spi_device *dev, |
337 | const struct regmap_config *config); | 339 | const struct regmap_config *config); |
338 | struct regmap *devm_regmap_init_spmi(struct spmi_device *dev, | 340 | struct regmap *devm_regmap_init_spmi_base(struct spmi_device *dev, |
339 | const struct regmap_config *config); | 341 | const struct regmap_config *config); |
342 | struct regmap *devm_regmap_init_spmi_ext(struct spmi_device *dev, | ||
343 | const struct regmap_config *config); | ||
340 | struct regmap *devm_regmap_init_mmio_clk(struct device *dev, const char *clk_id, | 344 | struct regmap *devm_regmap_init_mmio_clk(struct device *dev, const char *clk_id, |
341 | void __iomem *regs, | 345 | void __iomem *regs, |
342 | const struct regmap_config *config); | 346 | const struct regmap_config *config); |