svn commit: r194788 - in projects/mesh11s/sys/dev/usb: . controller input misc net quirk serial template

Rui Paulo rpaulo at FreeBSD.org
Tue Jun 23 23:01:06 UTC 2009


Author: rpaulo
Date: Tue Jun 23 23:01:05 2009
New Revision: 194788
URL: http://svn.freebsd.org/changeset/base/194788

Log:
  Fix mismerge.
  
  Sponsored by:	The FreeBSD Foundation

Modified:
  projects/mesh11s/sys/dev/usb/controller/at91dci.c
  projects/mesh11s/sys/dev/usb/controller/at91dci_atmelarm.c
  projects/mesh11s/sys/dev/usb/controller/atmegadci.c
  projects/mesh11s/sys/dev/usb/controller/atmegadci_atmelarm.c
  projects/mesh11s/sys/dev/usb/controller/avr32dci.c
  projects/mesh11s/sys/dev/usb/controller/ehci.c
  projects/mesh11s/sys/dev/usb/controller/ehci_ixp4xx.c
  projects/mesh11s/sys/dev/usb/controller/ehci_mbus.c
  projects/mesh11s/sys/dev/usb/controller/ehci_pci.c
  projects/mesh11s/sys/dev/usb/controller/musb_otg.c
  projects/mesh11s/sys/dev/usb/controller/musb_otg_atmelarm.c
  projects/mesh11s/sys/dev/usb/controller/ohci.c
  projects/mesh11s/sys/dev/usb/controller/ohci_atmelarm.c
  projects/mesh11s/sys/dev/usb/controller/ohci_pci.c
  projects/mesh11s/sys/dev/usb/controller/uhci.c
  projects/mesh11s/sys/dev/usb/controller/uhci_pci.c
  projects/mesh11s/sys/dev/usb/controller/usb_controller.c
  projects/mesh11s/sys/dev/usb/controller/uss820dci.c
  projects/mesh11s/sys/dev/usb/controller/uss820dci_atmelarm.c
  projects/mesh11s/sys/dev/usb/input/ukbd.c
  projects/mesh11s/sys/dev/usb/misc/ufm.c
  projects/mesh11s/sys/dev/usb/net/if_auereg.h
  projects/mesh11s/sys/dev/usb/net/if_axereg.h
  projects/mesh11s/sys/dev/usb/net/if_ruereg.h
  projects/mesh11s/sys/dev/usb/net/if_udavreg.h
  projects/mesh11s/sys/dev/usb/net/usb_ethernet.c
  projects/mesh11s/sys/dev/usb/net/usb_ethernet.h
  projects/mesh11s/sys/dev/usb/quirk/usb_quirk.c
  projects/mesh11s/sys/dev/usb/serial/usb_serial.c
  projects/mesh11s/sys/dev/usb/serial/usb_serial.h
  projects/mesh11s/sys/dev/usb/template/usb_template.h
  projects/mesh11s/sys/dev/usb/template/usb_template_cdce.c
  projects/mesh11s/sys/dev/usb/template/usb_template_msc.c
  projects/mesh11s/sys/dev/usb/template/usb_template_mtp.c
  projects/mesh11s/sys/dev/usb/usb_bus.h
  projects/mesh11s/sys/dev/usb/usb_busdma.c
  projects/mesh11s/sys/dev/usb/usb_compat_linux.h
  projects/mesh11s/sys/dev/usb/usb_controller.h
  projects/mesh11s/sys/dev/usb/usb_debug.c
  projects/mesh11s/sys/dev/usb/usb_debug.h
  projects/mesh11s/sys/dev/usb/usb_dev.c
  projects/mesh11s/sys/dev/usb/usb_dynamic.c
  projects/mesh11s/sys/dev/usb/usb_endian.h
  projects/mesh11s/sys/dev/usb/usb_error.c
  projects/mesh11s/sys/dev/usb/usb_generic.h
  projects/mesh11s/sys/dev/usb/usb_hid.c
  projects/mesh11s/sys/dev/usb/usb_hub.c
  projects/mesh11s/sys/dev/usb/usb_hub.h
  projects/mesh11s/sys/dev/usb/usb_if.m
  projects/mesh11s/sys/dev/usb/usb_ioctl.h
  projects/mesh11s/sys/dev/usb/usb_lookup.c
  projects/mesh11s/sys/dev/usb/usb_mbuf.c
  projects/mesh11s/sys/dev/usb/usb_mbuf.h
  projects/mesh11s/sys/dev/usb/usb_msctest.h
  projects/mesh11s/sys/dev/usb/usb_parse.c
  projects/mesh11s/sys/dev/usb/usb_pci.h
  projects/mesh11s/sys/dev/usb/usb_process.c
  projects/mesh11s/sys/dev/usb/usb_process.h
  projects/mesh11s/sys/dev/usb/usbdevs

Modified: projects/mesh11s/sys/dev/usb/controller/at91dci.c
==============================================================================
--- projects/mesh11s/sys/dev/usb/controller/at91dci.c	Tue Jun 23 23:00:13 2009	(r194787)
+++ projects/mesh11s/sys/dev/usb/controller/at91dci.c	Tue Jun 23 23:01:05 2009	(r194788)
@@ -279,7 +279,7 @@ at91dci_wakeup_peer(struct at91dci_softc
 
 	/* wait 8 milliseconds */
 	/* Wait for reset to complete. */
-	usb2_pause_mtx(&sc->sc_bus.bus_mtx, hz / 125);
+	usb_pause_mtx(&sc->sc_bus.bus_mtx, hz / 125);
 
 	AT91_UDP_WRITE_4(sc, AT91_UDP_GSTATE, 0);
 }
@@ -340,7 +340,7 @@ at91dci_setup_rx(struct at91dci_td *td)
 	    td->fifo_reg, (void *)&req, sizeof(req));
 
 	/* copy data into real buffer */
-	usb2_copy_in(td->pc, 0, &req, sizeof(req));
+	usbd_copy_in(td->pc, 0, &req, sizeof(req));
 
 	td->offset = sizeof(req);
 	td->remainder = 0;
