summaryrefslogtreecommitdiff
path: root/include/linux/mfd/axp20x.h
diff options
context:
space:
mode:
authorChen-Yu Tsai <wens@csie.org>2016-11-11 11:29:52 +0800
committerLee Jones <lee.jones@linaro.org>2016-11-29 08:21:35 +0000
commit34d9030b5d06ec0072796b3ab6a3fa24e53ece3d (patch)
tree26ab97081b61d0031d3a2dc0d1b3da6a6e8e937b /include/linux/mfd/axp20x.h
parentf57576e73cc4808af3b097b1fdedfa7d0f6378a4 (diff)
mfd: axp20x: Add address extension registers for AXP806 regmap
The AXP806 supports either master/standalone or slave mode. Slave mode allows sharing the serial bus, even with multiple AXP806 which all have the same hardware address. This is done with extra "serial interface address extension", or AXP806_BUS_ADDR_EXT, and "register address extension", or AXP806_REG_ADDR_EXT, registers. The former is read-only, with 1 bit customizable at the factory, and 1 bit depending on the state of an external pin. The latter is writable. Only when the these device addressing bits (in the upper 4 bits of the registers) match, will the device respond to operations on its other registers. Add these 2 registers to the regmap so we can access them. Signed-off-by: Chen-Yu Tsai <wens@csie.org> Signed-off-by: Lee Jones <lee.jones@linaro.org>
Diffstat (limited to 'include/linux/mfd/axp20x.h')
-rw-r--r--include/linux/mfd/axp20x.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/mfd/axp20x.h b/include/linux/mfd/axp20x.h
index 6349496f09fc..a4860bc9b73d 100644
--- a/include/linux/mfd/axp20x.h
+++ b/include/linux/mfd/axp20x.h
@@ -115,6 +115,8 @@ enum {
#define AXP806_CLDO2_V_CTRL 0x25
#define AXP806_CLDO3_V_CTRL 0x26
#define AXP806_VREF_TEMP_WARN_L 0xf3
+#define AXP806_BUS_ADDR_EXT 0xfe
+#define AXP806_REG_ADDR_EXT 0xff
/* Interrupt */
#define AXP152_IRQ1_EN 0x40