reformatted, added diagnostics, defined swapped access
This commit is contained in:
@@ -163,8 +163,11 @@ static struct ehci {
|
||||
const char *slot_name;
|
||||
} gehci;
|
||||
|
||||
#define DEBUG
|
||||
#define SHOW_INFO
|
||||
|
||||
#ifdef DEBUG
|
||||
#define debug(format, arg...) board_printf("DEBUG: " format, ## arg)
|
||||
#define debug(format, arg...) xprintf("DEBUG: " format, ## arg)
|
||||
#else
|
||||
#define debug(format, arg...) do {} while (0)
|
||||
#endif /* DEBUG */
|
||||
|
||||
@@ -68,6 +68,8 @@
|
||||
/*
|
||||
* e.g. PCI controllers need this
|
||||
*/
|
||||
#define CONFIG_SYS_OHCI_SWAP_REG_ACCES
|
||||
|
||||
#ifdef CONFIG_SYS_OHCI_SWAP_REG_ACCESS
|
||||
#define readl(a) swpl(*((volatile uint32_t *)(a)))
|
||||
#define writel(a, b) (*((volatile uint32_t *)(b)) = swpl((volatile uint32_t)a))
|
||||
@@ -108,7 +110,15 @@ struct pci_device_id ohci_usb_pci_table[] =
|
||||
0
|
||||
}, /* Philips 1561 PCI OHCI module ids */
|
||||
/* Please add supported PCI OHCI controller ids here */
|
||||
{ 0, 0, 0, 0, 0, 0, 0 }
|
||||
{
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0
|
||||
}
|
||||
};
|
||||
|
||||
#ifdef DEBUG
|
||||
@@ -134,7 +144,8 @@ static inline uint32_t roothub_portstatus(ohci_t *ohci, int i) { return readl(&o
|
||||
static void flush_data_cache(ohci_t *ohci);
|
||||
static int hc_interrupt(ohci_t *ohci);
|
||||
static void td_submit_job(ohci_t *ohci, struct usb_device *dev, uint32_t pipe,
|
||||
void *buffer, int transfer_len, struct devrequest *setup, urb_priv_t *urb, int interval);
|
||||
void *buffer, int transfer_len, struct devrequest *setup,
|
||||
urb_priv_t *urb, int interval);
|
||||
|
||||
/*-------------------------------------------------------------------------*
|
||||
* URB support functions
|
||||
|
||||
@@ -248,7 +248,6 @@ int usb_mem_init(void)
|
||||
#ifdef USE_RADEON_MEMORY
|
||||
usb_buffer = (void *)offscren_reserved();
|
||||
if (usb_buffer == NULL)
|
||||
#else
|
||||
#endif
|
||||
memset(usb_buffer, 0, USB_BUFFER_SIZE);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user