aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sparc64
diff options
context:
space:
mode:
Diffstat (limited to 'arch/sparc64')
-rw-r--r--arch/sparc64/kernel/of_device.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/arch/sparc64/kernel/of_device.c b/arch/sparc64/kernel/of_device.c
index cec0eceae552..b0f3e0082a0d 100644
--- a/arch/sparc64/kernel/of_device.c
+++ b/arch/sparc64/kernel/of_device.c
@@ -144,9 +144,12 @@ void __iomem *of_ioremap(struct resource *res, unsigned long offset, unsigned lo
144} 144}
145EXPORT_SYMBOL(of_ioremap); 145EXPORT_SYMBOL(of_ioremap);
146 146
147void of_iounmap(void __iomem *base, unsigned long size) 147void of_iounmap(struct resource *res, void __iomem *base, unsigned long size)
148{ 148{
149 release_region((unsigned long) base, size); 149 if (res->flags & IORESOURCE_MEM)
150 release_mem_region((unsigned long) base, size);
151 else
152 release_region((unsigned long) base, size);
150} 153}
151EXPORT_SYMBOL(of_iounmap); 154EXPORT_SYMBOL(of_iounmap);
152 155