summaryrefslogtreecommitdiffstats
path: root/sys/dev/usb/ugold.c
diff options
context:
space:
mode:
authormpi <mpi@openbsd.org>2014-03-19 08:59:36 +0000
committermpi <mpi@openbsd.org>2014-03-19 08:59:36 +0000
commitf964a65cb81e63aa2945f12c6b45f1fc5baaca96 (patch)
treebde107158485ef777764264302f78df6a6445d44 /sys/dev/usb/ugold.c
parentIt's still safe to assumed 'signed' exists (diff)
downloadwireguard-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/ugold.c')
-rw-r--r--sys/dev/usb/ugold.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/sys/dev/usb/ugold.c b/sys/dev/usb/ugold.c
index e37d2ee157e..ad688c9d688 100644
--- a/sys/dev/usb/ugold.c
+++ b/sys/dev/usb/ugold.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ugold.c,v 1.3 2013/11/04 11:51:33 mpi Exp $ */
+/* $OpenBSD: ugold.c,v 1.4 2014/03/19 08:59:37 mpi Exp $ */
/*
* Copyright (c) 2013 Takayoshi SASANO <sasano@openbsd.org>
@@ -102,6 +102,9 @@ ugold_match(struct device *parent, void *match, void *aux)
int size;
void *desc;
+ if (uha->reportid == UHIDEV_CLAIM_ALLREPORTID)
+ return (UMATCH_NONE);
+
if (usb_lookup(ugold_devs, uha->uaa->vendor, uha->uaa->product) == NULL)
return (UMATCH_NONE);