From 70666d5d9b5d5f47058bf32029b3ff62ae8ba7e2 Mon Sep 17 00:00:00 2001 From: Jianqiu Huang Date: Tue, 27 Aug 2019 04:02:39 -0500 Subject: [PATCH] Revert "(CR) cap-sensor: Optimize power consumption issue." ABOV_CTRL_MODE_RET is defined in abov_sar.h, and in abov_sar_a96t.h file, the register name has changed to ABOV_CTRL_MODE_REG. It will cause build error. Now revert it, and resubmit it. This reverts commit 16143ccfc41d9c80827615fdd060fd6f72a41c82. Change-Id: I3605f0df5c3d6b3c1e38f01c8111bcd536044948 Reviewed-on: https://gerrit.mot.com/1411231 SME-Granted: SME Approvals Granted SLTApproved: Slta Waiver Tested-by: Jira Key Reviewed-by: Hujun Liao Submit-Approved: Jira Key --- drivers/misc/abov_a96t/abov_sar_a96t.c | 7 ------- 1 file changed, 7 deletions(-) diff --git a/drivers/misc/abov_a96t/abov_sar_a96t.c b/drivers/misc/abov_a96t/abov_sar_a96t.c index e697a3f42a1e..0ca52c5ee990 100644 --- a/drivers/misc/abov_a96t/abov_sar_a96t.c +++ b/drivers/misc/abov_a96t/abov_sar_a96t.c @@ -1855,19 +1855,12 @@ void abovXX_suspend(pabovXX_t this) if (this) { LOG_INFO("ABOV suspend: disable irq!\n"); disable_irq(this->irq); - /* if upper layer don't disable capsensor, */ - /* we should let it enter sleep in suspend. */ - if (mEnabled) - write_register(this, ABOV_CTRL_MODE_RET, 0x02); } } void abovXX_resume(pabovXX_t this) { if (this) { LOG_INFO("ABOV resume: enable irq!\n"); - /* we should let capsensor enter active in resume*/ - if (mEnabled) - write_register(this, ABOV_CTRL_MODE_RET, 0x00); enable_irq(this->irq); } }