summaryrefslogtreecommitdiff
path: root/sys/dev/usb/ugen.c
diff options
context:
space:
mode:
authorTed Unangst <tedu@cvs.openbsd.org>2006-11-01 03:37:25 +0000
committerTed Unangst <tedu@cvs.openbsd.org>2006-11-01 03:37:25 +0000
commitcda47593c46bae82731a3ace441426d8628dd815 (patch)
treeaa28da856e618323be6d4d92b35e137b2e7735c6 /sys/dev/usb/ugen.c
parent4215128eaf88d9fc8ae8feca7b72fb5ad954c065 (diff)
poll errors should be POLLERR, not some random E value
from alexandre ratchov. ok claudio
Diffstat (limited to 'sys/dev/usb/ugen.c')
-rw-r--r--sys/dev/usb/ugen.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/sys/dev/usb/ugen.c b/sys/dev/usb/ugen.c
index 1c503715fd6..550993081d1 100644
--- a/sys/dev/usb/ugen.c
+++ b/sys/dev/usb/ugen.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ugen.c,v 1.35 2006/06/23 06:27:11 miod Exp $ */
+/* $OpenBSD: ugen.c,v 1.36 2006/11/01 03:37:23 tedu Exp $ */
/* $NetBSD: ugen.c,v 1.63 2002/11/26 18:49:48 christos Exp $ */
/* $FreeBSD: src/sys/dev/usb/ugen.c,v 1.26 1999/11/17 22:33:41 n_hibma Exp $ */
@@ -1347,20 +1347,20 @@ ugenpoll(dev_t dev, int events, usb_proc_ptr p)
USB_GET_SC(ugen, UGENUNIT(dev), sc);
if (sc->sc_dying)
- return (EIO);
+ return (POLLERR);
/* XXX always IN */
sce = &sc->sc_endpoints[UGENENDPOINT(dev)][IN];
if (sce == NULL)
- return (EINVAL);
+ return (POLLERR);
#ifdef DIAGNOSTIC
if (!sce->edesc) {
printf("ugenpoll: no edesc\n");
- return (EIO);
+ return (POLLERR);
}
if (!sce->pipeh) {
printf("ugenpoll: no pipe\n");
- return (EIO);
+ return (POLLERR);
}
#endif
s = splusb();