diff --git a/sys/dev/usb/ehci.c b/sys/dev/usb/ehci.c index 706a2bdcb232..aa66810bfa51 100644 --- a/sys/dev/usb/ehci.c +++ b/sys/dev/usb/ehci.c @@ -1,4 +1,4 @@ -/* $NetBSD: ehci.c,v 1.55 2004/06/22 05:25:10 mycroft Exp $ */ +/* $NetBSD: ehci.c,v 1.56 2004/06/22 07:20:35 mycroft Exp $ */ /* * Copyright (c) 2001 The NetBSD Foundation, Inc. @@ -69,7 +69,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: ehci.c,v 1.55 2004/06/22 05:25:10 mycroft Exp $"); +__KERNEL_RCSID(0, "$NetBSD: ehci.c,v 1.56 2004/06/22 07:20:35 mycroft Exp $"); #include "ohci.h" #include "uhci.h" @@ -1247,7 +1247,7 @@ ehci_open(usbd_pipe_handle pipe) /* qh_link filled when the QH is added */ sqh->qh.qh_endp = htole32( EHCI_QH_SET_ADDR(addr) | - EHCI_QH_SET_ENDPT(ed->bEndpointAddress) | + EHCI_QH_SET_ENDPT(UE_GET_ADDR(ed->bEndpointAddress)) | EHCI_QH_SET_EPS(speed) | EHCI_QH_DTC | EHCI_QH_SET_MPL(UGETW(ed->wMaxPacketSize)) | @@ -1255,6 +1255,7 @@ ehci_open(usbd_pipe_handle pipe) EHCI_QH_CTL : 0) | EHCI_QH_SET_NRL(naks) ); +printf("sqh=%p endp=%08x\n", sqh, sqh->qh.qh_endp); sqh->qh.qh_endphub = htole32( EHCI_QH_SET_MULT(1) /* XXX TT stuff */ @@ -2540,6 +2541,7 @@ ehci_device_request(usbd_xfer_handle xfer) EHCI_QH_SET_ADDR(addr) | EHCI_QH_SET_MPL(UGETW(epipe->pipe.endpoint->edesc->wMaxPacketSize)) ); +printf("sqh=%p endp=%08x\n", sqh, sqh->qh.qh_endp); /* Set up data transaction */ if (len != 0) { diff --git a/sys/dev/usb/ohci.c b/sys/dev/usb/ohci.c index cf5de8dd76d2..56a402fa0207 100644 --- a/sys/dev/usb/ohci.c +++ b/sys/dev/usb/ohci.c @@ -1,4 +1,4 @@ -/* $NetBSD: ohci.c,v 1.146 2003/12/29 08:17:10 toshii Exp $ */ +/* $NetBSD: ohci.c,v 1.147 2004/06/22 07:20:35 mycroft Exp $ */ /* $FreeBSD: src/sys/dev/usb/ohci.c,v 1.22 1999/11/17 22:33:40 n_hibma Exp $ */ /* @@ -46,7 +46,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: ohci.c,v 1.146 2003/12/29 08:17:10 toshii Exp $"); +__KERNEL_RCSID(0, "$NetBSD: ohci.c,v 1.147 2004/06/22 07:20:35 mycroft Exp $"); #include #include @@ -2053,7 +2053,7 @@ ohci_open(usbd_pipe_handle pipe) } sed->ed.ed_flags = htole32( OHCI_ED_SET_FA(addr) | - OHCI_ED_SET_EN(ed->bEndpointAddress) | + OHCI_ED_SET_EN(UE_GET_ADDR(ed->bEndpointAddress)) | (dev->speed == USB_SPEED_LOW ? OHCI_ED_SPEED : 0) | fmt | OHCI_ED_SET_MAXP(UGETW(ed->wMaxPacketSize)));