diff options
author | Martin Pieuchot <mpi@cvs.openbsd.org> | 2014-03-19 08:59:38 +0000 |
---|---|---|
committer | Martin Pieuchot <mpi@cvs.openbsd.org> | 2014-03-19 08:59:38 +0000 |
commit | d1669317a6061f891563c1bbbd503b2e45d077c0 (patch) | |
tree | c990ec5e2bf09e26c116561c8fa30ef3aace7b63 /sys/dev/usb/uhid.c | |
parent | 28c348dc9a8d89d1383d58a02ca11268337de586 (diff) |
Add a temporary hack to let a subdriver claim all the reportIDs of
a device. This should be removed once all the drivers attaching to
uhidev(4) are converted.
ok andre@, sthen@
Diffstat (limited to 'sys/dev/usb/uhid.c')
-rw-r--r-- | sys/dev/usb/uhid.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/sys/dev/usb/uhid.c b/sys/dev/usb/uhid.c index f16bf5c1670..a2966a1ecf9 100644 --- a/sys/dev/usb/uhid.c +++ b/sys/dev/usb/uhid.c @@ -1,4 +1,4 @@ -/* $OpenBSD: uhid.c,v 1.55 2013/11/19 14:04:07 pirofti Exp $ */ +/* $OpenBSD: uhid.c,v 1.56 2014/03/19 08:59:37 mpi Exp $ */ /* $NetBSD: uhid.c,v 1.57 2003/03/11 16:44:00 augustss Exp $ */ /* @@ -114,11 +114,10 @@ const struct cfattach uhid_ca = { int uhid_match(struct device *parent, void *match, void *aux) { -#ifdef UHID_DEBUG - struct uhidev_attach_arg *uha = (struct uhidev_attach_arg *)aux; -#endif + struct uhidev_attach_arg *uha = aux; - DPRINTF(("uhid_match: report=%d\n", uha->reportid)); + if (uha->reportid == UHIDEV_CLAIM_ALLREPORTID) + return (UMATCH_NONE); return (UMATCH_IFACECLASS_GENERIC); } |