@@ -461,7 +461,7 @@ repeat:
 		return (0);		/* we are complete */
 	}
 	while (count > 0) {
-		usb2_get_page(td->pc, td->offset, &buf_res);
+		usbd_get_page(td->pc, td->offset, &buf_res);
 
 		/* get correct length */
 		if (buf_res.length > count) {
@@ -568,7 +568,7 @@ repeat:
 	}
 	while (count > 0) {
 
-		usb2_get_page(td->pc, td->offset, &buf_res);
+		usbd_get_page(td->pc, td->offset, &buf_res);
 
 		/* get correct length */
 		if (buf_res.length > count) {
@@ -884,7 +884,7 @@ at91dci_setup_standard_chain(struct usb_
 
 	DPRINTFN(9, "addr=%d endpt=%d sumlen=%d speed=%d\n",
 	    xfer->address, UE_GET_ADDR(xfer->endpointno),
-	    xfer->sumlen, usb2_get_speed(xfer->xroot->udev));
+	    xfer->sumlen, usbd_get_speed(xfer->xroot->udev));
 
 	temp.max_frame_size = xfer->max_frame_size;
 
@@ -1065,11 +1065,11 @@ at91dci_start_standard_chain(struct usb_
 		DPRINTFN(15, "enable interrupts on endpoint %d\n", ep_no);
 
 		/* put transfer on interrupt queue */
-		usb2_transfer_enqueue(&xfer->xroot->bus->intr_q, xfer);
+		usbd_transfer_enqueue(&xfer->xroot->bus->intr_q, xfer);
 
 		/* start timeout, if any */
 		if (xfer->timeout != 0) {
-			usb2_transfer_timeout_ms(xfer,
+			usbd_transfer_timeout_ms(xfer,
 			    &at91dci_timeout, xfer->timeout);
 		}
 	}
@@ -1222,7 +1222,7 @@ at91dci_device_done(struct usb_xfer *xfe
 		DPRINTFN(15, "disable interrupts on endpoint %d\n", ep_no);
 	}
 	/* dequeue transfer and start next transfer */
-	usb2_transfer_done(xfer, error);
+	usbd_transfer_done(xfer, error);
 }
 
 static void
@@ -1394,7 +1394,7 @@ at91dci_init(struct at91dci_softc *sc)
 		(sc->sc_clocks_on) (sc->sc_clocks_arg);
 	}
 	/* wait a little for things to stabilise */
-	usb2_pause_mtx(&sc->sc_bus.bus_mtx, hz / 1000);
+	usb_pause_mtx(&sc->sc_bus.bus_mtx, hz / 1000);
 
 	/* disable and clear all interrupts */
 
@@ -1651,7 +1651,7 @@ at91dci_device_isoc_fs_enter(struct usb_
 	 * pre-compute when the isochronous transfer will be finished:
 	 */
 	xfer->isoc_time_complete =
-	    usb2_isoc_time_expand(&sc->sc_bus, nframes) + temp +
+	    usb_isoc_time_expand(&sc->sc_bus, nframes) + temp +
 	    xfer->nframes;
 
 	/* compute frame number for next insertion */
@@ -2184,7 +2184,7 @@ at91dci_xfer_setup(struct usb_setup_para
 	parm->hc_max_packet_count = 1;
 	parm->hc_max_frame_size = 0x500;
 
-	usb2_transfer_setup_sub(parm);
+	usbd_transfer_setup_sub(parm);
 
 	/*
 	 * compute maximum number of TDs
@@ -2212,7 +2212,7 @@ at91dci_xfer_setup(struct usb_setup_para
 	}
 
 	/*
-	 * check if "usb2_transfer_setup_sub" set an error
+	 * check if "usbd_transfer_setup_sub" set an error
 	 */
 	if (parm->err) {
 		return;

Modified: projects/mesh11s/sys/dev/usb/controller/at91dci_atmelarm.c
==============================================================================
--- projects/mesh11s/sys/dev/usb/controller/at91dci_atmelarm.c	Tue Jun 23 23:00:13 2009	(r194787)
+++ projects/mesh11s/sys/dev/usb/controller/at91dci_atmelarm.c	Tue Jun 23 23:01:05 2009	(r194788)
@@ -163,7 +163,7 @@ at91_udp_attach(device_t dev)
 	sc->sc_dci.sc_bus.devices_max = AT91_MAX_DEVICES;
 
 	/* get all DMA memory */
-	if (usb2_bus_mem_alloc_all(&sc->sc_dci.sc_bus,
+	if (usb_bus_mem_alloc_all(&sc->sc_dci.sc_bus,
 	    USB_GET_DMA_TAG(dev), NULL)) {
 		return (ENOMEM);
 	}
@@ -185,7 +185,7 @@ at91_udp_attach(device_t dev)
 	at91_udp_pull_down(sc);
 
 	/* wait 10ms for pulldown to stabilise */
-	usb2_pause_mtx(NULL, hz / 100);
+	usb_pause_mtx(NULL, hz / 100);
 
 	sc->sc_iclk = at91_pmc_clock_ref("udc_clk");
 	sc->sc_fclk = at91_pmc_clock_ref("udpck");
@@ -314,7 +314,7 @@ at91_udp_detach(device_t dev)
 		    sc->sc_dci.sc_io_res);
 		sc->sc_dci.sc_io_res = NULL;
 	}
-	usb2_bus_mem_free_all(&sc->sc_dci.sc_bus, NULL);
+	usb_bus_mem_free_all(&sc->sc_dci.sc_bus, NULL);
 
 	/* disable clocks */
 	at91_pmc_clock_disable(sc->sc_iclk);

Modified: projects/mesh11s/sys/dev/usb/controller/atmegadci.c
==============================================================================
--- projects/mesh11s/sys/dev/usb/controller/atmegadci.c	Tue Jun 23 23:00:13 2009	(r194787)
+++ projects/mesh11s/sys/dev/usb/controller/atmegadci.c	Tue Jun 23 23:01:05 2009	(r194788)
@@ -223,7 +223,7 @@ atmegadci_wakeup_peer(struct atmegadci_s
 
 	/* wait 8 milliseconds */
 	/* Wait for reset to complete. */
-	usb2_pause_mtx(&sc->sc_bus.bus_mtx, hz / 125);
+	usb_pause_mtx(&sc->sc_bus.bus_mtx, hz / 125);
 
 	/* hardware should have cleared RMWKUP bit */
 }
@@ -286,7 +286,7 @@ atmegadci_setup_rx(struct atmegadci_td *
 	    (void *)&req, sizeof(req));
 
 	/* copy data into real buffer */
-	usb2_copy_in(td->pc, 0, &req, sizeof(req));
+	usbd_copy_in(td->pc, 0, &req, sizeof(req));
 
 	td->offset = sizeof(req);
 	td->remainder = 0;
@@ -397,7 +397,7 @@ repeat:
 		return (0);		/* we are complete */
 	}
 	while (count > 0) {
-		usb2_get_page(td->pc, td->offset, &buf_res);
+		usbd_get_page(td->pc, td->offset, &buf_res);
 
 		/* get correct length */
 		if (buf_res.length > count) {
@@ -484,7 +484,7 @@ repeat:
 	}
 	while (count > 0) {
 
-		usb2_get_page(td->pc, td->offset, &buf_res);
+		usbd_get_page(td->pc, td->offset, &buf_res);
 
 		/* get correct length */
 		if (buf_res.length > count) {
@@ -787,7 +787,7 @@ atmegadci_setup_standard_chain(struct us
 
 	DPRINTFN(9, "addr=%d endpt=%d sumlen=%d speed=%d\n",
 	    xfer->address, UE_GET_ADDR(xfer->endpointno),
-	    xfer->sumlen, usb2_get_speed(xfer->xroot->udev));
+	    xfer->sumlen, usbd_get_speed(xfer->xroot->udev));
 
 	temp.max_frame_size = xfer->max_frame_size;
 
@@ -948,11 +948,11 @@ atmegadci_start_standard_chain(struct us
 	if (atmegadci_xfer_do_fifo(xfer)) {
 
 		/* put transfer on interrupt queue */
-		usb2_transfer_enqueue(&xfer->xroot->bus->intr_q, xfer);
+		usbd_transfer_enqueue(&xfer->xroot->bus->intr_q, xfer);
 
 		/* start timeout, if any */
 		if (xfer->timeout != 0) {
-			usb2_transfer_timeout_ms(xfer,
+			usbd_transfer_timeout_ms(xfer,
 			    &atmegadci_timeout, xfer->timeout);
 		}
 	}
@@ -1108,7 +1108,7 @@ atmegadci_device_done(struct usb_xfer *x
 		DPRINTFN(15, "disabled interrupts!\n");
 	}
 	/* dequeue transfer and start next transfer */
-	usb2_transfer_done(xfer, error);
+	usbd_transfer_done(xfer, error);
 }
 
 static void
@@ -1255,7 +1255,7 @@ atmegadci_init(struct atmegadci_softc *s
 		if (ATMEGA_READ_1(sc, 0x49) & 0x01)
 			break;
 		/* wait a little bit for PLL to start */
-		usb2_pause_mtx(&sc->sc_bus.bus_mtx, hz / 100);
+		usb_pause_mtx(&sc->sc_bus.bus_mtx, hz / 100);
 	}
 
 	/* make sure USB is enabled */
@@ -1271,7 +1271,7 @@ atmegadci_init(struct atmegadci_softc *s
 	ATMEGA_WRITE_1(sc, ATMEGA_UDCON, ATMEGA_UDCON_DETACH);
 
 	/* wait a little for things to stabilise */
-	usb2_pause_mtx(&sc->sc_bus.bus_mtx, hz / 20);
+	usb_pause_mtx(&sc->sc_bus.bus_mtx, hz / 20);
 
 	/* enable interrupts */
 	ATMEGA_WRITE_1(sc, ATMEGA_UDIEN,
@@ -1472,7 +1472,7 @@ atmegadci_device_isoc_fs_enter(struct us
 	 * pre-compute when the isochronous transfer will be finished:
 	 */
 	xfer->isoc_time_complete =
-	    usb2_isoc_time_expand(&sc->sc_bus, nframes) + temp +
+	    usb_isoc_time_expand(&sc->sc_bus, nframes) + temp +
 	    xfer->nframes;
 
 	/* compute frame number for next insertion */
@@ -2036,7 +2036,7 @@ atmegadci_xfer_setup(struct usb_setup_pa
 	parm->hc_max_packet_count = 1;
 	parm->hc_max_frame_size = 0x500;
 
-	usb2_transfer_setup_sub(parm);
+	usbd_transfer_setup_sub(parm);
 
 	/*
 	 * compute maximum number of TDs
@@ -2051,7 +2051,7 @@ atmegadci_xfer_setup(struct usb_setup_pa
 	}
 
 	/*
-	 * check if "usb2_transfer_setup_sub" set an error
+	 * check if "usbd_transfer_setup_sub" set an error
 	 */
 	if (parm->err)
 		return;

Modified: projects/mesh11s/sys/dev/usb/controller/atmegadci_atmelarm.c
==============================================================================
--- projects/mesh11s/sys/dev/usb/controller/atmegadci_atmelarm.c	Tue Jun 23 23:00:13 2009	(r194787)
+++ projects/mesh11s/sys/dev/usb/controller/atmegadci_atmelarm.c	Tue Jun 23 23:01:05 2009	(r194788)
@@ -105,7 +105,7 @@ atmegadci_attach(device_t dev)
 	sc->sc_otg.sc_bus.devices_max = ATMEGA_MAX_DEVICES;
 
 	/* get all DMA memory */
-	if (usb2_bus_mem_alloc_all(&sc->sc_otg.sc_bus,
+	if (usb_bus_mem_alloc_all(&sc->sc_otg.sc_bus,
 	    USB_GET_DMA_TAG(dev), NULL)) {
 		return (ENOMEM);
 	}
@@ -189,7 +189,7 @@ atmegadci_detach(device_t dev)
 		    sc->sc_otg.sc_io_res);
 		sc->sc_otg.sc_io_res = NULL;
 	}
-	usb2_bus_mem_free_all(&sc->sc_otg.sc_bus, NULL);
+	usb_bus_mem_free_all(&sc->sc_otg.sc_bus, NULL);
 
 	return (0);
 }

Modified: projects/mesh11s/sys/dev/usb/controller/avr32dci.c
==============================================================================
--- projects/mesh11s/sys/dev/usb/controller/avr32dci.c	Tue Jun 23 23:00:13 2009	(r194787)
+++ projects/mesh11s/sys/dev/usb/controller/avr32dci.c	Tue Jun 23 23:01:05 2009	(r194788)
@@ -256,7 +256,7 @@ avr32dci_wakeup_peer(struct avr32dci_sof
 
 	/* wait 8 milliseconds */
 	/* Wait for reset to complete. */
-	usb2_pause_mtx(&sc->sc_bus.bus_mtx, hz / 125);
+	usb_pause_mtx(&sc->sc_bus.bus_mtx, hz / 125);
 
 	/* hardware should have cleared RMWKUP bit */
 }
@@ -308,7 +308,7 @@ avr32dci_setup_rx(struct avr32dci_td *td
 	memcpy(&req, sc->physdata, sizeof(req));
 
 	/* copy data into real buffer */
-	usb2_copy_in(td->pc, 0, &req, sizeof(req));
+	usbd_copy_in(td->pc, 0, &req, sizeof(req));
 
 	td->offset = sizeof(req);
 	td->remainder = 0;
@@ -409,7 +409,7 @@ repeat:
 		return (0);		/* we are complete */
 	}
 	while (count > 0) {
-		usb2_get_page(td->pc, td->offset, &buf_res);
+		usbd_get_page(td->pc, td->offset, &buf_res);
 
 		/* get correct length */
 		if (buf_res.length > count) {
@@ -485,7 +485,7 @@ repeat:
 	}
 	while (count > 0) {
 
-		usb2_get_page(td->pc, td->offset, &buf_res);
+		usbd_get_page(td->pc, td->offset, &buf_res);
 
 		/* get correct length */
 		if (buf_res.length > count) {
@@ -757,7 +757,7 @@ avr32dci_setup_standard_chain(struct usb
 
 	DPRINTFN(9, "addr=%d endpt=%d sumlen=%d speed=%d\n",
 	    xfer->address, UE_GET_ADDR(xfer->endpoint),
-	    xfer->sumlen, usb2_get_speed(xfer->xroot->udev));
+	    xfer->sumlen, usbd_get_speed(xfer->xroot->udev));
 
 	temp.max_frame_size = xfer->max_frame_size;
 
@@ -919,11 +919,11 @@ avr32dci_start_standard_chain(struct usb
 		avr32dci_mod_ien(sc, AVR32_INT_EPT_INT(ep_no), 0);
 
 		/* put transfer on interrupt queue */
-		usb2_transfer_enqueue(&xfer->xroot->bus->intr_q, xfer);
+		usbd_transfer_enqueue(&xfer->xroot->bus->intr_q, xfer);
 
 		/* start timeout, if any */
 		if (xfer->timeout != 0) {
-			usb2_transfer_timeout_ms(xfer,
+			usbd_transfer_timeout_ms(xfer,
 			    &avr32dci_timeout, xfer->timeout);
 		}
 	}
@@ -1076,7 +1076,7 @@ avr32dci_device_done(struct usb_xfer *xf
 		DPRINTFN(15, "disabled interrupts!\n");
 	}
 	/* dequeue transfer and start next transfer */
-	usb2_transfer_done(xfer, error);
+	usbd_transfer_done(xfer, error);
 }
 
 static void
@@ -1217,7 +1217,7 @@ avr32dci_init(struct avr32dci_softc *sc)
 	avr32dci_mod_ctrl(sc, AVR32_CTRL_DEV_DETACH, 0);
 
 	/* wait a little for things to stabilise */
-	usb2_pause_mtx(&sc->sc_bus.bus_mtx, hz / 20);
+	usb_pause_mtx(&sc->sc_bus.bus_mtx, hz / 20);
 
 	/* disable interrupts */
 	avr32dci_mod_ien(sc, 0, 0xFFFFFFFF);
@@ -1406,7 +1406,7 @@ avr32dci_device_isoc_fs_enter(struct usb
 	 * pre-compute when the isochronous transfer will be finished:
 	 */
 	xfer->isoc_time_complete =
-	    usb2_isoc_time_expand(&sc->sc_bus, nframes) + temp +
+	    usb_isoc_time_expand(&sc->sc_bus, nframes) + temp +
 	    xfer->nframes;
 
 	/* compute frame number for next insertion */
@@ -1969,7 +1969,7 @@ avr32dci_xfer_setup(struct usb_setup_par
 	parm->hc_max_packet_count = 1;
 	parm->hc_max_frame_size = 0x400;
 
-	usb2_transfer_setup_sub(parm);
+	usbd_transfer_setup_sub(parm);
 
 	/*
 	 * compute maximum number of TDs
@@ -1984,7 +1984,7 @@ avr32dci_xfer_setup(struct usb_setup_par
 	}
 
 	/*
-	 * check if "usb2_transfer_setup_sub" set an error
+	 * check if "usbd_transfer_setup_sub" set an error
 	 */
 	if (parm->err)
 		return;

Modified: projects/mesh11s/sys/dev/usb/controller/ehci.c
==============================================================================
--- projects/mesh11s/sys/dev/usb/controller/ehci.c	Tue Jun 23 23:00:13 2009	(r194787)
+++ projects/mesh11s/sys/dev/usb/controller/ehci.c	Tue Jun 23 23:01:05 2009	(r194788)
@@ -172,7 +172,7 @@ ehci_reset(ehci_softc_t *sc)
 
 	EOWRITE4(sc, EHCI_USBCMD, EHCI_CMD_HCRESET);
 	for (i = 0; i < 100; i++) {
-		usb2_pause_mtx(NULL, hz / 1000);
+		usb_pause_mtx(NULL, hz / 1000);
 		hcr = EOREAD4(sc, EHCI_USBCMD) & EHCI_CMD_HCRESET;
 		if (!hcr) {
 			if (sc->sc_flags & (EHCI_SCFLG_SETMODE | EHCI_SCFLG_BIGEMMIO)) {
@@ -208,7 +208,7 @@ ehci_hcreset(ehci_softc_t *sc)
 
 	EOWRITE4(sc, EHCI_USBCMD, 0);	/* Halt controller */
 	for (i = 0; i < 100; i++) {
-		usb2_pause_mtx(NULL, hz / 1000);
+		usb_pause_mtx(NULL, hz / 1000);
 		hcr = EOREAD4(sc, EHCI_USBSTS) & EHCI_STS_HCH;
 		if (hcr)
 			break;
@@ -240,7 +240,7 @@ ehci_init(ehci_softc_t *sc)
 
 	DPRINTF("start\n");
 
-	usb2_callout_init_mtx(&sc->sc_tmo_pcd, &sc->sc_bus.bus_mtx, 0);
+	usb_callout_init_mtx(&sc->sc_tmo_pcd, &sc->sc_bus.bus_mtx, 0);
 
 #if USB_DEBUG
 	if (ehcidebug > 2) {
@@ -293,7 +293,7 @@ ehci_init(ehci_softc_t *sc)
 	for (i = 0; i < EHCI_VIRTUAL_FRAMELIST_COUNT; i++) {
 		ehci_qh_t *qh;
 
-		usb2_get_page(sc->sc_hw.intr_start_pc + i, 0, &buf_res);
+		usbd_get_page(sc->sc_hw.intr_start_pc + i, 0, &buf_res);
 
 		qh = buf_res.buffer;
 
@@ -361,7 +361,7 @@ ehci_init(ehci_softc_t *sc)
 		ehci_sitd_t *sitd;
 		ehci_itd_t *itd;
 
-		usb2_get_page(sc->sc_hw.isoc_fs_start_pc + i, 0, &buf_res);
+		usbd_get_page(sc->sc_hw.isoc_fs_start_pc + i, 0, &buf_res);
 
 		sitd = buf_res.buffer;
 
@@ -386,7 +386,7 @@ ehci_init(ehci_softc_t *sc)
 		    sc->sc_intr_p_last[i | (EHCI_VIRTUAL_FRAMELIST_COUNT / 2)]->qh_self;
 
 
-		usb2_get_page(sc->sc_hw.isoc_hs_start_pc + i, 0, &buf_res);
+		usbd_get_page(sc->sc_hw.isoc_hs_start_pc + i, 0, &buf_res);
 
 		itd = buf_res.buffer;
 
@@ -408,7 +408,7 @@ ehci_init(ehci_softc_t *sc)
 		    sitd->sitd_self;
 	}
 
-	usb2_get_page(&sc->sc_hw.pframes_pc, 0, &buf_res);
+	usbd_get_page(&sc->sc_hw.pframes_pc, 0, &buf_res);
 
 	if (1) {
 		uint32_t *pframes;
@@ -428,7 +428,7 @@ ehci_init(ehci_softc_t *sc)
 	/* setup sync list pointer */
 	EOWRITE4(sc, EHCI_PERIODICLISTBASE, buf_res.physaddr);
 
-	usb2_get_page(&sc->sc_hw.async_start_pc, 0, &buf_res);
+	usbd_get_page(&sc->sc_hw.async_start_pc, 0, &buf_res);
 
 	if (1) {
 
@@ -464,7 +464,7 @@ ehci_init(ehci_softc_t *sc)
 	}
 	/* flush all cache into memory */
 
-	usb2_bus_mem_flush_all(&sc->sc_bus, &ehci_iterate_hw_softc);
+	usb_bus_mem_flush_all(&sc->sc_bus, &ehci_iterate_hw_softc);
 
 #if USB_DEBUG
 	if (ehcidebug) {
@@ -491,7 +491,7 @@ ehci_init(ehci_softc_t *sc)
 	EOWRITE4(sc, EHCI_CONFIGFLAG, EHCI_CONF_CF);
 
 	for (i = 0; i < 100; i++) {
-		usb2_pause_mtx(NULL, hz / 1000);
+		usb_pause_mtx(NULL, hz / 1000);
 		hcr = EOREAD4(sc, EHCI_USBSTS) & EHCI_STS_HCH;
 		if (!hcr) {
 			break;
@@ -517,7 +517,7 @@ ehci_detach(ehci_softc_t *sc)
 {
 	USB_BUS_LOCK(&sc->sc_bus);
 
-	usb2_callout_stop(&sc->sc_tmo_pcd);
+	usb_callout_stop(&sc->sc_tmo_pcd);
 
 	EOWRITE4(sc, EHCI_USBINTR, sc->sc_eintrs);
 	USB_BUS_UNLOCK(&sc->sc_bus);
@@ -527,9 +527,9 @@ ehci_detach(ehci_softc_t *sc)
 	}
 
 	/* XXX let stray task complete */
-	usb2_pause_mtx(NULL, hz / 20);
+	usb_pause_mtx(NULL, hz / 20);
 
-	usb2_callout_drain(&sc->sc_tmo_pcd);
+	usb_callout_drain(&sc->sc_tmo_pcd);
 }
 
 void
@@ -562,7 +562,7 @@ ehci_suspend(ehci_softc_t *sc)
 		if (hcr == 0) {
 			break;
 		}
-		usb2_pause_mtx(&sc->sc_bus.bus_mtx, hz / 1000);
+		usb_pause_mtx(&sc->sc_bus.bus_mtx, hz / 1000);
 	}
 
 	if (hcr != 0) {
@@ -576,7 +576,7 @@ ehci_suspend(ehci_softc_t *sc)
 		if (hcr == EHCI_STS_HCH) {
 			break;
 		}
-		usb2_pause_mtx(&sc->sc_bus.bus_mtx, hz / 1000);
+		usb_pause_mtx(&sc->sc_bus.bus_mtx, hz / 1000);
 	}
 
 	if (hcr != EHCI_STS_HCH) {
@@ -599,10 +599,10 @@ ehci_resume(ehci_softc_t *sc)
 	/* restore things in case the bios doesn't */
 	EOWRITE4(sc, EHCI_CTRLDSSEGMENT, 0);
 
-	usb2_get_page(&sc->sc_hw.pframes_pc, 0, &buf_res);
+	usbd_get_page(&sc->sc_hw.pframes_pc, 0, &buf_res);
 	EOWRITE4(sc, EHCI_PERIODICLISTBASE, buf_res.physaddr);
 
-	usb2_get_page(&sc->sc_hw.async_start_pc, 0, &buf_res);
+	usbd_get_page(&sc->sc_hw.async_start_pc, 0, &buf_res);
 	EOWRITE4(sc, EHCI_ASYNCLISTADDR, buf_res.physaddr | EHCI_LINK_QH);
 
 	EOWRITE4(sc, EHCI_USBINTR, sc->sc_eintrs);
@@ -619,7 +619,7 @@ ehci_resume(ehci_softc_t *sc)
 	}
 
 	if (hcr) {
-		usb2_pause_mtx(&sc->sc_bus.bus_mtx,
+		usb_pause_mtx(&sc->sc_bus.bus_mtx,
 		    USB_MS_TO_TICKS(USB_RESUME_WAIT));
 
 		for (i = 1; i <= sc->sc_noport; i++) {
@@ -638,7 +638,7 @@ ehci_resume(ehci_softc_t *sc)
 		if (hcr != EHCI_STS_HCH) {
 			break;
 		}
-		usb2_pause_mtx(&sc->sc_bus.bus_mtx, hz / 1000);
+		usb_pause_mtx(&sc->sc_bus.bus_mtx, hz / 1000);
 	}
 	if (hcr == EHCI_STS_HCH) {
 		device_printf(sc->sc_bus.bdev, "config timeout\n");
@@ -646,7 +646,7 @@ ehci_resume(ehci_softc_t *sc)
 
 	USB_BUS_UNLOCK(&sc->sc_bus);
 
-	usb2_pause_mtx(NULL,
+	usb_pause_mtx(NULL,
 	    USB_MS_TO_TICKS(USB_RESUME_WAIT));
 
 	/* catch any lost interrupts */
@@ -812,7 +812,7 @@ ehci_dump_sqtd(ehci_softc_t *sc, ehci_qt
 {
 	uint8_t temp;
 
-	usb2_pc_cpu_invalidate(sqtd->page_cache);
+	usb_pc_cpu_invalidate(sqtd->page_cache);
 	printf("QTD(%p) at 0x%08x:\n", sqtd, hc32toh(sc, sqtd->qtd_self));
 	ehci_dump_qtd(sc, sqtd);
 	temp = (sqtd->qtd_next & htohc32(sc, EHCI_LINK_TERMINATE)) ? 1 : 0;
@@ -840,7 +840,7 @@ ehci_dump_sqh(ehci_softc_t *sc, ehci_qh_
 	uint32_t endp;
 	uint32_t endphub;
 
-	usb2_pc_cpu_invalidate(qh->page_cache);
+	usb_pc_cpu_invalidate(qh->page_cache);
 	printf("QH(%p) at 0x%08x:\n", qh, hc32toh(sc, qh->qh_self) & ~0x1F);
 	printf("  link=");
 	ehci_dump_link(sc, qh->qh_link, 1);
@@ -870,7 +870,7 @@ ehci_dump_sqh(ehci_softc_t *sc, ehci_qh_
 static void
 ehci_dump_sitd(ehci_softc_t *sc, ehci_sitd_t *sitd)
 {
-	usb2_pc_cpu_invalidate(sitd->page_cache);
+	usb_pc_cpu_invalidate(sitd->page_cache);
 	printf("SITD(%p) at 0x%08x\n", sitd, hc32toh(sc, sitd->sitd_self) & ~0x1F);
 	printf(" next=0x%08x\n", hc32toh(sc, sitd->sitd_next));
 	printf(" portaddr=0x%08x dir=%s addr=%d endpt=0x%x port=0x%x huba=0x%x\n",
@@ -896,7 +896,7 @@ ehci_dump_sitd(ehci_softc_t *sc, ehci_si
 static void
 ehci_dump_itd(ehci_softc_t *sc, ehci_itd_t *itd)
 {
-	usb2_pc_cpu_invalidate(itd->page_cache);
+	usb_pc_cpu_invalidate(itd->page_cache);
 	printf("ITD(%p) at 0x%08x\n", itd, hc32toh(sc, itd->itd_self) & ~0x1F);
 	printf(" next=0x%08x\n", hc32toh(sc, itd->itd_next));
 	printf(" status[0]=0x%08x; <%s>\n", hc32toh(sc, itd->itd_status[0]),
@@ -978,11 +978,11 @@ ehci_transfer_intr_enqueue(struct usb_xf
 		return;
 	}
 	/* put transfer on interrupt queue */
-	usb2_transfer_enqueue(&xfer->xroot->bus->intr_q, xfer);
+	usbd_transfer_enqueue(&xfer->xroot->bus->intr_q, xfer);
 
 	/* start timeout, if any */
 	if (xfer->timeout != 0) {
-		usb2_transfer_timeout_ms(xfer, &ehci_timeout, xfer->timeout);
+		usbd_transfer_timeout_ms(xfer, &ehci_timeout, xfer->timeout);
 	}
 }
 
@@ -999,7 +999,7 @@ _ehci_append_fs_td(ehci_sitd_t *std, ehc
 
 	std->prev = last;
 
-	usb2_pc_cpu_flush(std->page_cache);
+	usb_pc_cpu_flush(std->page_cache);
 
 	/*
 	 * the last->next->prev is never followed: std->next->prev = std;
@@ -1007,7 +1007,7 @@ _ehci_append_fs_td(ehci_sitd_t *std, ehc
 	last->next = std;
 	last->sitd_next = std->sitd_self;
 
-	usb2_pc_cpu_flush(last->page_cache);
+	usb_pc_cpu_flush(last->page_cache);
 
 	return (std);
 }
@@ -1025,7 +1025,7 @@ _ehci_append_hs_td(ehci_itd_t *std, ehci
 
 	std->prev = last;
 
-	usb2_pc_cpu_flush(std->page_cache);
+	usb_pc_cpu_flush(std->page_cache);
 
 	/*
 	 * the last->next->prev is never followed: std->next->prev = std;
@@ -1033,7 +1033,7 @@ _ehci_append_hs_td(ehci_itd_t *std, ehci
 	last->next = std;
 	last->itd_next = std->itd_self;
 
-	usb2_pc_cpu_flush(last->page_cache);
+	usb_pc_cpu_flush(last->page_cache);
 
 	return (std);
 }
@@ -1056,7 +1056,7 @@ _ehci_append_qh(ehci_qh_t *sqh, ehci_qh_
 
 	sqh->prev = last;
 
-	usb2_pc_cpu_flush(sqh->page_cache);
+	usb_pc_cpu_flush(sqh->page_cache);
 
 	/*
 	 * the last->next->prev is never followed: sqh->next->prev = sqh;
@@ -1065,7 +1065,7 @@ _ehci_append_qh(ehci_qh_t *sqh, ehci_qh_
 	last->next = sqh;
 	last->qh_link = sqh->qh_self;
 
-	usb2_pc_cpu_flush(last->page_cache);
+	usb_pc_cpu_flush(last->page_cache);
 
 	return (sqh);
 }
@@ -1081,11 +1081,11 @@ _ehci_remove_fs_td(ehci_sitd_t *std, ehc
 	std->prev->next = std->next;
 	std->prev->sitd_next = std->sitd_next;
 
-	usb2_pc_cpu_flush(std->prev->page_cache);
+	usb_pc_cpu_flush(std->prev->page_cache);
 
 	if (std->next) {
 		std->next->prev = std->prev;
-		usb2_pc_cpu_flush(std->next->page_cache);
+		usb_pc_cpu_flush(std->next->page_cache);
 	}
 	return ((last == std) ? std->prev : last);
 }
@@ -1101,11 +1101,11 @@ _ehci_remove_hs_td(ehci_itd_t *std, ehci
 	std->prev->next = std->next;
 	std->prev->itd_next = std->itd_next;
 
-	usb2_pc_cpu_flush(std->prev->page_cache);
+	usb_pc_cpu_flush(std->prev->page_cache);
 
 	if (std->next) {
 		std->next->prev = std->prev;
-		usb2_pc_cpu_flush(std->next->page_cache);
+		usb_pc_cpu_flush(std->next->page_cache);
 	}
 	return ((last == std) ? std->prev : last);
 }
@@ -1124,17 +1124,17 @@ _ehci_remove_qh(ehci_qh_t *sqh, ehci_qh_
 		sqh->prev->next = sqh->next;
 		sqh->prev->qh_link = sqh->qh_link;
 
-		usb2_pc_cpu_flush(sqh->prev->page_cache);
+		usb_pc_cpu_flush(sqh->prev->page_cache);
 
 		if (sqh->next) {
 			sqh->next->prev = sqh->prev;
-			usb2_pc_cpu_flush(sqh->next->page_cache);
+			usb_pc_cpu_flush(sqh->next->page_cache);
 		}
 		last = ((last == sqh) ? sqh->prev : last);
 
 		sqh->prev = 0;
 
-		usb2_pc_cpu_flush(sqh->page_cache);
+		usb_pc_cpu_flush(sqh->page_cache);
 	}
 	return (last);
 }
@@ -1156,7 +1156,7 @@ ehci_non_isoc_done_sub(struct usb_xfer *
 	}
 	while (1) {
 
-		usb2_pc_cpu_invalidate(td->page_cache);
+		usb_pc_cpu_invalidate(td->page_cache);
 		status = hc32toh(sc, td->qtd_status);
 
 		len = EHCI_QTD_GET_BYTES(status);
@@ -1306,13 +1306,13 @@ ehci_check_transfer(struct usb_xfer *xfe
 		/* isochronous full speed transfer */
 
 		td = xfer->td_transfer_last;
-		usb2_pc_cpu_invalidate(td->page_cache);
+		usb_pc_cpu_invalidate(td->page_cache);
 		status = hc32toh(sc, td->sitd_status);
 
 		/* also check if first is complete */
 
 		td = xfer->td_transfer_first;
-		usb2_pc_cpu_invalidate(td->page_cache);
+		usb_pc_cpu_invalidate(td->page_cache);
 		status |= hc32toh(sc, td->sitd_status);
 
 		if (!(status & EHCI_SITD_ACTIVE)) {
@@ -1325,7 +1325,7 @@ ehci_check_transfer(struct usb_xfer *xfe
 		/* isochronous high speed transfer */
 
 		td = xfer->td_transfer_last;
-		usb2_pc_cpu_invalidate(td->page_cache);
+		usb_pc_cpu_invalidate(td->page_cache);
 		status =
 		    td->itd_status[0] | td->itd_status[1] |
 		    td->itd_status[2] | td->itd_status[3] |
@@ -1334,7 +1334,7 @@ ehci_check_transfer(struct usb_xfer *xfe
 
 		/* also check first transfer */
 		td = xfer->td_transfer_first;
-		usb2_pc_cpu_invalidate(td->page_cache);
+		usb_pc_cpu_invalidate(td->page_cache);
 		status |=
 		    td->itd_status[0] | td->itd_status[1] |
 		    td->itd_status[2] | td->itd_status[3] |
@@ -1358,7 +1358,7 @@ ehci_check_transfer(struct usb_xfer *xfe
 		td = xfer->td_transfer_cache;
 
 		while (1) {
-			usb2_pc_cpu_invalidate(td->page_cache);
+			usb_pc_cpu_invalidate(td->page_cache);
 			status = hc32toh(sc, td->qtd_status);
 
 			/*
@@ -1494,7 +1494,7 @@ ehci_interrupt(ehci_softc_t *sc)
 		ehci_root_intr(sc);
 
 		/* do not allow RHSC interrupts > 1 per second */
-		usb2_callout_reset(&sc->sc_tmo_pcd, hz,
+		usb_callout_reset(&sc->sc_tmo_pcd, hz,
 		    (void *)&ehci_pcd_enable, sc);
 	}
 	status &= ~(EHCI_STS_INT | EHCI_STS_ERRINT | EHCI_STS_PCD | EHCI_STS_IAA);
@@ -1653,7 +1653,7 @@ restart:
 
 			/* fill out buffer pointers */
 
-			usb2_get_page(temp->pc, buf_offset, &buf_res);
+			usbd_get_page(temp->pc, buf_offset, &buf_res);
 			td->qtd_buffer[0] =
 			    htohc32(temp->sc, buf_res.physaddr);
 			td->qtd_buffer_hi[0] = 0;
@@ -1663,7 +1663,7 @@ restart:
 			while (average > EHCI_PAGE_SIZE) {
 				average -= EHCI_PAGE_SIZE;
 				buf_offset += EHCI_PAGE_SIZE;
-				usb2_get_page(temp->pc, buf_offset, &buf_res);
+				usbd_get_page(temp->pc, buf_offset, &buf_res);
 				td->qtd_buffer[x] =
 				    htohc32(temp->sc,
 				    buf_res.physaddr & (~0xFFF));
@@ -1680,7 +1680,7 @@ restart:
 			 * of a valid page !
 			 */
 			buf_offset += average;
-			usb2_get_page(temp->pc, buf_offset - 1, &buf_res);
+			usbd_get_page(temp->pc, buf_offset - 1, &buf_res);
 			td->qtd_buffer[x] =
 			    htohc32(temp->sc,
 			    buf_res.physaddr & (~0xFFF));
@@ -1694,7 +1694,7 @@ restart:
 		td->qtd_altnext = qtd_altnext;
 		td->alt_next = td_alt_next;
 
-		usb2_pc_cpu_flush(td->page_cache);
+		usb_pc_cpu_flush(td->page_cache);
 	}
 
 	if (precompute) {
@@ -1736,7 +1736,7 @@ ehci_setup_standard_chain(struct usb_xfe
 
 	DPRINTFN(9, "addr=%d endpt=%d sumlen=%d speed=%d\n",
 	    xfer->address, UE_GET_ADDR(xfer->endpointno),
-	    xfer->sumlen, usb2_get_speed(xfer->xroot->udev));
+	    xfer->sumlen, usbd_get_speed(xfer->xroot->udev));
 
 	temp.average = xfer->max_hc_frame_size;
 	temp.max_frame_size = xfer->max_frame_size;
@@ -1768,7 +1768,7 @@ ehci_setup_standard_chain(struct usb_xfe
 		temp.auto_data_toggle = 1;
 	}
 
-	if (usb2_get_speed(xfer->xroot->udev) != USB_SPEED_HIGH) {
+	if (usbd_get_speed(xfer->xroot->udev) != USB_SPEED_HIGH) {
 		/* max 3 retries */
 		temp.qtd_status |=
 		    htohc32(temp.sc, EHCI_QTD_SET_CERR(3));
@@ -1891,7 +1891,7 @@ ehci_setup_standard_chain(struct usb_xfe
 	td->qtd_altnext = htohc32(temp.sc, EHCI_LINK_TERMINATE);
 	td->qtd_status |= htohc32(temp.sc, EHCI_QTD_IOC);
 
-	usb2_pc_cpu_flush(td->page_cache);
+	usb_pc_cpu_flush(td->page_cache);
 
 	/* must have at least one frame! */
 
@@ -1917,14 +1917,14 @@ ehci_setup_standard_chain(struct usb_xfe
 	    EHCI_QH_SET_ENDPT(UE_GET_ADDR(xfer->endpointno)) |
 	    EHCI_QH_SET_MPL(xfer->max_packet_size));
 
-	if (usb2_get_speed(xfer->xroot->udev) == USB_SPEED_HIGH) {
+	if (usbd_get_speed(xfer->xroot->udev) == USB_SPEED_HIGH) {
 		qh_endp |= (EHCI_QH_SET_EPS(EHCI_QH_SPEED_HIGH) |
 		    EHCI_QH_DTC);
 		if (methods != &ehci_device_intr_methods)
 			qh_endp |= EHCI_QH_SET_NRL(8);
 	} else {
 
-		if (usb2_get_speed(xfer->xroot->udev) == USB_SPEED_FULL) {
+		if (usbd_get_speed(xfer->xroot->udev) == USB_SPEED_FULL) {
 			qh_endp |= (EHCI_QH_SET_EPS(EHCI_QH_SPEED_FULL) |
 			    EHCI_QH_DTC);
 		} else {
@@ -1945,8 +1945,8 @@ ehci_setup_standard_chain(struct usb_xfe
 
 	qh_endphub =
 	    (EHCI_QH_SET_MULT(xfer->max_packet_count & 3) |
-	    EHCI_QH_SET_CMASK(xfer->usb2_cmask) |
-	    EHCI_QH_SET_SMASK(xfer->usb2_smask) |
+	    EHCI_QH_SET_CMASK(xfer->usb_cmask) |
+	    EHCI_QH_SET_SMASK(xfer->usb_smask) |
 	    EHCI_QH_SET_HUBA(xfer->xroot->udev->hs_hub_addr) |
 	    EHCI_QH_SET_PORT(xfer->xroot->udev->hs_port_no));
 
@@ -1974,7 +1974,7 @@ ehci_setup_standard_chain(struct usb_xfe
 	qh->qh_qtd.qtd_altnext =
 	    htohc32(temp.sc, EHCI_LINK_TERMINATE);
 
-	usb2_pc_cpu_flush(qh->page_cache);
+	usb_pc_cpu_flush(qh->page_cache);
 
 	if (xfer->xroot->udev->flags.self_suspended == 0) {
 		EHCI_APPEND_QH(qh, *qh_last);
@@ -2035,7 +2035,7 @@ ehci_isoc_fs_done(ehci_softc_t *sc, stru
 			ehci_dump_sitd(sc, td);
 		}
 #endif
-		usb2_pc_cpu_invalidate(td->page_cache);
+		usb_pc_cpu_invalidate(td->page_cache);
 		status = hc32toh(sc, td->sitd_status);
 
 		len = EHCI_SITD_GET_LEN(status);
@@ -2090,7 +2090,7 @@ ehci_isoc_hs_done(ehci_softc_t *sc, stru
 		}
 #endif
 
-		usb2_pc_cpu_invalidate(td->page_cache);
+		usb_pc_cpu_invalidate(td->page_cache);
 		status = hc32toh(sc, td->itd_status[td_no]);
 
 		len = EHCI_ITD_GET_LEN(status);
@@ -2174,7 +2174,7 @@ ehci_device_done(struct usb_xfer *xfer, 
 		xfer->td_transfer_last = NULL;
 	}
 	/* dequeue transfer and start next transfer */
-	usb2_transfer_done(xfer, error);
+	usbd_transfer_done(xfer, error);
 }
 
 /*------------------------------------------------------------------------*
@@ -2282,17 +2282,17 @@ ehci_device_intr_open(struct usb_xfer *x
 
 	/* Allocate a microframe slot first: */
 
-	slot = usb2_intr_schedule_adjust
+	slot = usb_intr_schedule_adjust
 	    (xfer->xroot->udev, xfer->max_frame_size, USB_HS_MICRO_FRAMES_MAX);
 
-	if (usb2_get_speed(xfer->xroot->udev) == USB_SPEED_HIGH) {
-		xfer->usb2_uframe = slot;
-		xfer->usb2_smask = (1 << slot) & 0xFF;
-		xfer->usb2_cmask = 0;
+	if (usbd_get_speed(xfer->xroot->udev) == USB_SPEED_HIGH) {
+		xfer->usb_uframe = slot;
+		xfer->usb_smask = (1 << slot) & 0xFF;
+		xfer->usb_cmask = 0;
 	} else {
-		xfer->usb2_uframe = slot;
-		xfer->usb2_smask = (1 << slot) & 0x3F;
-		xfer->usb2_cmask = (-(4 << slot)) & 0xFE;
+		xfer->usb_uframe = slot;
+		xfer->usb_smask = (1 << slot) & 0x3F;
+		xfer->usb_cmask = (-(4 << slot)) & 0xFE;
 	}
 
 	/*
@@ -2330,8 +2330,8 @@ ehci_device_intr_close(struct usb_xfer *
 	ehci_softc_t *sc = EHCI_BUS2SC(xfer->xroot->bus);
 	uint8_t slot;
 
-	slot = usb2_intr_schedule_adjust
-	    (xfer->xroot->udev, -(xfer->max_frame_size), xfer->usb2_uframe);
+	slot = usb_intr_schedule_adjust
+	    (xfer->xroot->udev, -(xfer->max_frame_size), xfer->usb_uframe);
 
 	sc->sc_intr_stat[xfer->qh_pos]--;
 
@@ -2403,7 +2403,7 @@ ehci_device_isoc_fs_open(struct usb_xfer
 			 */
 			td->sitd_back = htohc32(sc, EHCI_LINK_TERMINATE);
 
-			usb2_pc_cpu_flush(td->page_cache);
+			usb_pc_cpu_flush(td->page_cache);
 		}
 	}
 }
@@ -2478,7 +2478,7 @@ ehci_device_isoc_fs_enter(struct usb_xfe
 	 * pre-compute when the isochronous transfer will be finished:
 	 */
 	xfer->isoc_time_complete =
-	    usb2_fs_isoc_schedule_isoc_time_expand
+	    usbd_fs_isoc_schedule_isoc_time_expand
 	    (xfer->xroot->udev, &fss_start, &fss_end, nframes) + buf_offset +
 	    xfer->nframes;
 
@@ -2534,7 +2534,7 @@ ehci_device_isoc_fs_enter(struct usb_xfe
 		 * We currently don't care if the ISOCHRONOUS schedule is
 		 * full!
 		 */
-		error = usb2_fs_isoc_schedule_alloc(fss, &sa, *plen);
+		error = usbd_fs_isoc_schedule_alloc(fss, &sa, *plen);
 		if (error) {
 			/*
 			 * The FULL speed schedule is FULL! Set length
@@ -2544,17 +2544,17 @@ ehci_device_isoc_fs_enter(struct usb_xfe
 		}
 		if (*plen) {
 			/*
-			 * only call "usb2_get_page()" when we have a
+			 * only call "usbd_get_page()" when we have a
 			 * non-zero length
 			 */
-			usb2_get_page(xfer->frbuffers, buf_offset, &buf_res);
+			usbd_get_page(xfer->frbuffers, buf_offset, &buf_res);
 			td->sitd_bp[0] = htohc32(sc, buf_res.physaddr);
 			buf_offset += *plen;
 			/*
 			 * NOTE: We need to subtract one from the offset so
 			 * that we are on a valid page!
 			 */
-			usb2_get_page(xfer->frbuffers, buf_offset - 1,
+			usbd_get_page(xfer->frbuffers, buf_offset - 1,
 			    &buf_res);
 			temp = buf_res.physaddr & ~0xFFF;
 		} else {
@@ -2607,7 +2607,7 @@ ehci_device_isoc_fs_enter(struct usb_xfe
 			    EHCI_SITD_ACTIVE |
 			    EHCI_SITD_SET_LEN(*plen));
 		}
-		usb2_pc_cpu_flush(td->page_cache);
+		usb_pc_cpu_flush(td->page_cache);
 
 #if USB_DEBUG
 		if (ehcidebug > 15) {
@@ -2692,7 +2692,7 @@ ehci_device_isoc_hs_open(struct usb_xfer
 			/* set transfer multiplier */
 			td->itd_bp[2] = htohc32(sc, xfer->max_packet_count & 3);
 
-			usb2_pc_cpu_flush(td->page_cache);
+			usb_pc_cpu_flush(td->page_cache);
 		}
 	}
 }
@@ -2764,7 +2764,7 @@ ehci_device_isoc_hs_enter(struct usb_xfe
 	 * pre-compute when the isochronous transfer will be finished:
 	 */
 	xfer->isoc_time_complete =
-	    usb2_isoc_time_expand(&sc->sc_bus, nframes) + buf_offset +
+	    usb_isoc_time_expand(&sc->sc_bus, nframes) + buf_offset +
 	    ((xfer->nframes + 7) / 8);
 
 	/* get the real number of frames */

*** DIFF OUTPUT TRUNCATED AT 1000 LINES ***


More information about the svn-src-projects mailing list