summaryrefslogtreecommitdiffstats
path: root/sys/dev/usb/uhid.c
diff options
context:
space:
mode:
authorjulian <julian@FreeBSD.org>2001-09-12 08:38:13 +0000
committerjulian <julian@FreeBSD.org>2001-09-12 08:38:13 +0000
commit5596676e6c6c1e81e899cd0531f9b1c28a292669 (patch)
treeb1a19fcdf05759281fab0d89efb13f0fdf42102e /sys/dev/usb/uhid.c
parent83e00d4274950d2b531c24692cd123538ffbddb9 (diff)
downloadFreeBSD-src-5596676e6c6c1e81e899cd0531f9b1c28a292669.zip
FreeBSD-src-5596676e6c6c1e81e899cd0531f9b1c28a292669.tar.gz
KSE Milestone 2
Note ALL MODULES MUST BE RECOMPILED make the kernel aware that there are smaller units of scheduling than the process. (but only allow one thread per process at this time). This is functionally equivalent to teh previousl -current except that there is a thread associated with each process. Sorry john! (your next MFC will be a doosie!) Reviewed by: peter@freebsd.org, dillon@freebsd.org X-MFC after: ha ha ha ha
Diffstat (limited to 'sys/dev/usb/uhid.c')
-rw-r--r--sys/dev/usb/uhid.c30
1 files changed, 15 insertions, 15 deletions
diff --git a/sys/dev/usb/uhid.c b/sys/dev/usb/uhid.c
index cffc5e5..7914cb3 100644
--- a/sys/dev/usb/uhid.c
+++ b/sys/dev/usb/uhid.c
@@ -163,7 +163,7 @@ Static void uhid_intr(usbd_xfer_handle, usbd_private_handle,
Static int uhid_do_read(struct uhid_softc *, struct uio *uio, int);
Static int uhid_do_write(struct uhid_softc *, struct uio *uio, int);
Static int uhid_do_ioctl(struct uhid_softc *, u_long, caddr_t, int,
- struct proc *);
+ struct thread *);
USB_DECLARE_DRIVER(uhid);
@@ -373,11 +373,11 @@ uhid_intr(xfer, addr, status)
}
int
-uhidopen(dev, flag, mode, p)
+uhidopen(dev, flag, mode, td)
dev_t dev;
int flag;
int mode;
- struct proc *p;
+ struct thread *td;
{
struct uhid_softc *sc;
usbd_status err;
@@ -422,11 +422,11 @@ uhidopen(dev, flag, mode, p)
}
int
-uhidclose(dev, flag, mode, p)
+uhidclose(dev, flag, mode, td)
dev_t dev;
int flag;
int mode;
- struct proc *p;
+ struct thread *td;
{
struct uhid_softc *sc;
@@ -588,12 +588,12 @@ uhidwrite(dev, uio, flag)
}
int
-uhid_do_ioctl(sc, cmd, addr, flag, p)
+uhid_do_ioctl(sc, cmd, addr, flag, td)
struct uhid_softc *sc;
u_long cmd;
caddr_t addr;
int flag;
- struct proc *p;
+ struct thread *td;
{
struct usb_ctl_report_desc *rd;
struct usb_ctl_report *re;
@@ -614,8 +614,8 @@ uhid_do_ioctl(sc, cmd, addr, flag, p)
if (*(int *)addr) {
if (sc->sc_async != NULL)
return (EBUSY);
- sc->sc_async = p;
- DPRINTF(("uhid_do_ioctl: FIOASYNC %p\n", p));
+ sc->sc_async = td->td_proc; /* XXXKSE */
+ DPRINTF(("uhid_do_ioctl: FIOASYNC %p\n", td->td_proc));
} else
sc->sc_async = NULL;
break;
@@ -703,12 +703,12 @@ uhid_do_ioctl(sc, cmd, addr, flag, p)
}
int
-uhidioctl(dev, cmd, addr, flag, p)
+uhidioctl(dev, cmd, addr, flag, td)
dev_t dev;
u_long cmd;
caddr_t addr;
int flag;
- struct proc *p;
+ struct thread *td;
{
struct uhid_softc *sc;
int error;
@@ -716,17 +716,17 @@ uhidioctl(dev, cmd, addr, flag, p)
USB_GET_SC(uhid, UHIDUNIT(dev), sc);
sc->sc_refcnt++;
- error = uhid_do_ioctl(sc, cmd, addr, flag, p);
+ error = uhid_do_ioctl(sc, cmd, addr, flag, td);
if (--sc->sc_refcnt < 0)
usb_detach_wakeup(USBDEV(sc->sc_dev));
return (error);
}
int
-uhidpoll(dev, events, p)
+uhidpoll(dev, events, td)
dev_t dev;
int events;
- struct proc *p;
+ struct thread *td;
{
struct uhid_softc *sc;
int revents = 0;
@@ -744,7 +744,7 @@ uhidpoll(dev, events, p)
if (sc->sc_q.c_cc > 0)
revents |= events & (POLLIN | POLLRDNORM);
else
- selrecord(p, &sc->sc_rsel);
+ selrecord(td, &sc->sc_rsel);
}
splx(s);
OpenPOWER on IntegriCloud