Actually in Android the system will try to invoke the early_suspend during a phone call. but it can not go to the deep sleep because of the wakelock. so I suggest that the psensor driver should be added the wakelock to prevent the issue.
Please add and check the follows:
Actually in Android the system will try to invoke the early_suspend during a phone call. but it can not go to the deep sleep because of the wakelock. so I suggest that the psensor driver should be added the wakelock to prevent the issue.
Please add and check the follows:
--- a/mediatek/ custom/ common/ kernel/ alsps/tmd2772_ auto/tmd2772. c custom/ common/ kernel/ alsps/tmd2772_ auto/tmd2772. c ******* ******* ******* ******* ******* ******* ******* ******* ******* ******* *** ps_operate( void* self, uint32_t command, void* buff_in, int size_in, ps_calibrate_ call(obj- >client) ; init_client( obj->client) ; &psensor_ lock); enable_ ps(obj- >client, 1)))
APS_ERR( "enable ps fail: %d\n", err); ps_operate( void* self, uint32_t command, void* buff_in, int size_in, &psensor_ lock); enable_ ps(obj- >client, 0)))
APS_ERR( "disable ps fail: %d\n", err); i2c_probe( struct i2c_client *client, const struct i2c_device_
+++ b/mediatek/
@@ -64,6 +64,7 @@ static u8 offset_data=0;
#define PRO_OFFSET 1
static u16 tmp_data=0;
#define OFFDATA_DEFAULT 1
+struct wake_lock psensor_lock;
//end
/*****
* extern functions
@@ -2417,6 +2418,7 @@ int TMD2772_
tmd2772_
TMD2772_
#endif
+ wake_lock(
if((err = TMD2772_
{
@@ -2437,6 +2439,7 @@ int TMD2772_
}
else
{
+ wake_unlock(
if((err = TMD2772_
{
@@ -2819,7 +2822,7 @@ static int TMD2772_
mutex_ init(&mutex) ; i2c_client = client; init(&psensor_ lock,WAKE_ LOCK_SUSPEND, "psensor wakelock"); >polling_ mode_ps)
TMD2772_
-
+ wake_lock_
if(1 == obj->hw-
//if (1)
{