sh: P4 ioremap pass-through
authorMagnus Damm <damm@igel.co.jp>
Tue, 25 Nov 2008 12:57:29 +0000 (21:57 +0900)
committerPaul Mundt <lethal@linux-sh.org>
Mon, 22 Dec 2008 09:43:48 +0000 (18:43 +0900)
commit716777db7270255f1f7210fd87a7188b08c9a267
tree01e65e44140231a2b16d7ebd273e7e7b280decb7
parent0c9122323acb0c3410dfbd219cb47f4c2e9305e3
sh: P4 ioremap pass-through

This patch adds a pass-through case when ioremapping P4 addresses.

Addresses passed to ioremap() should be physical addresses, so the
best option is usually to convert the virtual address to a physical
address before calling ioremap. This will give you a virtual address
in P2 which matches the physical address and this works well for
most internal hardware blocks on the SuperH architecture.

However, some hardware blocks must be accessed through P4. Converting
the P4 address to a physical and then back to a P2 does not work. One
example of this is the sh7722 TMU block, it must be accessed through P4.

Without this patch P4 addresses will be mapped using PTEs which
requires the page allocator to be up and running.

Signed-off-by: Magnus Damm <damm@igel.co.jp>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
arch/sh/include/asm/addrspace.h
arch/sh/include/asm/io.h
arch/sh/mm/fault_32.c
arch/sh/mm/ioremap_32.c