]> Pileus Git - ~andy/linux/blobdiff - drivers/usb/early/ehci-dbgp.c
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wirel...
[~andy/linux] / drivers / usb / early / ehci-dbgp.c
index a6a350f5827bb6a4240fb6b535e15defde84d5fd..1fc8f1249806ab964645b5395e2f2d099a80a757 100644 (file)
@@ -102,6 +102,9 @@ static struct kgdb_io kgdbdbgp_io_ops;
 #define dbgp_kgdb_mode (0)
 #endif
 
+/* Local version of HC_LENGTH macro as ehci struct is not available here */
+#define EARLY_HC_LENGTH(p)     (0x00ff & (p)) /* bits 7 : 0 */
+
 /*
  * USB Packet IDs (PIDs)
  */
@@ -892,7 +895,7 @@ int __init early_dbgp_init(char *s)
        dbgp_printk("ehci_bar: %p\n", ehci_bar);
 
        ehci_caps  = ehci_bar;
-       ehci_regs  = ehci_bar + HC_LENGTH(readl(&ehci_caps->hc_capbase));
+       ehci_regs  = ehci_bar + EARLY_HC_LENGTH(readl(&ehci_caps->hc_capbase));
        ehci_debug = ehci_bar + offset;
        ehci_dev.bus = bus;
        ehci_dev.slot = slot;