Commit b624b553 authored by Alexander Viro's avatar Alexander Viro Committed by Linus Torvalds

[PATCH] ppc __iomem annotations - gg2

gg2_pci_config_base is an iomem pointer.
Signed-off-by: default avatarAl Viro <viro@parcelfarce.linux.theplanet.co.uk>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent 7bc0ea5e
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
#include <asm/open_pic.h> #include <asm/open_pic.h>
/* LongTrail */ /* LongTrail */
unsigned long gg2_pci_config_base; void __iomem *gg2_pci_config_base;
/* /*
* The VLSI Golden Gate II has only 512K of PCI configuration space, so we * The VLSI Golden Gate II has only 512K of PCI configuration space, so we
...@@ -253,9 +253,10 @@ chrp_find_bridges(void) ...@@ -253,9 +253,10 @@ chrp_find_bridges(void)
|| strncmp(model, "Motorola, Grackle", 17) == 0) { || strncmp(model, "Motorola, Grackle", 17) == 0) {
setup_grackle(hose); setup_grackle(hose);
} else if (is_longtrail) { } else if (is_longtrail) {
void __iomem *p = ioremap(GG2_PCI_CONFIG_BASE, 0x80000);
hose->ops = &gg2_pci_ops; hose->ops = &gg2_pci_ops;
hose->cfg_data = ioremap(GG2_PCI_CONFIG_BASE, 0x80000); hose->cfg_data = p;
gg2_pci_config_base = (unsigned long) hose->cfg_data; gg2_pci_config_base = p;
} else { } else {
printk("No methods for %s (model %s), using RTAS\n", printk("No methods for %s (model %s), using RTAS\n",
dev->full_name, model); dev->full_name, model);
......
...@@ -118,13 +118,12 @@ chrp_show_cpuinfo(struct seq_file *m) ...@@ -118,13 +118,12 @@ chrp_show_cpuinfo(struct seq_file *m)
if (!strncmp(model, "IBM,LongTrail", 13)) { if (!strncmp(model, "IBM,LongTrail", 13)) {
/* VLSI VAS96011/12 `Golden Gate 2' */ /* VLSI VAS96011/12 `Golden Gate 2' */
/* Memory banks */ /* Memory banks */
sdramen = (in_le32((unsigned *)(gg2_pci_config_base+ sdramen = (in_le32(gg2_pci_config_base + GG2_PCI_DRAM_CTRL)
GG2_PCI_DRAM_CTRL))
>>31) & 1; >>31) & 1;
for (i = 0; i < (sdramen ? 4 : 6); i++) { for (i = 0; i < (sdramen ? 4 : 6); i++) {
t = in_le32((unsigned *)(gg2_pci_config_base+ t = in_le32(gg2_pci_config_base+
GG2_PCI_DRAM_BANK0+ GG2_PCI_DRAM_BANK0+
i*4)); i*4);
if (!(t & 1)) if (!(t & 1))
continue; continue;
switch ((t>>8) & 0x1f) { switch ((t>>8) & 0x1f) {
...@@ -154,7 +153,7 @@ chrp_show_cpuinfo(struct seq_file *m) ...@@ -154,7 +153,7 @@ chrp_show_cpuinfo(struct seq_file *m)
gg2_memtypes[sdramen ? 1 : ((t>>1) & 3)]); gg2_memtypes[sdramen ? 1 : ((t>>1) & 3)]);
} }
/* L2 cache */ /* L2 cache */
t = in_le32((unsigned *)(gg2_pci_config_base+GG2_PCI_CC_CTRL)); t = in_le32(gg2_pci_config_base+GG2_PCI_CC_CTRL);
seq_printf(m, "board l2\t: %s %s (%s)\n", seq_printf(m, "board l2\t: %s %s (%s)\n",
gg2_cachesizes[(t>>7) & 3], gg2_cachesizes[(t>>7) & 3],
gg2_cachetypes[(t>>2) & 3], gg2_cachetypes[(t>>2) & 3],
......
...@@ -34,7 +34,7 @@ ...@@ -34,7 +34,7 @@
* GG2 specific PCI Registers * GG2 specific PCI Registers
*/ */
extern unsigned long gg2_pci_config_base; /* kernel virtual address */ extern void __iomem *gg2_pci_config_base; /* kernel virtual address */
#define GG2_PCI_BUSNO 0x40 /* Bus number */ #define GG2_PCI_BUSNO 0x40 /* Bus number */
#define GG2_PCI_SUBBUSNO 0x41 /* Subordinate bus number */ #define GG2_PCI_SUBBUSNO 0x41 /* Subordinate bus number */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment