diff --git a/BaS_gcc/include/ehci.h b/BaS_gcc/include/ehci.h index 09f1021..6176a9a 100644 --- a/BaS_gcc/include/ehci.h +++ b/BaS_gcc/include/ehci.h @@ -22,6 +22,7 @@ #ifndef USB_EHCI_H #define USB_EHCI_H +#define CONFIG_SYS_USB_EHCI_MAX_ROOT_PORTS 5 #if !defined(CONFIG_SYS_USB_EHCI_MAX_ROOT_PORTS) #define CONFIG_SYS_USB_EHCI_MAX_ROOT_PORTS 2 #endif diff --git a/BaS_gcc/sources/ehci-hcd.c b/BaS_gcc/sources/ehci-hcd.c index 2d1ffce..377b950 100644 --- a/BaS_gcc/sources/ehci-hcd.c +++ b/BaS_gcc/sources/ehci-hcd.c @@ -556,7 +556,7 @@ static int ehci_submit_root(struct usb_device *dev, uint32_t pipe, void *buffer, uint32_t *status_reg; if (swpw(req->index) > CONFIG_SYS_USB_EHCI_MAX_ROOT_PORTS) { - err("The request port(%d) is not configured\r\n", swpw(req->index) - 1); + err("the requested port(%d) is not configured\r\n", swpw(req->index) - 1); return -1; } status_reg = (uint32_t *)&gehci.hcor->or_portsc[swpw(req->index) - 1]; diff --git a/BaS_gcc/sources/pci.c b/BaS_gcc/sources/pci.c index d6f8e2f..d5304d0 100644 --- a/BaS_gcc/sources/pci.c +++ b/BaS_gcc/sources/pci.c @@ -40,7 +40,11 @@ #define debug_printf(format, arg...) do { ; } while (0) #endif /* DEBUG_PCI */ +#if MACHINE_FIREBEE #define pci_config_wait() wait(20000); /* FireBee USB not properly detected otherwise */ +#elif MACHINE_M5484LITE +#define pci_config_wait() do { ; } while (0) +#endif /* * PCI device class descriptions displayed during PCI bus scan diff --git a/BaS_gcc/sources/usb.c b/BaS_gcc/sources/usb.c index ef53623..2df8ce9 100644 --- a/BaS_gcc/sources/usb.c +++ b/BaS_gcc/sources/usb.c @@ -56,7 +56,7 @@ extern int usb_stor_curr_dev; extern uint32_t usb_1st_disk_drive; -#define USB_DEBUG +//#define USB_DEBUG #ifdef USB_DEBUG #define debug_printf(fmt, args...) xprintf(fmt , ##args) @@ -180,7 +180,7 @@ int usb_init(int32_t handle, const struct pci_device_id *ent) usb_started = 0; return -1; /* out of memoy */ } - debug_printf("Scanning bus for devices... "); + xprintf("Scanning bus for devices... "); controller_priv[bus_index] = (struct hci *)priv; controller_priv[bus_index]->usbnum = bus_index; usb_scan_devices(priv); @@ -1079,13 +1079,13 @@ void usb_scan_devices(void *priv) dev = usb_alloc_new_device(bus_index, priv); if (usb_new_device(dev)) { - debug_printf("No USB Device found\r\n"); + xprintf("No USB Device found\r\n"); if (dev != NULL) dev_index[bus_index]--; } else { - debug_printf("%d USB Device(s) found\r\n", dev_index[bus_index]); + xprintf("%d USB Device(s) found\r\n", dev_index[bus_index]); } { /* insert "driver" if possible */ @@ -1100,7 +1100,7 @@ void usb_scan_devices(void *priv) else debug_printf("USB HID mouse driver installed\r\n"); } - debug_printf("Scan end\r\n"); + xprintf("Scan end\r\n"); } /**************************************************************************** @@ -1108,7 +1108,7 @@ void usb_scan_devices(void *priv) * Probes device for being a hub and configurate it */ -#define USB_HUB_DEBUG +//#define USB_HUB_DEBUG #ifdef USB_HUB_DEBUG #define dbg_hub(fmt, args...) xprintf(fmt , ##args)