diff options
| author | 2014-03-19 08:59:36 +0000 | |
|---|---|---|
| committer | 2014-03-19 08:59:36 +0000 | |
| commit | f964a65cb81e63aa2945f12c6b45f1fc5baaca96 (patch) | |
| tree | bde107158485ef777764264302f78df6a6445d44 /sys/dev/usb/uthum.c | |
| parent | It's still safe to assumed 'signed' exists (diff) | |
| download | wireguard-openbsd-f964a65cb81e63aa2945f12c6b45f1fc5baaca96.tar.xz wireguard-openbsd-f964a65cb81e63aa2945f12c6b45f1fc5baaca96.zip | |
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/uthum.c')
| -rw-r--r-- | sys/dev/usb/uthum.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/sys/dev/usb/uthum.c b/sys/dev/usb/uthum.c index 16ebf725dea..8abbb0ad4f0 100644 --- a/sys/dev/usb/uthum.c +++ b/sys/dev/usb/uthum.c @@ -1,4 +1,4 @@ -/* $OpenBSD: uthum.c,v 1.25 2014/03/07 18:39:02 mpi Exp $ */ +/* $OpenBSD: uthum.c,v 1.26 2014/03/19 08:59:37 mpi Exp $ */ /* * Copyright (c) 2009, 2010 Yojiro UO <yuo@nui.org> @@ -167,8 +167,10 @@ const struct cfattach uthum_ca = { int uthum_match(struct device *parent, void *match, void *aux) { - struct usb_attach_arg *uaa = aux; - struct uhidev_attach_arg *uha = (struct uhidev_attach_arg *)uaa; + struct uhidev_attach_arg *uha = aux; + + if (uha->reportid == UHIDEV_CLAIM_ALLREPORTID) + return (UMATCH_NONE); if (uthum_lookup(uha->uaa->vendor, uha->uaa->product) == NULL) return UMATCH_NONE; |
