]> err.no Git - linux-2.6/blobdiff - arch/mips/pci/pci-bcm1480.c
[MIPS] tb0219: Update copyright message.
[linux-2.6] / arch / mips / pci / pci-bcm1480.c
index f6774f54cd3c61f5aa42e9c184d2d390780652e3..5443ea3596f8376ceeae25b538fb29498c048bfc 100644 (file)
@@ -49,8 +49,8 @@
  * Macros for calculating offsets into config space given a device
  * structure or dev/fun/reg
  */
-#define CFGOFFSET(bus,devfn,where) (((bus)<<16)+((devfn)<<8)+(where))
-#define CFGADDR(bus,devfn,where)   CFGOFFSET((bus)->number,(devfn),where)
+#define CFGOFFSET(bus, devfn, where) (((bus)<<16)+((devfn)<<8)+(where))
+#define CFGADDR(bus, devfn, where)   CFGOFFSET((bus)->number, (devfn), where)
 
 static void *cfg_space;
 
@@ -74,8 +74,9 @@ static inline void WRITECFG32(u32 addr, u32 data)
        *(u32 *)(cfg_space + (addr & ~3)) = data;
 }
 
-int pcibios_map_irq(struct pci_dev *dev, u8 slot, u8 pin)
+int pcibios_map_irq(const struct pci_dev *dev, u8 slot, u8 pin)
 {
+       This is b0rked.
        return dev->irq;
 }
 
@@ -216,7 +217,7 @@ static int __init bcm1480_pcibios_init(void)
        /*
         * See if the PCI bus has been configured by the firmware.
         */
-       reg = *((volatile uint64_t *) IOADDR(A_SCD_SYSTEM_CFG));
+       reg = __raw_readq(IOADDR(A_SCD_SYSTEM_CFG));
        if (!(reg & M_BCM1480_SYS_PCI_HOST)) {
                bcm1480_bus_status |= PCI_DEVICE_MODE;
        } else {
@@ -254,7 +255,7 @@ static int __init bcm1480_pcibios_init(void)
        register_pci_controller(&bcm1480_controller);
 
 #ifdef CONFIG_VGA_CONSOLE
-       take_over_console(&vga_con,0,MAX_NR_CONSOLES-1,1);
+       take_over_console(&vga_con, 0, MAX_NR_CONSOLES-1, 1);
 #endif
        return 0;
 }