Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

mfd: rk808: Disable the under voltage detect

Rk808 has a under voltage detect function, when the voltage of buck is
under 85% the target voltage, the buck output will reset. But if the
power load is too heavy, this function maybe err, when current over
4.2A, although the voltage is normal, but RK808 mistakenly think it is
under 85%, and reset the buck. So let's disable this function.

Signed-off-by: Chris Zhong <zyw@rock-chips.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>

authored by

Chris Zhong and committed by
Lee Jones
e19f7428 9a503a7d

+4
+1
drivers/mfd/rk808.c
··· 89 89 { RK808_BOOST_CONFIG_REG, BOOST_ILMIN_MASK, BOOST_ILMIN_100MA }, 90 90 { RK808_BUCK1_CONFIG_REG, BUCK1_RATE_MASK, BUCK_ILMIN_200MA }, 91 91 { RK808_BUCK2_CONFIG_REG, BUCK2_RATE_MASK, BUCK_ILMIN_200MA }, 92 + { RK808_DCDC_UV_ACT_REG, BUCK_UV_ACT_MASK, BUCK_UV_ACT_DISABLE}, 92 93 { RK808_VB_MON_REG, MASK_ALL, VB_LO_ACT | 93 94 VB_LO_SEL_3500MV }, 94 95 };
+3
include/linux/mfd/rk808.h
··· 156 156 #define BUCK2_RATE_MASK (3 << 3) 157 157 #define MASK_ALL 0xff 158 158 159 + #define BUCK_UV_ACT_MASK 0x0f 160 + #define BUCK_UV_ACT_DISABLE 0 161 + 159 162 #define SWITCH2_EN BIT(6) 160 163 #define SWITCH1_EN BIT(5) 161 164 #define DEV_OFF_RST BIT(3)