From 9ed652e11c35fc9b8291fd21dc00cc9c0de8f77a Mon Sep 17 00:00:00 2001 From: =?utf8?q?=E5=BC=A0=E6=99=B4?= Date: Wed, 18 Jul 2012 16:56:51 +0800 Subject: [PATCH] rk30:phone:Close tps80032 vlow interrupt, only open it when in sleep mode --- arch/arm/mach-rk30/board-rk30-phone-twl60xx.c | 6 ++++-- drivers/mfd/twl6030-irq.c | 2 ++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/arch/arm/mach-rk30/board-rk30-phone-twl60xx.c b/arch/arm/mach-rk30/board-rk30-phone-twl60xx.c index 913055c06c78..aa12cf7d7015 100755 --- a/arch/arm/mach-rk30/board-rk30-phone-twl60xx.c +++ b/arch/arm/mach-rk30/board-rk30-phone-twl60xx.c @@ -74,6 +74,8 @@ int tps80032_pre_init(void){ twl_reg_write(CHARGERUSB_CTRLLIMIT2,TWL6030_MODULE_CHARGER, 0x0f); twl_reg_write(CHARGERUSB_CTRLLIMIT2,TWL6030_MODULE_CHARGER, 0x1f); + + twl_reg_write(0x05,TWL_MODULE_PM_MASTER,0x1d); //set vlow wakeup voltage 3.45v twl_reg_write(LDO5_CFG_TRANS,TWL_MODULE_PM_RECEIVER,0x03); //set ldo5 is disabled when in sleep mode twl_reg_write(LDO7_CFG_TRANS,TWL_MODULE_PM_RECEIVER,0x03); //set ldo7 is disabled when in sleep mode @@ -742,13 +744,13 @@ void twl60xx_pmu_early_suspend(struct regulator_dev *rdev) { printk("%s\n", __func__); - twl_reg_write(0x06,TWL_MODULE_PIH, 0x00); + twl_reg_write(REG_INT_MSK_STS_A,TWL_MODULE_PIH, 0x00); //open vlow interrupt } void twl60xx_pmu_early_resume(struct regulator_dev *rdev) { printk("%s\n", __func__); - twl_reg_write(0x06,TWL_MODULE_PIH, 0x04); + twl_reg_write(REG_INT_MSK_STS_A,TWL_MODULE_PIH, 0x04); //close vlow interrupt } #else void twl60xx_pmu_early_suspend(struct regulator_dev *rdev) diff --git a/drivers/mfd/twl6030-irq.c b/drivers/mfd/twl6030-irq.c index 59e2ea63e188..4d306b6273d0 100755 --- a/drivers/mfd/twl6030-irq.c +++ b/drivers/mfd/twl6030-irq.c @@ -557,6 +557,8 @@ int twl6030_init_irq(int irq_num, unsigned irq_base, unsigned irq_end, if (status < 0) goto fail_vlow; + twl_i2c_write_u8(TWL_MODULE_PIH, 0x04,REG_INT_MSK_STS_A); //close vlow interrupt + return status; fail_vlow: -- 2.34.1