mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-07 04:12:04 -04:00
input/goodix_berlin: report pressure for passive stylus
goodix_berlin: If we use passive stylus, we need to report pressure. For goodix, the value of pressure is the same as major. Change-Id: I3e21075a7faf83beb4d519982377d080824ae002 Reviewed-on: https://gerrit.mot.com/2775276 SME-Granted: SME Approvals Granted SLTApproved: Slta Waiver Tested-by: Jira Key Reviewed-by: Yeqing Wang <wangyq13@motorola.com> Reviewed-by: <zhuwg1@motorola.com> Reviewed-by: Jun Weng <wengjun1@motorola.com> Reviewed-by: Huosheng Liao <liaohs@motorola.com> Submit-Approved: Jira Key
This commit is contained in:
parent
ab87620da1
commit
f3e51aeccc
3 changed files with 16 additions and 0 deletions
|
|
@ -42,8 +42,12 @@ ifeq ($(TOUCHSCREEN_LAST_TIME),true)
|
|||
endif
|
||||
|
||||
ifeq ($(GTP_ENABLE_DDA_STYLUS),true)
|
||||
ifeq ($(MOTO_DDA_PASSIVE_STYLUS),true)
|
||||
KBUILD_OPTIONS += CONFIG_MOTO_DDA_PASSIVE_STYLUS=y
|
||||
else
|
||||
KBUILD_OPTIONS += CONFIG_GTP_DDA_STYLUS=y
|
||||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(BOARD_USES_DOUBLE_TAP_CTRL),true)
|
||||
KBUILD_OPTIONS += CONFIG_BOARD_USES_DOUBLE_TAP_CTRL=y
|
||||
|
|
|
|||
|
|
@ -60,6 +60,10 @@ ifneq ($(filter m y,$(CONFIG_GTP_DDA_STYLUS)),)
|
|||
goodix_brl_mmi-objs += goodix_ts_dda.o
|
||||
endif
|
||||
|
||||
ifneq ($(filter m y,$(CONFIG_MOTO_DDA_PASSIVE_STYLUS)),)
|
||||
EXTRA_CFLAGS += -DCONFIG_MOTO_DDA_PASSIVESTYLUS
|
||||
endif
|
||||
|
||||
ifneq ($(filter m y,$(CONFIG_INPUT_TOUCHSCREEN_MMI)),)
|
||||
EXTRA_CFLAGS += -DCONFIG_INPUT_TOUCHSCREEN_MMI
|
||||
goodix_brl_mmi-objs += goodix_ts_mmi.o
|
||||
|
|
|
|||
|
|
@ -1266,6 +1266,10 @@ static void goodix_ts_report_finger(struct input_dev *dev,
|
|||
touch_data->coords[i].y);
|
||||
input_report_abs(dev, ABS_MT_TOUCH_MAJOR,
|
||||
touch_data->coords[i].w);
|
||||
#ifdef CONFIG_MOTO_DDA_PASSIVESTYLUS
|
||||
input_report_abs(dev, ABS_MT_PRESSURE,
|
||||
touch_data->coords[i].w);
|
||||
#endif
|
||||
} else {
|
||||
if (touchdown[i] == 1) {
|
||||
ts_debug("TOUCH: [%d] release\n", i);
|
||||
|
|
@ -1715,6 +1719,10 @@ static int goodix_ts_input_dev_config(struct goodix_ts_core *core_data)
|
|||
0, ts_bdata->panel_max_y, 0, 0);
|
||||
input_set_abs_params(input_dev, ABS_MT_TOUCH_MAJOR,
|
||||
0, ts_bdata->panel_max_w, 0, 0);
|
||||
#ifdef CONFIG_MOTO_DDA_PASSIVESTYLUS
|
||||
input_set_abs_params(input_dev, ABS_MT_PRESSURE,
|
||||
0, ts_bdata->panel_max_w, 0, 0);
|
||||
#endif
|
||||
#ifdef CONFIG_ENABLE_GTP_PALM_CANCEL
|
||||
input_set_abs_params(input_dev, ABS_MT_TOOL_TYPE,
|
||||
MT_TOOL_FINGER, MT_TOOL_PALM, 0, 0);
|
||||
|
|
|
|||
Loading…
Reference in a new issue