diff options
author | Paul Mundt <lethal@linux-sh.org> | 2009-12-14 14:23:41 +0900 |
---|---|---|
committer | Paul Mundt <lethal@linux-sh.org> | 2009-12-14 14:23:41 +0900 |
commit | bf3cdeda901c7f42de3cddc8c5aa19f6b8d8f9df (patch) | |
tree | 4f0ebc608a8ea53d723be1695fbc9606a255ae85 /arch/sh/mm | |
parent | 1232d88a47626cad13ba82f3a9ea814820bc1c65 (diff) | |
download | linux-3.10-bf3cdeda901c7f42de3cddc8c5aa19f6b8d8f9df.tar.gz linux-3.10-bf3cdeda901c7f42de3cddc8c5aa19f6b8d8f9df.tar.bz2 linux-3.10-bf3cdeda901c7f42de3cddc8c5aa19f6b8d8f9df.zip |
sh: wire up vmallocinfo support in ioremap() implementations.
This wires up the caller information for the ioremap VMA, which allows
for more helpful caller tracking via /proc/vmallocinfo. Follows the x86
and powerpc changes of the same nature.
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Diffstat (limited to 'arch/sh/mm')
-rw-r--r-- | arch/sh/mm/ioremap_32.c | 10 | ||||
-rw-r--r-- | arch/sh/mm/ioremap_64.c | 6 |
2 files changed, 8 insertions, 8 deletions
diff --git a/arch/sh/mm/ioremap_32.c b/arch/sh/mm/ioremap_32.c index a86eaa9d75a..2141befb4f9 100644 --- a/arch/sh/mm/ioremap_32.c +++ b/arch/sh/mm/ioremap_32.c @@ -33,10 +33,10 @@ * have to convert them into an offset in a page-aligned mapping, but the * caller shouldn't need to know that small detail. */ -void __iomem *__ioremap(unsigned long phys_addr, unsigned long size, - unsigned long flags) +void __iomem *__ioremap_caller(unsigned long phys_addr, unsigned long size, + unsigned long flags, void *caller) { - struct vm_struct * area; + struct vm_struct *area; unsigned long offset, last_addr, addr, orig_addr; pgprot_t pgprot; @@ -67,7 +67,7 @@ void __iomem *__ioremap(unsigned long phys_addr, unsigned long size, /* * Ok, go for it.. */ - area = get_vm_area(size, VM_IOREMAP); + area = get_vm_area_caller(size, VM_IOREMAP, caller); if (!area) return NULL; area->phys_addr = phys_addr; @@ -103,7 +103,7 @@ void __iomem *__ioremap(unsigned long phys_addr, unsigned long size, return (void __iomem *)(offset + (char *)orig_addr); } -EXPORT_SYMBOL(__ioremap); +EXPORT_SYMBOL(__ioremap_caller); void __iounmap(void __iomem *addr) { diff --git a/arch/sh/mm/ioremap_64.c b/arch/sh/mm/ioremap_64.c index b16843d02b7..ef434657d42 100644 --- a/arch/sh/mm/ioremap_64.c +++ b/arch/sh/mm/ioremap_64.c @@ -258,15 +258,15 @@ static void shmedia_unmapioaddr(unsigned long vaddr) pte_clear(&init_mm, vaddr, ptep); } -void __iomem *__ioremap(unsigned long offset, unsigned long size, - unsigned long flags) +void __iomem *__ioremap_caller(unsigned long offset, unsigned long size, + unsigned long flags, void *caller) { char name[14]; sprintf(name, "phys_%08x", (u32)offset); return shmedia_alloc_io(offset, size, name, flags); } -EXPORT_SYMBOL(__ioremap); +EXPORT_SYMBOL(__ioremap_caller); void __iounmap(void __iomem *virtual) { |