summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authortobhe <tobhe@cvs.openbsd.org>2020-09-11 19:18:02 +0000
committertobhe <tobhe@cvs.openbsd.org>2020-09-11 19:18:02 +0000
commit4bf5b4a6a2678b85ea982c286575e0038d43a552 (patch)
treeca00284268a80c5fc63226ff7251058c328d1ae4 /sys
parenta9ca2a18ba361b340de01054efc395121f75472e (diff)
Correctly set y_sensors for Geyser2 touchpads.
Feedback and ok patrick@ ok kn@
Diffstat (limited to 'sys')
-rw-r--r--sys/dev/usb/utpms.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/sys/dev/usb/utpms.c b/sys/dev/usb/utpms.c
index f113061c46a..e589c59040c 100644
--- a/sys/dev/usb/utpms.c
+++ b/sys/dev/usb/utpms.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: utpms.c,v 1.9 2020/08/25 14:01:58 deraadt Exp $ */
+/* $OpenBSD: utpms.c,v 1.10 2020/09/11 19:18:01 tobhe Exp $ */
/*
* Copyright (c) 2005, Johan Wallén
@@ -311,6 +311,12 @@ utpms_attach(struct device *parent, struct device *self, void *aux)
for (i = 0; i < nitems(utpms_devices); i++) {
pd = &utpms_devices[i];
if (product == pd->product && vendor == pd->vendor) {
+ sc->sc_noise = pd->noise;
+ sc->sc_threshold = pd->threshold;
+ sc->sc_x_factor = pd->x_factor;
+ sc->sc_x_sensors = pd->x_sensors;
+ sc->sc_y_factor = pd->y_factor;
+ sc->sc_y_sensors = pd->y_sensors;
switch (pd->type) {
case FOUNTAIN:
printf(": Fountain");
@@ -326,12 +332,6 @@ utpms_attach(struct device *parent, struct device *self, void *aux)
break;
}
printf(" Trackpad\n");
- sc->sc_noise = pd->noise;
- sc->sc_threshold = pd->threshold;
- sc->sc_x_factor = pd->x_factor;
- sc->sc_x_sensors = pd->x_sensors;
- sc->sc_y_factor = pd->y_factor;
- sc->sc_y_sensors = pd->y_sensors;
break;
}
}