[meta-freescale] Issue with egalax_ts in linux-boundary

Erik Botö erik.boto at pelagicore.com
Tue Jul 2 01:13:43 PDT 2013


Hi,

On Mon, Jul 1, 2013 at 8:59 PM, Erik Botö <erik.boto at pelagicore.com> wrote:
> Now
> that I frase it this way I realize it should probably be removed from
> the "if (down) else ()"-statement and always done before input_sync()
> instead. I'll post an updated patch-suggestion tomorrow.

And here's the updated version. I simple moved the loop that reports all
touch points outside of the if-else statement.

Cheers,
Erik Botö

diff -uNr git.orig/drivers/input/touchscreen/egalax_ts.c
git/drivers/input/touchscreen/egalax_ts.c
--- git.orig/drivers/input/touchscreen/egalax_ts.c 2013-07-02
08:04:22.456501162 +0200
+++ git/drivers/input/touchscreen/egalax_ts.c 2013-07-02 08:05:53.684507633
+0200
@@ -133,7 +133,6 @@
  }

  if (down) {
- /* should also report old pointers */
  events[id].valid = valid;
  events[id].status = down;
  events[id].x = x;
@@ -144,23 +143,6 @@
  input_report_abs(input_dev, ABS_Y, y);
  input_event(data->input_dev, EV_KEY, BTN_TOUCH, 1);
  input_report_abs(input_dev, ABS_PRESSURE, 1);
-#else
- for (i = 0; i < MAX_SUPPORT_POINTS; i++) {
- if (!events[i].valid)
- continue;
- dev_dbg(&client->dev, "report id:%d valid:%d x:%d y:%d",
- i, valid, x, y);
-
- input_report_abs(input_dev,
- ABS_MT_TRACKING_ID, i);
- input_report_abs(input_dev,
- ABS_MT_TOUCH_MAJOR, 1);
- input_report_abs(input_dev,
- ABS_MT_POSITION_X, events[i].x);
- input_report_abs(input_dev,
- ABS_MT_POSITION_Y, events[i].y);
- input_mt_sync(input_dev);
- }
 #endif
  } else {
  dev_dbg(&client->dev, "release id:%d\n", id);
@@ -176,6 +158,24 @@
 #endif
  }

+#ifndef CONFIG_TOUCHSCREEN_EGALAX_SINGLE_TOUCH
+ /* report all pointers */
+ for (i = 0; i < MAX_SUPPORT_POINTS; i++) {
+ if (!events[i].valid)
+ continue;
+ dev_dbg(&client->dev, "report id:%d valid:%d x:%d y:%d",
+ i, valid, x, y);
+ input_report_abs(input_dev,
+ ABS_MT_TRACKING_ID, i);
+ input_report_abs(input_dev,
+ ABS_MT_TOUCH_MAJOR, 1);
+ input_report_abs(input_dev,
+ ABS_MT_POSITION_X, events[i].x);
+ input_report_abs(input_dev,
+ ABS_MT_POSITION_Y, events[i].y);
+ input_mt_sync(input_dev);
+ }
+#endif
  input_sync(input_dev);
  return IRQ_HANDLED;
 }
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.yoctoproject.org/pipermail/meta-freescale/attachments/20130702/91c8e523/attachment.html>


More information about the meta-freescale mailing list