Egis.FPS Call early panel power-on when finger detected

motorola/kernel/modules/drivers/input/misc/ets_fps_mmi/:
Call display panel early power-on when finger is detected.

To avoid unexpected calling on panel's early power-on, e.g. unexpected
touching on FPS, move this calling from case of interrupt received to
case of finger detected.

NO_PROP_NEEDED: This feature is only enabled on bo for now. If this
feature wants to be enabled on bq-shm2018, the cherry-pick should then
be done in the development stage of related products.

Change-Id: I8a24835a3b2c8acfdb3a4ed744501b9a7b67b8c4
Signed-off-by: chengql2 <chengql2@lenovo.com>
Reviewed-on: https://gerrit.mot.com/1706588
SLTApproved: Slta Waiver
SME-Granted: SME Approvals Granted
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
This commit is contained in:
chengql2 2020-07-27 16:14:27 +08:00 • committed by Qiuliang Cheng
commit f8fec22ac5
4 changed files with 29 additions and 17 deletions

View file

@ -17,8 +17,8 @@ ifeq ($(FPS_NAVI_ENABLE),true)
endif
endif
ifeq ($(DISPLAY_SPEED_UP), true)
KERNEL_CFLAGS += CONFIG_DISPLAY_SPEED_UP=y
ifeq ($(EGIS_DISPLAY_SPEED_UP), true)
KERNEL_CFLAGS += CONFIG_EGIS_DISPLAY_SPEED_UP=y
endif
ifeq ($(FPS_ENABLE_DOUBLE_TAP), true)

View file

@ -35,8 +35,8 @@ ifneq ($(filter rav%, $(TARGET_PRODUCT)),)
EXTRA_CFLAGS += -DCONFIG_INPUT_EGISTEC_FPS_POSE=0
endif
ifneq ($(filter m y, $(CONFIG_DISPLAY_SPEED_UP)),)
EXTRA_CFLAGS += -DCONFIG_DISPLAY_SPEED_UP
ifneq ($(filter m y, $(CONFIG_EGIS_DISPLAY_SPEED_UP)),)
EXTRA_CFLAGS += -DCONFIG_EGIS_DISPLAY_SPEED_UP
endif
ifneq ($(filter m y, $(CONFIG_NAV_DOUBLE_TAP)),)

View file

@ -246,7 +246,7 @@ void interrupt_timer_routine(unsigned long _data)
}
#endif
#ifdef CONFIG_DISPLAY_SPEED_UP
#ifdef CONFIG_EGIS_DISPLAY_SPEED_UP
extern void ext_dsi_display_early_power_on(void);
static bool is_auth_ready = false;
#endif
@ -262,11 +262,10 @@ static irqreturn_t fp_eint_func(int irq, void *dev_id)
#else
__pm_wakeup_event(ets_wake_lock, 1500);
#endif
#ifdef CONFIG_DISPLAY_SPEED_UP
if (is_auth_ready) {
pr_info("etspi: call ext_dsi_display_early_power_on()");
ext_dsi_display_early_power_on();
} else
#ifdef CONFIG_EGIS_DISPLAY_SPEED_UP
if (is_auth_ready)
pr_info("etspi: already in authentication mode");
else
pr_info("etspi: not in authentication mode");
#endif
return IRQ_HANDLED;
@ -530,11 +529,19 @@ static long etspi_ioctl(struct file *filp, unsigned int cmd, unsigned long arg)
DEBUG_PRINT("etspi:fp_ioctl <<< fp Trigger function abort\n");
fps_interrupt_abort();
goto done;
#ifdef CONFIG_DISPLAY_SPEED_UP
case SET_AUTH_STATUS:
pr_info("etspi: - set auth status: %lu", arg);
if (arg) is_auth_ready = true;
else is_auth_ready = false;
#ifdef CONFIG_EGIS_DISPLAY_SPEED_UP
case NOTIFY_AUTH_STATUS:
pr_info("etspi: - notify auth status: %lu", arg);
if (arg == AUTH_STATUS_NONE)
is_auth_ready = false;
else if (arg == AUTH_STATUS_READY)
is_auth_ready = true;
else if (arg == AUTH_STATUS_FINGER_DETECTED) {
if (is_auth_ready) {
pr_info("etspi: call ext_dsi_display_early_power_on()");
ext_dsi_display_early_power_on();
}
}
goto done;
#endif
default:

View file

@ -74,8 +74,13 @@
#define INT_TRIGGER_ABORT 0xa8
#define FP_TRANSFER_SYNC 0xAA
#ifdef CONFIG_DISPLAY_SPEED_UP
#define SET_AUTH_STATUS 0xD1
#ifdef CONFIG_EGIS_DISPLAY_SPEED_UP
#define NOTIFY_AUTH_STATUS 0xD1
#define AUTH_STATUS_NONE 0
#define AUTH_STATUS_READY 1
#define AUTH_STATUS_FINGER_DETECTED 2
#define AUTH_STATUS_CAPTURED 3
#endif
#define DRDY_IRQ_ENABLE 1