spi-topcliff-pch: add recovery processing in case wait-event timeout
[zen-stable.git] / arch / arm / plat-mxc / include / mach / io.h
blob338300b18b00c0af6002b6fd7e91b62056f70c55
1 /*
2 * Copyright 2004-2007 Freescale Semiconductor, Inc. All Rights Reserved.
3 */
5 /*
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License version 2 as
8 * published by the Free Software Foundation.
9 */
11 #ifndef __ASM_ARCH_MXC_IO_H__
12 #define __ASM_ARCH_MXC_IO_H__
14 /* Allow IO space to be anywhere in the memory */
15 #define IO_SPACE_LIMIT 0xffffffff
17 #define __arch_ioremap __imx_ioremap
18 #define __arch_iounmap __iounmap
20 #define addr_in_module(addr, mod) \
21 ((unsigned long)(addr) - mod ## _BASE_ADDR < mod ## _SIZE)
23 extern void __iomem *(*imx_ioremap)(unsigned long, size_t, unsigned int);
25 static inline void __iomem *
26 __imx_ioremap(unsigned long phys_addr, size_t size, unsigned int mtype)
28 if (imx_ioremap != NULL)
29 return imx_ioremap(phys_addr, size, mtype);
30 else
31 return __arm_ioremap(phys_addr, size, mtype);
34 /* io address mapping macro */
35 #define __io(a) __typesafe_io(a)
37 #define __mem_pci(a) (a)
39 #endif