diff options
author | Thomas Petazzoni <thomas.petazzoni@free-electrons.com> | 2012-09-11 08:27:19 -0400 |
---|---|---|
committer | Jason Cooper <jason@lakedaemon.net> | 2012-09-21 14:03:35 -0400 |
commit | 060f3d191b1d80312d7c90de2f3c3356db413f40 (patch) | |
tree | 084ff4029442389bcdf1e4cf5c2d6081f08c458a /arch/arm/mach-kirkwood/pcie.c | |
parent | c3c5a2815d0b7ebde157556685a0ef8ffa34b98c (diff) |
arm: mach-kirkwood: use IOMEM() for base address definitions
We now define all virtual base address constants using IOMEM() so that
those are naturally typed as void __iomem pointers, and we do the
necessary adjustements in the mach-kirkwood code.
Note that we introduce a few temporary additional "unsigned long"
casts when calling into plat-orion functions. Those are removed by
followup patches converting plat-orion functions to void __iomem
pointers as well.
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Acked-by: Arnd Bergmann <arnd@arndb.de>
Tested-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: Jason Cooper <jason@lakedaemon.net>
Diffstat (limited to 'arch/arm/mach-kirkwood/pcie.c')
-rw-r--r-- | arch/arm/mach-kirkwood/pcie.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/arch/arm/mach-kirkwood/pcie.c b/arch/arm/mach-kirkwood/pcie.c index 6e8b2efa3c35..df6399dea745 100644 --- a/arch/arm/mach-kirkwood/pcie.c +++ b/arch/arm/mach-kirkwood/pcie.c | |||
@@ -47,8 +47,8 @@ void kirkwood_enable_pcie(void) | |||
47 | void kirkwood_pcie_id(u32 *dev, u32 *rev) | 47 | void kirkwood_pcie_id(u32 *dev, u32 *rev) |
48 | { | 48 | { |
49 | kirkwood_enable_pcie(); | 49 | kirkwood_enable_pcie(); |
50 | *dev = orion_pcie_dev_id((void __iomem *)PCIE_VIRT_BASE); | 50 | *dev = orion_pcie_dev_id(PCIE_VIRT_BASE); |
51 | *rev = orion_pcie_rev((void __iomem *)PCIE_VIRT_BASE); | 51 | *rev = orion_pcie_rev(PCIE_VIRT_BASE); |
52 | } | 52 | } |
53 | 53 | ||
54 | struct pcie_port { | 54 | struct pcie_port { |
@@ -133,7 +133,7 @@ static struct pci_ops pcie_ops = { | |||
133 | 133 | ||
134 | static void __init pcie0_ioresources_init(struct pcie_port *pp) | 134 | static void __init pcie0_ioresources_init(struct pcie_port *pp) |
135 | { | 135 | { |
136 | pp->base = (void __iomem *)PCIE_VIRT_BASE; | 136 | pp->base = PCIE_VIRT_BASE; |
137 | pp->irq = IRQ_KIRKWOOD_PCIE; | 137 | pp->irq = IRQ_KIRKWOOD_PCIE; |
138 | 138 | ||
139 | /* | 139 | /* |
@@ -155,7 +155,7 @@ static void __init pcie0_ioresources_init(struct pcie_port *pp) | |||
155 | 155 | ||
156 | static void __init pcie1_ioresources_init(struct pcie_port *pp) | 156 | static void __init pcie1_ioresources_init(struct pcie_port *pp) |
157 | { | 157 | { |
158 | pp->base = (void __iomem *)PCIE1_VIRT_BASE; | 158 | pp->base = PCIE1_VIRT_BASE; |
159 | pp->irq = IRQ_KIRKWOOD_PCIE1; | 159 | pp->irq = IRQ_KIRKWOOD_PCIE1; |
160 | 160 | ||
161 | /* | 161 | /* |
@@ -273,11 +273,11 @@ static struct hw_pci kirkwood_pci __initdata = { | |||
273 | .map_irq = kirkwood_pcie_map_irq, | 273 | .map_irq = kirkwood_pcie_map_irq, |
274 | }; | 274 | }; |
275 | 275 | ||
276 | static void __init add_pcie_port(int index, unsigned long base) | 276 | static void __init add_pcie_port(int index, void __iomem *base) |
277 | { | 277 | { |
278 | printk(KERN_INFO "Kirkwood PCIe port %d: ", index); | 278 | printk(KERN_INFO "Kirkwood PCIe port %d: ", index); |
279 | 279 | ||
280 | if (orion_pcie_link_up((void __iomem *)base)) { | 280 | if (orion_pcie_link_up(base)) { |
281 | printk(KERN_INFO "link up\n"); | 281 | printk(KERN_INFO "link up\n"); |
282 | pcie_port_map[num_pcie_ports++] = index; | 282 | pcie_port_map[num_pcie_ports++] = index; |
283 | } else | 283 | } else |