Adding support for MOXA ART SoC. Testing port of linux-2.6.32.60-moxart.
[linux-3.6.7-moxart.git] / arch / arm / mach-tegra / include / mach / io.h
blobfe700f9ce7dc993e4ceabfd10e7f86e5b76bc0b9
1 /*
2 * arch/arm/mach-tegra/include/mach/io.h
4 * Copyright (C) 2010 Google, Inc.
6 * Author:
7 * Colin Cross <ccross@google.com>
8 * Erik Gilling <konkers@google.com>
10 * This software is licensed under the terms of the GNU General Public
11 * License version 2, as published by the Free Software Foundation, and
12 * may be copied, distributed, and modified under those terms.
14 * This program is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 * GNU General Public License for more details.
21 #ifndef __MACH_TEGRA_IO_H
22 #define __MACH_TEGRA_IO_H
24 #define IO_SPACE_LIMIT 0xffff
26 #ifndef __ASSEMBLER__
28 #ifdef CONFIG_TEGRA_PCI
29 extern void __iomem *tegra_pcie_io_base;
31 static inline void __iomem *__io(unsigned long addr)
33 return tegra_pcie_io_base + (addr & IO_SPACE_LIMIT);
35 #else
36 static inline void __iomem *__io(unsigned long addr)
38 return (void __iomem *)addr;
40 #endif
42 #define __io(a) __io(a)
44 #endif
46 #endif