On 02/27/2015 03:31 AM, Ulf Brosziewski wrote:
...>
It might be that the following patch to wsmouse.c solves the problem
with the new version of wsconscomm. Tests would be welcome (I could
only verify that the patch does no harm to other touchpad types, i.e.,
Elantech-v4 and Alps Glidepoint).

Index: wsmouse.c
===================================================================
RCS file: /cvs/src/sys/dev/wscons/wsmouse.c,v
retrieving revision 1.26
diff -u -p -r1.26 wsmouse.c
--- wsmouse.c 27 Oct 2014 13:55:05 -0000 1.26
+++ wsmouse.c 27 Feb 2015 01:39:29 -0000
@@ -420,7 +420,7 @@ wsmouse_input(struct device *wsmousedev,
ev->value = w;
TIMESTAMP;
ADVANCE;
- sc->sc_w = w;
+ sc->sc_w = (sc->sc_z == 0 ? INVALID_W : w);
}
} else {
if (sc->sc_dw) {

Sorry, the change was in the wrong place and would only do a half of
the work. It should look like:

Index: wsmouse.c
===================================================================
RCS file: /cvs/src/sys/dev/wscons/wsmouse.c,v
retrieving revision 1.26
diff -u -p -r1.26 wsmouse.c
--- wsmouse.c   27 Oct 2014 13:55:05 -0000      1.26
+++ wsmouse.c   27 Feb 2015 02:50:06 -0000
@@ -433,6 +433,9 @@ wsmouse_input(struct device *wsmousedev,
                }
        }

+       if (sc->sc_z == 0)
+               sc->sc_w = INVALID_W;
+
        mb = sc->sc_mb;
        while ((d = mb ^ ub) != 0) {
                /*

Reply via email to