diff options
author | Martin Pieuchot <mpi@cvs.openbsd.org> | 2014-03-23 11:55:00 +0000 |
---|---|---|
committer | Martin Pieuchot <mpi@cvs.openbsd.org> | 2014-03-23 11:55:00 +0000 |
commit | 79d065a954940141014d894e5af25a7133be52c1 (patch) | |
tree | 5adc522c4ade52d63e3335bee6be04feaa5af68e | |
parent | f15b60181d372f49e52f78e4bf7a19bb88e20710 (diff) |
Revert audio key handling, requested by ratchov@
-rw-r--r-- | sys/dev/usb/hidkbd.c | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/sys/dev/usb/hidkbd.c b/sys/dev/usb/hidkbd.c index 01feb02a145..42cd511743f 100644 --- a/sys/dev/usb/hidkbd.c +++ b/sys/dev/usb/hidkbd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: hidkbd.c,v 1.10 2014/03/16 10:53:09 mpi Exp $ */ +/* $OpenBSD: hidkbd.c,v 1.11 2014/03/23 11:54:59 mpi Exp $ */ /* $NetBSD: ukbd.c,v 1.85 2003/03/11 16:44:00 augustss Exp $ */ /* @@ -425,6 +425,22 @@ hidkbd_decode(struct hidkbd *kbd, struct hidkbd_data *ud) } s = spltty(); wskbd_rawinput(kbd->sc_wskbddev, cbuf, j); + + /* + * Pass audio keys to wskbd_input anyway. + */ + for (i = 0; i < nkeys; i++) { + key = ibuf[i]; + switch (key & CODEMASK) { + case 127: + case 128: + case 129: + wskbd_input(kbd->sc_wskbddev, + key & RELEASE ? WSCONS_EVENT_KEY_UP : + WSCONS_EVENT_KEY_DOWN, key & CODEMASK); + break; + } + } splx(s); return; |