ChangeSet 1.1500.8.9, 2004/01/30 17:10:00-08:00, [EMAIL PROTECTED]
[PATCH] USB: remove pci_unmap_single() calls from usbcore
There's an unnecessary pci-ism in usbcore -- just an oversight
in some API conversion, and harmless on most systems. This'll
be a good thing to remove for non-PCI HCD support though.
drivers/usb/core/hcd.c | 15 +++++++++------
1 files changed, 9 insertions(+), 6 deletions(-)
diff -Nru a/drivers/usb/core/hcd.c b/drivers/usb/core/hcd.c
--- a/drivers/usb/core/hcd.c Mon Feb 9 14:41:27 2004
+++ b/drivers/usb/core/hcd.c Mon Feb 9 14:41:27 2004
@@ -34,7 +34,10 @@
#include <linux/slab.h>
#include <linux/completion.h>
#include <linux/uts.h> /* for UTS_SYSNAME */
-#include <linux/pci.h> /* for hcd->pdev and dma addressing */
+#include <linux/mm.h>
+#include <asm/io.h>
+#include <asm/scatterlist.h>
+#include <linux/device.h>
#include <linux/dma-mapping.h>
#include <asm/byteorder.h>
@@ -1474,16 +1477,16 @@
if (hcd->controller->dma_mask) {
if (usb_pipecontrol (urb->pipe)
&& !(urb->transfer_flags & URB_NO_SETUP_DMA_MAP))
- pci_unmap_single (hcd->pdev, urb->setup_dma,
+ dma_unmap_single (hcd->controller, urb->setup_dma,
sizeof (struct usb_ctrlrequest),
- PCI_DMA_TODEVICE);
+ DMA_TO_DEVICE);
if (urb->transfer_buffer_length != 0
&& !(urb->transfer_flags & URB_NO_TRANSFER_DMA_MAP))
- pci_unmap_single (hcd->pdev, urb->transfer_dma,
+ dma_unmap_single (hcd->controller, urb->transfer_dma,
urb->transfer_buffer_length,
usb_pipein (urb->pipe)
- ? PCI_DMA_FROMDEVICE
- : PCI_DMA_TODEVICE);
+ ? DMA_FROM_DEVICE
+ : DMA_TO_DEVICE);
}
/* pass ownership to the completion handler */
-------------------------------------------------------
The SF.Net email is sponsored by EclipseCon 2004
Premiere Conference on Open Tools Development and Integration
See the breadth of Eclipse activity. February 3-5 in Anaheim, CA.
http://www.eclipsecon.org/osdn
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel