summaryrefslogtreecommitdiffstats
path: root/sys/dev/usb/controller/uhci.c
diff options
context:
space:
mode:
authorthompsa <thompsa@FreeBSD.org>2009-06-23 02:19:59 +0000
committerthompsa <thompsa@FreeBSD.org>2009-06-23 02:19:59 +0000
commit74c6c20b93f0513a453c6544f8b98ad55cbdc741 (patch)
treeee5c9acfe716a9835136731811e9e1a68751e278 /sys/dev/usb/controller/uhci.c
parent52922c0742bc8545734b2903d6407b99664e84ed (diff)
downloadFreeBSD-src-74c6c20b93f0513a453c6544f8b98ad55cbdc741.zip
FreeBSD-src-74c6c20b93f0513a453c6544f8b98ad55cbdc741.tar.gz
- Make struct usb_xfer opaque so that drivers can not access the internals
- Reduce the number of headers needed for a usb driver, the common case is just usb.h and usbdi.h
Diffstat (limited to 'sys/dev/usb/controller/uhci.c')
-rw-r--r--sys/dev/usb/controller/uhci.c25
1 files changed, 22 insertions, 3 deletions
diff --git a/sys/dev/usb/controller/uhci.c b/sys/dev/usb/controller/uhci.c
index 6d6a67e..77e95d3 100644
--- a/sys/dev/usb/controller/uhci.c
+++ b/sys/dev/usb/controller/uhci.c
@@ -38,9 +38,28 @@ __FBSDID("$FreeBSD$");
* ftp://download.intel.com/design/intarch/datashts/29056201.pdf
*/
+#include <sys/stdint.h>
+#include <sys/stddef.h>
+#include <sys/param.h>
+#include <sys/queue.h>
+#include <sys/types.h>
+#include <sys/systm.h>
+#include <sys/kernel.h>
+#include <sys/bus.h>
+#include <sys/linker_set.h>
+#include <sys/module.h>
+#include <sys/lock.h>
+#include <sys/mutex.h>
+#include <sys/condvar.h>
+#include <sys/sysctl.h>
+#include <sys/sx.h>
+#include <sys/unistd.h>
+#include <sys/callout.h>
+#include <sys/malloc.h>
+#include <sys/priv.h>
+
#include <dev/usb/usb.h>
-#include <dev/usb/usb_mfunc.h>
-#include <dev/usb/usb_error.h>
+#include <dev/usb/usbdi.h>
#define USB_DEBUG_VAR uhcidebug
@@ -1103,7 +1122,7 @@ uhci_non_isoc_done_sub(struct usb_xfer *xfer)
td_alt_next = td->alt_next;
if (xfer->aframes != xfer->nframes) {
- xfer->frlengths[xfer->aframes] = 0;
+ usbd_xfer_set_frame_len(xfer, xfer->aframes, 0);
}
while (1) {
OpenPOWER on IntegriCloud