input: atmel_mxt_ts: Fix to reject coordinates outside active touch area
Firmware reports minimum/maximum coordinates when touches are
from outside of active area. Generate a release event in this
case to handle touches that are going to inactive area. Add
pdata entries for minimum values and check before reporting
the coordinates to userspace.
CRs-fixed: 326858
Change-Id: I385fb80eb670e539b45d232c04969c4502cdf65a
Signed-off-by: Mohan Pallaka <mpallaka@codeaurora.org>
diff --git a/arch/arm/mach-msm/board-8960.c b/arch/arm/mach-msm/board-8960.c
index 384da36..e8df203 100644
--- a/arch/arm/mach-msm/board-8960.c
+++ b/arch/arm/mach-msm/board-8960.c
@@ -1948,8 +1948,14 @@
static struct mxt_platform_data mxt_platform_data_2d = {
.config_array = mxt_config_array_2d,
.config_array_size = ARRAY_SIZE(mxt_config_array_2d),
- .x_size = 1365,
- .y_size = 767,
+ .panel_minx = 0,
+ .panel_maxx = 1365,
+ .panel_miny = 0,
+ .panel_maxy = 767,
+ .disp_minx = 0,
+ .disp_maxx = 1365,
+ .disp_miny = 0,
+ .disp_maxy = 767,
.irqflags = IRQF_TRIGGER_FALLING,
.i2c_pull_up = true,
.reset_gpio = MXT_TS_RESET_GPIO,
@@ -1970,8 +1976,14 @@
static struct mxt_platform_data mxt_platform_data_3d = {
.config_array = mxt_config_array_3d,
.config_array_size = ARRAY_SIZE(mxt_config_array_3d),
- .x_size = 1919,
- .y_size = 1199,
+ .panel_minx = 0,
+ .panel_maxx = 1919,
+ .panel_miny = 0,
+ .panel_maxy = 1199,
+ .disp_minx = 0,
+ .disp_maxx = 1919,
+ .disp_miny = 0,
+ .disp_maxy = 1199,
.irqflags = IRQF_TRIGGER_FALLING,
.i2c_pull_up = true,
.reset_gpio = MXT_TS_RESET_GPIO,