diff --git a/drivers/input/touchscreen/himax_v2_mmi/himax_common.c b/drivers/input/touchscreen/himax_v2_mmi/himax_common.c index 0911109c5deb..3b82778c2e4a 100644 --- a/drivers/input/touchscreen/himax_v2_mmi/himax_common.c +++ b/drivers/input/touchscreen/himax_v2_mmi/himax_common.c @@ -3613,7 +3613,11 @@ FW_force_upgrade: E("%s: create ts_resume workqueue failed\n", __func__); goto err_create_ts_resume_wq_failed; } +#if defined(__HIMAX_HX83102D_MOD__) + INIT_DELAYED_WORK(&ts->ts_int_work, himax_resume_work_func); +#else INIT_WORK(&ts->ts_int_work, himax_resume_work_func); +#endif #endif /*Himax Power On and Load Config*/ if (himax_loadSensorConfig(pdata)) { @@ -3758,7 +3762,11 @@ err_input_register_device_failed: input_free_device(ts->input_dev); err_detect_failed: #ifdef HX_RESUME_SET_FW +#if defined(__HIMAX_HX83102D_MOD__) + cancel_delayed_work_sync(&ts->ts_int_work); +#else cancel_work_sync(&ts->ts_int_work); +#endif destroy_workqueue(ts->ts_int_workqueue); err_create_ts_resume_wq_failed: #endif diff --git a/drivers/input/touchscreen/himax_v2_mmi/himax_common.h b/drivers/input/touchscreen/himax_v2_mmi/himax_common.h index 556077a51da9..4f016cf22ec4 100755 --- a/drivers/input/touchscreen/himax_v2_mmi/himax_common.h +++ b/drivers/input/touchscreen/himax_v2_mmi/himax_common.h @@ -455,7 +455,11 @@ struct himax_ts_data { #endif #ifdef HX_RESUME_SET_FW struct workqueue_struct *ts_int_workqueue; +#if defined(__HIMAX_HX83102D_MOD__) + struct delayed_work ts_int_work; +#else struct work_struct ts_int_work; +#endif #endif struct workqueue_struct *himax_diag_wq; diff --git a/drivers/input/touchscreen/himax_v2_mmi/himax_ic_incell_core.c b/drivers/input/touchscreen/himax_v2_mmi/himax_ic_incell_core.c index 6b24758c5ea7..c78c28c633ff 100755 --- a/drivers/input/touchscreen/himax_v2_mmi/himax_ic_incell_core.c +++ b/drivers/input/touchscreen/himax_v2_mmi/himax_ic_incell_core.c @@ -2026,13 +2026,21 @@ static void himax_mcu_pin_reset(void) I("%s: Now reset the Touch chip,private_ts->vdd_1v8_always_on = %d \n", __func__,private_ts->vdd_1v8_always_on); himax_rst_gpio_set(private_ts->rst_gpio, 0); +#if defined(__HIMAX_HX83102_MOD__) + msleep(5); +#else if(private_ts->vdd_1v8_always_on) msleep(10); else msleep(20); +#endif himax_rst_gpio_set(private_ts->rst_gpio, 1); #ifdef HX_ZERO_FLASH +#if defined(__HIMAX_HX83102_MOD__) + msleep(2); +#else msleep(10); +#endif #else msleep(50); #endif diff --git a/drivers/input/touchscreen/himax_v2_mmi/himax_platform_QCT_SPI.c b/drivers/input/touchscreen/himax_v2_mmi/himax_platform_QCT_SPI.c index 5ecbe43fd1b0..d4c8f649b173 100755 --- a/drivers/input/touchscreen/himax_v2_mmi/himax_platform_QCT_SPI.c +++ b/drivers/input/touchscreen/himax_v2_mmi/himax_platform_QCT_SPI.c @@ -874,7 +874,12 @@ void himax_resume_thread_func(void) { struct himax_ts_data *ts = private_ts; I("%s: TP resume from thread\n", __func__); +#if defined(__HIMAX_HX83102D_MOD__) + queue_delayed_work(ts->ts_int_workqueue, + &ts->ts_int_work, msecs_to_jiffies(60)); +#else queue_work(ts->ts_int_workqueue, &ts->ts_int_work); +#endif return; } #endif @@ -936,6 +941,12 @@ int drm_notifier_callback(struct notifier_block *self, } #endif break; +#if defined(__HIMAX_HX83102D_MOD__) + case MSM_DRM_BLANK_UNBLANK: + D("DRM_EARLY_EVENT_BLANK resume.\n"); + himax_common_resume(ts->dev); + return 0; +#endif } }