diff options
author | Scott Williams <scwilliams@nvidia.com> | 2011-04-05 17:57:18 -0700 |
---|---|---|
committer | Dan Willemsen <dwillemsen@nvidia.com> | 2011-11-30 21:42:29 -0800 |
commit | 870853c92b488b4f16d97996881d92e73c73b47b (patch) | |
tree | 341f98c6cfffed438f2bde8d58db28d50ca77643 /arch/arm/mach-tegra/io.c | |
parent | cba382f1ac1eda5fcc2c384f20075b9c77e5aa6a (diff) |
ARM: tegra: Don't hardcode physical memory limits
Original-Change-Id: If5ab16be5a4b5bad9f7ee0be753ae22d2d8c5c45
Rebase-Id: Rf492f1b40f0748ed1d2b12f1d98816b8dd10294b
Diffstat (limited to 'arch/arm/mach-tegra/io.c')
-rw-r--r-- | arch/arm/mach-tegra/io.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/arch/arm/mach-tegra/io.c b/arch/arm/mach-tegra/io.c index f1522e16a758..9c1fc5aa1674 100644 --- a/arch/arm/mach-tegra/io.c +++ b/arch/arm/mach-tegra/io.c @@ -26,6 +26,7 @@ #include <linux/mm.h> #include <linux/io.h> +#include <mach/iomap.h> #include <asm/page.h> #include <asm/mach/map.h> @@ -92,8 +93,9 @@ void __iomem *tegra_ioremap(unsigned long p, size_t size, unsigned int type) * __arm_ioremap fails to set the domain of ioremapped memory * correctly, only use it on physical memory. */ - if (v == NULL && p < SZ_1G) - v = __arm_ioremap(p, size, type); + if (v == NULL && p >= TEGRA_DRAM_BASE && + p <= (TEGRA_DRAM_BASE + TEGRA_DRAM_SIZE)) + v = __arm_ioremap(p, size, type); /* * If the physical address was not physical memory or statically |