summaryrefslogtreecommitdiff
path: root/arch/sparc64
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2006-06-29 14:35:33 -0700
committerDavid S. Miller <davem@sunset.davemloft.net>2006-06-29 16:37:16 -0700
commit3ca9fab410fbef6fc3a13284f5c26faccade21d1 (patch)
tree91b4c38077db397bec0ff85f1c89c9f869b3970f /arch/sparc64
parent95714e12dfb4794ee120f058fdf763e61baaad82 (diff)
downloadlinux-3.10-3ca9fab410fbef6fc3a13284f5c26faccade21d1.tar.gz
linux-3.10-3ca9fab410fbef6fc3a13284f5c26faccade21d1.tar.bz2
linux-3.10-3ca9fab410fbef6fc3a13284f5c26faccade21d1.zip
[SPARC]: Add of_io{remap,unmap}().
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc64')
-rw-r--r--arch/sparc64/kernel/of_device.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/arch/sparc64/kernel/of_device.c b/arch/sparc64/kernel/of_device.c
index 00502dc280e..9812cfa6dd3 100644
--- a/arch/sparc64/kernel/of_device.c
+++ b/arch/sparc64/kernel/of_device.c
@@ -129,6 +129,23 @@ static int of_device_resume(struct device * dev)
return error;
}
+void __iomem *of_ioremap(struct resource *res, unsigned long offset, unsigned long size, char *name)
+{
+ unsigned long ret = res->start + offset;
+
+ if (!request_region(ret, size, name))
+ ret = 0;
+
+ return (void __iomem *) ret;
+}
+EXPORT_SYMBOL(of_ioremap);
+
+void of_iounmap(void __iomem *base, unsigned long size)
+{
+ release_region((unsigned long) base, size);
+}
+EXPORT_SYMBOL(of_iounmap);
+
#ifdef CONFIG_PCI
struct bus_type isa_bus_type = {
.name = "isa",