aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/mfd/abx500/ab8500-bm.h
diff options
context:
space:
mode:
authorLee Jones <lee.jones@linaro.org>2013-02-14 07:39:15 -0500
committerLee Jones <lee.jones@linaro.org>2013-03-06 23:35:46 -0500
commitdb43e6c473b57d4e7a55c4bd6edef71f40f13eae (patch)
tree0fbe4762c914ba15898cf8bcb9bd8e531fe8fc31 /include/linux/mfd/abx500/ab8500-bm.h
parent405fea1c6691eb8259f2ca879c9348a4cf5d898d (diff)
ab8500-bm: Add usb power path support
AB8540 supports power path function in USB charging mode for fast power up with dead and weak battery, and it could extend the battery age. When USB charging starts, if the Vbattrue is below than SW cut off voltage, power path and pre-charge should be enabled. If Vbattrue is higher than SW cut off voltage, power path and pre-charge should be disabled. This is to make sure full current to battery charge. At the end of charge, power path should be enable again to reduce charging the battery again. Signed-off-by: Lee Jones <lee.jones@linaro.org>
Diffstat (limited to 'include/linux/mfd/abx500/ab8500-bm.h')
-rw-r--r--include/linux/mfd/abx500/ab8500-bm.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/include/linux/mfd/abx500/ab8500-bm.h b/include/linux/mfd/abx500/ab8500-bm.h
index a73e05a0441b..0ebf0c5d1f88 100644
--- a/include/linux/mfd/abx500/ab8500-bm.h
+++ b/include/linux/mfd/abx500/ab8500-bm.h
@@ -69,6 +69,8 @@
69#define AB8500_USBCH_CTRL1_REG 0xC0 69#define AB8500_USBCH_CTRL1_REG 0xC0
70#define AB8500_USBCH_CTRL2_REG 0xC1 70#define AB8500_USBCH_CTRL2_REG 0xC1
71#define AB8500_USBCH_IPT_CRNTLVL_REG 0xC2 71#define AB8500_USBCH_IPT_CRNTLVL_REG 0xC2
72#define AB8540_USB_PP_MODE_REG 0xC5
73#define AB8540_USB_PP_CHR_REG 0xC6
72 74
73/* 75/*
74 * Gas Gauge register offsets 76 * Gas Gauge register offsets
@@ -259,6 +261,16 @@ enum bup_vch_sel {
259#define AB8505_RTC_PCUT_RESTART_REG 0x16 261#define AB8505_RTC_PCUT_RESTART_REG 0x16
260#define AB8505_RTC_PCUT_DEBOUNCE_REG 0x17 262#define AB8505_RTC_PCUT_DEBOUNCE_REG 0x17
261 263
264/* USB Power Path constants for ab8540 */
265#define BUS_VSYS_VOL_SELECT_MASK 0x06
266#define BUS_VSYS_VOL_SELECT_3P6V 0x00
267#define BUS_VSYS_VOL_SELECT_3P325V 0x02
268#define BUS_VSYS_VOL_SELECT_3P9V 0x04
269#define BUS_VSYS_VOL_SELECT_4P3V 0x06
270#define BUS_POWER_PATH_MODE_ENA 0x01
271#define BUS_PP_PRECHG_CURRENT_MASK 0x0E
272#define BUS_POWER_PATH_PRECHG_ENA 0x01
273
262/** 274/**
263 * struct res_to_temp - defines one point in a temp to res curve. To 275 * struct res_to_temp - defines one point in a temp to res curve. To
264 * be used in battery packs that combines the identification resistor with a 276 * be used in battery packs that combines the identification resistor with a