summaryrefslogtreecommitdiff
path: root/sys/dev/usb/ohcivar.h
diff options
context:
space:
mode:
authorFederico G. Schwindt <fgsch@cvs.openbsd.org>1999-08-27 09:00:31 +0000
committerFederico G. Schwindt <fgsch@cvs.openbsd.org>1999-08-27 09:00:31 +0000
commitc6d969a5ffa607045a4b07b03b1fe4f278f5a5c2 (patch)
treed8ef2fc89f8ed5df12c8b5113f1ed266a160dc56 /sys/dev/usb/ohcivar.h
parentc79e6b116f4cd7baa14086e6fcda5e8b1f733082 (diff)
Sync with NetBSD;
Make sure not to call tsleep() from suspend/resume routine. Move more of the transfer completion processing to HC independent code. Fix some problems with transfer abort & timeout. Merge the soft_{td,qh} with the real {td,qh}. This saves time and space.
Diffstat (limited to 'sys/dev/usb/ohcivar.h')
-rw-r--r--sys/dev/usb/ohcivar.h13
1 files changed, 7 insertions, 6 deletions
diff --git a/sys/dev/usb/ohcivar.h b/sys/dev/usb/ohcivar.h
index 601619a4199..ffa75a6b072 100644
--- a/sys/dev/usb/ohcivar.h
+++ b/sys/dev/usb/ohcivar.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: ohcivar.h,v 1.3 1999/08/19 08:18:38 fgsch Exp $ */
+/* $OpenBSD: ohcivar.h,v 1.4 1999/08/27 09:00:28 fgsch Exp $ */
/* $NetBSD: ohcivar.h,v 1.6 1999/08/14 14:49:31 augustss Exp $ */
/*
@@ -39,26 +39,27 @@
*/
typedef struct ohci_soft_ed {
- ohci_ed_t *ed;
+ ohci_ed_t ed;
struct ohci_soft_ed *next;
ohci_physaddr_t physaddr;
} ohci_soft_ed_t;
-#define OHCI_ED_CHUNK 256
+#define OHCI_SED_SIZE ((sizeof (struct ohci_soft_ed) + OHCI_ED_ALIGN - 1) / OHCI_ED_ALIGN * OHCI_ED_ALIGN)
+#define OHCI_SED_CHUNK 128
typedef struct ohci_soft_td {
- ohci_td_t *td;
+ ohci_td_t td;
struct ohci_soft_td *nexttd; /* mirrors nexttd in TD */
struct ohci_soft_td *dnext; /* next in done list */
ohci_physaddr_t physaddr;
LIST_ENTRY(ohci_soft_td) hnext;
- /*ohci_soft_ed_t *sed;*/
usbd_request_handle reqh;
u_int16_t len;
u_int16_t flags;
#define OHCI_CALL_DONE 0x0001
#define OHCI_SET_LEN 0x0002
} ohci_soft_td_t;
-#define OHCI_TD_CHUNK 256
+#define OHCI_STD_SIZE ((sizeof (struct ohci_soft_td) + OHCI_TD_ALIGN - 1) / OHCI_TD_ALIGN * OHCI_TD_ALIGN)
+#define OHCI_STD_CHUNK 128
#define OHCI_NO_EDS (2*OHCI_NO_INTRS-1)