mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-09 13:49:24 -04:00
synaptics_mmi: log touch events in factory mode
Always log touch events while running in factory mode. This will allow for easier debugging of factory issues. Change-Id: I348164021d590e40751ba3c456245c3349a4d53a Signed-off-by: Konstantin Makariev <hcv867@motorola.com> Reviewed-on: https://gerrit.mot.com/1347015 SLTApproved: Slta Waiver SME-Granted: SME Approvals Granted Tested-by: Jira Key Reviewed-by: Konstantin Makariev <kmakariev@motorola.com> Submit-Approved: Jira Key
This commit is contained in:
parent
db27ede695
commit
e2c7ca421e
1 changed files with 20 additions and 1 deletions
|
|
@ -35,6 +35,7 @@
|
|||
#include <linux/reboot.h>
|
||||
#include <linux/pinctrl/consumer.h>
|
||||
#include <linux/input/mt.h>
|
||||
#include <soc/qcom/mmi_boot_info.h>
|
||||
|
||||
#if 0
|
||||
#ifdef pr_debug
|
||||
|
|
@ -4391,6 +4392,13 @@ static int synaptics_rmi4_f12_abs_report(struct synaptics_rmi4_data *rmi4_data,
|
|||
struct f12_d1_s0_type *finger_data_buf;
|
||||
struct synaptics_rmi4_packet_reg *reg_data_1 =
|
||||
&rmi4_data->f12_data_registers_ptr->regs[F12_D1_IDX];
|
||||
static int print_xy = -1;
|
||||
|
||||
if (unlikely(print_xy == -1)) {
|
||||
print_xy = 0;
|
||||
if (strncmp(bi_bootmode(), "mot-factory", strlen("mot-factory")) == 0)
|
||||
print_xy = 1;
|
||||
}
|
||||
|
||||
if (atomic_read(&rmi4_data->panel_off_flag))
|
||||
return 0;
|
||||
|
|
@ -4470,7 +4478,8 @@ static int synaptics_rmi4_f12_abs_report(struct synaptics_rmi4_data *rmi4_data,
|
|||
INPUT_REPORT_MT_SLOT_STATE(rmi4_data,
|
||||
MT_TOOL_FINGER, finger_status);
|
||||
#endif
|
||||
dev_dbg(&rmi4_data->i2c_client->dev,
|
||||
if (print_xy) {
|
||||
dev_info(&rmi4_data->i2c_client->dev,
|
||||
"%s: Finger %d:\n"
|
||||
"x = %d\n"
|
||||
"y = %d\n"
|
||||
|
|
@ -4478,6 +4487,16 @@ static int synaptics_rmi4_f12_abs_report(struct synaptics_rmi4_data *rmi4_data,
|
|||
"w = %d\n",
|
||||
__func__, finger,
|
||||
x, y, p, w);
|
||||
} else {
|
||||
dev_dbg(&rmi4_data->i2c_client->dev,
|
||||
"%s: Finger %d:\n"
|
||||
"x = %d\n"
|
||||
"y = %d\n"
|
||||
"p = %d\n"
|
||||
"w = %d\n",
|
||||
__func__, finger,
|
||||
x, y, p, w);
|
||||
}
|
||||
|
||||
input_report_abs(rmi4_data->input_dev,
|
||||
ABS_MT_POSITION_X, x);
|
||||
|
|
|
|||
Loading…
Reference in a new issue