Loading drivers/input/touchscreen/focaltech_touch/focaltech_core.c +7 −2 Original line number Diff line number Diff line Loading @@ -744,6 +744,7 @@ static void fts_ts_trusted_touch_abort_pvm(struct fts_ts_data *fts_data) case TRUSTED_TOUCH_PVM_INIT: case PVM_I2C_RESOURCE_RELEASED: atomic_set(&fts_data->trusted_touch_enabled, 0); atomic_set(&fts_data->trusted_touch_underway, 0); } atomic_set(&fts_data->trusted_touch_abort_status, 0); Loading Loading @@ -779,6 +780,8 @@ static int fts_ts_bus_get(struct fts_ts_data *fts_data) { int rc = 0; cancel_work_sync(&fts_data->suspend_work); cancel_work_sync(&fts_data->resume_work); reinit_completion(&fts_data->trusted_touch_powerdown); fts_ts_enable_reg(fts_data, true); mutex_lock(&fts_data->fts_clk_io_ctrl_mutex); Loading Loading @@ -856,6 +859,7 @@ static void fts_trusted_touch_pvm_vm_mode_disable(struct fts_ts_data *fts_data) fts_ts_trusted_touch_set_pvm_driver_state(fts_data, TRUSTED_TOUCH_PVM_INIT); atomic_set(&fts_data->trusted_touch_enabled, 0); atomic_set(&fts_data->trusted_touch_underway, 0); return; error: fts_ts_trusted_touch_abort_handler(fts_data, Loading Loading @@ -993,6 +997,7 @@ static int fts_ts_trusted_touch_pvm_vm_mode_enable(struct fts_ts_data *fts_data) int rc = 0; struct trusted_touch_vm_info *vm_info = fts_data->vm_info; atomic_set(&fts_data->trusted_touch_underway, 1); /* i2c session start and resource acquire */ if (fts_ts_bus_get(fts_data) < 0) { FTS_ERROR("fts_ts_bus_get failed\n"); Loading Loading @@ -2864,7 +2869,7 @@ static int fts_ts_suspend(struct device *dev) return 0; } #ifdef CONFIG_FTS_TRUSTED_TOUCH if (atomic_read(&fts_data->trusted_touch_enabled)) if (atomic_read(&fts_data->trusted_touch_underway)) wait_for_completion_interruptible( &fts_data->trusted_touch_powerdown); #endif Loading Loading @@ -2910,7 +2915,7 @@ static int fts_ts_resume(struct device *dev) } #ifdef CONFIG_ST_TRUSTED_TOUCH if (atomic_read(&ts_data->trusted_touch_enabled)) if (atomic_read(&ts_data->trusted_touch_underway)) wait_for_completion_interruptible( &ts_data->trusted_touch_powerdown); #endif Loading drivers/input/touchscreen/focaltech_touch/focaltech_core.h +1 −0 Original line number Diff line number Diff line Loading @@ -295,6 +295,7 @@ struct fts_ts_data { struct clk *iface_clk; atomic_t trusted_touch_initialized; atomic_t trusted_touch_enabled; atomic_t trusted_touch_underway; atomic_t trusted_touch_event; atomic_t trusted_touch_abort_status; atomic_t delayed_vm_probe_pending; Loading drivers/input/touchscreen/st/fts.c +8 −3 Original line number Diff line number Diff line Loading @@ -769,6 +769,7 @@ static void fts_trusted_touch_abort_pvm(struct fts_ts_info *info) case TRUSTED_TOUCH_PVM_INIT: case PVM_I2C_RESOURCE_RELEASED: atomic_set(&info->trusted_touch_enabled, 0); atomic_set(&info->trusted_touch_underway, 0); } atomic_set(&info->trusted_touch_abort_status, 0); Loading Loading @@ -807,7 +808,8 @@ static int fts_bus_get(struct fts_ts_info *info) { int rc = 0; flush_workqueue(info->event_wq); cancel_work_sync(&info->suspend_work); cancel_work_sync(&info->resume_work); reinit_completion(&info->trusted_touch_powerdown); fts_enable_reg(info, true); mutex_lock(&info->fts_clk_io_ctrl_mutex); Loading Loading @@ -884,6 +886,7 @@ static void fts_trusted_touch_pvm_vm_mode_disable(struct fts_ts_info *info) fts_trusted_touch_set_pvm_driver_state(info, TRUSTED_TOUCH_PVM_INIT); atomic_set(&info->trusted_touch_enabled, 0); atomic_set(&info->trusted_touch_underway, 0); return; error: fts_trusted_touch_abort_handler(info, Loading Loading @@ -1018,6 +1021,8 @@ static int fts_trusted_touch_pvm_vm_mode_enable(struct fts_ts_info *info) int rc = 0; struct trusted_touch_vm_info *vm_info = info->vm_info; atomic_set(&info->trusted_touch_underway, 1); /* i2c session start and resource acquire */ if (fts_bus_get(info) < 0) { dev_err(&info->client->dev, "fts_bus_get failed\n"); Loading Loading @@ -5350,7 +5355,7 @@ static void fts_resume_work(struct work_struct *work) info = container_of(work, struct fts_ts_info, resume_work); #ifdef CONFIG_ST_TRUSTED_TOUCH if (atomic_read(&info->trusted_touch_enabled)) if (atomic_read(&info->trusted_touch_underway)) wait_for_completion_interruptible( &info->trusted_touch_powerdown); #endif Loading Loading @@ -5385,7 +5390,7 @@ static void fts_suspend_work(struct work_struct *work) info = container_of(work, struct fts_ts_info, suspend_work); #ifdef CONFIG_ST_TRUSTED_TOUCH if (atomic_read(&info->trusted_touch_enabled)) if (atomic_read(&info->trusted_touch_underway)) wait_for_completion_interruptible( &info->trusted_touch_powerdown); #endif Loading drivers/input/touchscreen/st/fts.h +1 −0 Original line number Diff line number Diff line Loading @@ -416,6 +416,7 @@ struct fts_ts_info { struct clk *core_clk; struct clk *iface_clk; atomic_t trusted_touch_initialized; atomic_t trusted_touch_underway; atomic_t trusted_touch_enabled; atomic_t trusted_touch_event; atomic_t trusted_touch_abort_status; Loading Loading
drivers/input/touchscreen/focaltech_touch/focaltech_core.c +7 −2 Original line number Diff line number Diff line Loading @@ -744,6 +744,7 @@ static void fts_ts_trusted_touch_abort_pvm(struct fts_ts_data *fts_data) case TRUSTED_TOUCH_PVM_INIT: case PVM_I2C_RESOURCE_RELEASED: atomic_set(&fts_data->trusted_touch_enabled, 0); atomic_set(&fts_data->trusted_touch_underway, 0); } atomic_set(&fts_data->trusted_touch_abort_status, 0); Loading Loading @@ -779,6 +780,8 @@ static int fts_ts_bus_get(struct fts_ts_data *fts_data) { int rc = 0; cancel_work_sync(&fts_data->suspend_work); cancel_work_sync(&fts_data->resume_work); reinit_completion(&fts_data->trusted_touch_powerdown); fts_ts_enable_reg(fts_data, true); mutex_lock(&fts_data->fts_clk_io_ctrl_mutex); Loading Loading @@ -856,6 +859,7 @@ static void fts_trusted_touch_pvm_vm_mode_disable(struct fts_ts_data *fts_data) fts_ts_trusted_touch_set_pvm_driver_state(fts_data, TRUSTED_TOUCH_PVM_INIT); atomic_set(&fts_data->trusted_touch_enabled, 0); atomic_set(&fts_data->trusted_touch_underway, 0); return; error: fts_ts_trusted_touch_abort_handler(fts_data, Loading Loading @@ -993,6 +997,7 @@ static int fts_ts_trusted_touch_pvm_vm_mode_enable(struct fts_ts_data *fts_data) int rc = 0; struct trusted_touch_vm_info *vm_info = fts_data->vm_info; atomic_set(&fts_data->trusted_touch_underway, 1); /* i2c session start and resource acquire */ if (fts_ts_bus_get(fts_data) < 0) { FTS_ERROR("fts_ts_bus_get failed\n"); Loading Loading @@ -2864,7 +2869,7 @@ static int fts_ts_suspend(struct device *dev) return 0; } #ifdef CONFIG_FTS_TRUSTED_TOUCH if (atomic_read(&fts_data->trusted_touch_enabled)) if (atomic_read(&fts_data->trusted_touch_underway)) wait_for_completion_interruptible( &fts_data->trusted_touch_powerdown); #endif Loading Loading @@ -2910,7 +2915,7 @@ static int fts_ts_resume(struct device *dev) } #ifdef CONFIG_ST_TRUSTED_TOUCH if (atomic_read(&ts_data->trusted_touch_enabled)) if (atomic_read(&ts_data->trusted_touch_underway)) wait_for_completion_interruptible( &ts_data->trusted_touch_powerdown); #endif Loading
drivers/input/touchscreen/focaltech_touch/focaltech_core.h +1 −0 Original line number Diff line number Diff line Loading @@ -295,6 +295,7 @@ struct fts_ts_data { struct clk *iface_clk; atomic_t trusted_touch_initialized; atomic_t trusted_touch_enabled; atomic_t trusted_touch_underway; atomic_t trusted_touch_event; atomic_t trusted_touch_abort_status; atomic_t delayed_vm_probe_pending; Loading
drivers/input/touchscreen/st/fts.c +8 −3 Original line number Diff line number Diff line Loading @@ -769,6 +769,7 @@ static void fts_trusted_touch_abort_pvm(struct fts_ts_info *info) case TRUSTED_TOUCH_PVM_INIT: case PVM_I2C_RESOURCE_RELEASED: atomic_set(&info->trusted_touch_enabled, 0); atomic_set(&info->trusted_touch_underway, 0); } atomic_set(&info->trusted_touch_abort_status, 0); Loading Loading @@ -807,7 +808,8 @@ static int fts_bus_get(struct fts_ts_info *info) { int rc = 0; flush_workqueue(info->event_wq); cancel_work_sync(&info->suspend_work); cancel_work_sync(&info->resume_work); reinit_completion(&info->trusted_touch_powerdown); fts_enable_reg(info, true); mutex_lock(&info->fts_clk_io_ctrl_mutex); Loading Loading @@ -884,6 +886,7 @@ static void fts_trusted_touch_pvm_vm_mode_disable(struct fts_ts_info *info) fts_trusted_touch_set_pvm_driver_state(info, TRUSTED_TOUCH_PVM_INIT); atomic_set(&info->trusted_touch_enabled, 0); atomic_set(&info->trusted_touch_underway, 0); return; error: fts_trusted_touch_abort_handler(info, Loading Loading @@ -1018,6 +1021,8 @@ static int fts_trusted_touch_pvm_vm_mode_enable(struct fts_ts_info *info) int rc = 0; struct trusted_touch_vm_info *vm_info = info->vm_info; atomic_set(&info->trusted_touch_underway, 1); /* i2c session start and resource acquire */ if (fts_bus_get(info) < 0) { dev_err(&info->client->dev, "fts_bus_get failed\n"); Loading Loading @@ -5350,7 +5355,7 @@ static void fts_resume_work(struct work_struct *work) info = container_of(work, struct fts_ts_info, resume_work); #ifdef CONFIG_ST_TRUSTED_TOUCH if (atomic_read(&info->trusted_touch_enabled)) if (atomic_read(&info->trusted_touch_underway)) wait_for_completion_interruptible( &info->trusted_touch_powerdown); #endif Loading Loading @@ -5385,7 +5390,7 @@ static void fts_suspend_work(struct work_struct *work) info = container_of(work, struct fts_ts_info, suspend_work); #ifdef CONFIG_ST_TRUSTED_TOUCH if (atomic_read(&info->trusted_touch_enabled)) if (atomic_read(&info->trusted_touch_underway)) wait_for_completion_interruptible( &info->trusted_touch_powerdown); #endif Loading
drivers/input/touchscreen/st/fts.h +1 −0 Original line number Diff line number Diff line Loading @@ -416,6 +416,7 @@ struct fts_ts_info { struct clk *core_clk; struct clk *iface_clk; atomic_t trusted_touch_initialized; atomic_t trusted_touch_underway; atomic_t trusted_touch_enabled; atomic_t trusted_touch_event; atomic_t trusted_touch_abort_status; Loading