projects
/
oweals
/
u-boot.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'master' of git://git.denx.de/u-boot-arm
[oweals/u-boot.git]
/
cpu
/
mips
/
au1x00_usb_ohci.c
diff --git
a/cpu/mips/au1x00_usb_ohci.c
b/cpu/mips/au1x00_usb_ohci.c
index dbf72dc6f8c9fb9b5d50cd8aff23c861b1613517..ea02efbb0dd169a0093672628b43734492bf65a4 100644
(file)
--- a/
cpu/mips/au1x00_usb_ohci.c
+++ b/
cpu/mips/au1x00_usb_ohci.c
@@
-27,15
+27,13
@@
*/
/*
* IMPORTANT NOTES
*/
/*
* IMPORTANT NOTES
- * 1 - you MUST define LITTLEENDIAN in the configuration file for the
- * board or this driver will NOT work!
- * 2 - this driver is intended for use with USB Mass Storage Devices
+ * 1 - this driver is intended for use with USB Mass Storage Devices
* (BBB) ONLY. There is NO support for Interrupt or Isochronous pipes!
*/
#include <config.h>
* (BBB) ONLY. There is NO support for Interrupt or Isochronous pipes!
*/
#include <config.h>
-#if
defined(CONFIG_AU1X00) && defined(CONFIG_USB_OHCI)
+#if
def CONFIG_USB_OHCI
/* #include <pci.h> no PCI on the AU1x00 */
/* #include <pci.h> no PCI on the AU1x00 */
@@
-56,7
+54,7
@@
#define USBH_ENABLE_CE (1<<3)
#define USBH_ENABLE_RD (1<<4)
#define USBH_ENABLE_CE (1<<3)
#define USBH_ENABLE_RD (1<<4)
-#ifdef
LITTLE
ENDIAN
+#ifdef
__LITTLE_
ENDIAN
#define USBH_ENABLE_INIT (USBH_ENABLE_CE | USBH_ENABLE_E | USBH_ENABLE_C)
#else
#define USBH_ENABLE_INIT (USBH_ENABLE_CE | USBH_ENABLE_E | USBH_ENABLE_C | USBH_ENABLE_BE)
#define USBH_ENABLE_INIT (USBH_ENABLE_CE | USBH_ENABLE_E | USBH_ENABLE_C)
#else
#define USBH_ENABLE_INIT (USBH_ENABLE_CE | USBH_ENABLE_E | USBH_ENABLE_C | USBH_ENABLE_BE)
@@
-654,7
+652,8
@@
static void td_fill (ohci_t *ohci, unsigned int info,
td->index = index;
td->data = (__u32)data;
#ifdef OHCI_FILL_TRACE
td->index = index;
td->data = (__u32)data;
#ifdef OHCI_FILL_TRACE
- if (1 || ((usb_pipetype(urb_priv->pipe) == PIPE_BULK) && usb_pipeout(urb_priv->pipe))) {
+ if (1 || (usb_pipebulk(urb_priv->pipe) &&
+ usb_pipeout(urb_priv->pipe))) {
for (i = 0; i < len; i++)
printf("td->data[%d] %#2x\n",i, ((unsigned char *)(td->data+0x80000000))[i]);
}
for (i = 0; i < len; i++)
printf("td->data[%d] %#2x\n",i, ((unsigned char *)(td->data+0x80000000))[i]);
}
@@
-758,7
+757,7
@@
static void dl_transfer_length(td_t * td)
tdCBP = m32_swap (td->hwCBP);
tdCBP = m32_swap (td->hwCBP);
- if (!(usb_pipe
type (lurb_priv->pipe) == PIPE_CONTROL
&&
+ if (!(usb_pipe
control(lurb_priv->pipe)
&&
((td->index == 0) || (td->index == lurb_priv->length - 1)))) {
if (tdBE != 0) {
if (td->hwCBP == 0)
((td->index == 0) || (td->index == lurb_priv->length - 1)))) {
if (tdBE != 0) {
if (td->hwCBP == 0)
@@
-1015,7
+1014,7
@@
pkt_print(dev, pipe, buffer, transfer_len, cmd, "SUB(rh)", usb_pipein(pipe));
#else
wait_ms(1);
#endif
#else
wait_ms(1);
#endif
- if (
(pipe & PIPE_INTERRUPT) == PIPE_INTERRUPT
) {
+ if (
usb_pipeint(pipe)
) {
info("Root-Hub submit IRQ: NOT implemented");
return 0;
}
info("Root-Hub submit IRQ: NOT implemented");
return 0;
}
@@
-1249,7
+1248,7
@@
int submit_common_msg(struct usb_device *dev, unsigned long pipe, void *buffer,
/* allow more time for a BULK device to react - some are slow */
#define BULK_TO 5000 /* timeout in milliseconds */
/* allow more time for a BULK device to react - some are slow */
#define BULK_TO 5000 /* timeout in milliseconds */
- if (usb_pipe
type (pipe) == PIPE_BULK
)
+ if (usb_pipe
bulk(pipe)
)
timeout = BULK_TO;
else
timeout = 100;
timeout = BULK_TO;
else
timeout = 100;