summaryrefslogtreecommitdiff
path: root/drivers/mfd/da9052-core.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/mfd/da9052-core.c')
-rw-r--r--drivers/mfd/da9052-core.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/drivers/mfd/da9052-core.c b/drivers/mfd/da9052-core.c
index 6ef039ea6aa2..4babd287e9c5 100644
--- a/drivers/mfd/da9052-core.c
+++ b/drivers/mfd/da9052-core.c
@@ -559,6 +559,7 @@ void da9053_power_off(void)
{
#if defined(CONFIG_MODULE_CCXMX53)
struct da9052_ssc_msg msgs[5];
+ struct da9052_ssc_msg msg_test;
int ret;
if (!da9052_data)
@@ -587,6 +588,17 @@ void da9053_power_off(void)
if (ret != 0)
printk(KERN_WARNING "DA9052: %s failure\n", __func__);
+ // Dummy read
+ msg_test.addr = DA9052_GPIO0809_REG;
+ msg_test.data = 0;
+ da9052_data->read(da9052_data, &msg_test);
+
+ // Do not unlock to disallow any other I2C access.
+
+ // A Dialog reported PMIC I2C bug needs to finish with an I2C read
+ // or the PMIC won't power up again in some cases.
+ while(1);
+
da9052_unlock(da9052_data);
#else
struct da9052_ssc_msg ssc_msg;