diff options
Diffstat (limited to 'arch/arm/mach-tegra')
| -rw-r--r-- | arch/arm/mach-tegra/pm.c | 1 | ||||
| -rw-r--r-- | arch/arm/mach-tegra/tegra.c | 10 |
2 files changed, 11 insertions, 0 deletions
diff --git a/arch/arm/mach-tegra/pm.c b/arch/arm/mach-tegra/pm.c index 4ae0286b468d..f55b05a29b55 100644 --- a/arch/arm/mach-tegra/pm.c +++ b/arch/arm/mach-tegra/pm.c | |||
| @@ -24,6 +24,7 @@ | |||
| 24 | #include <linux/cpu_pm.h> | 24 | #include <linux/cpu_pm.h> |
| 25 | #include <linux/suspend.h> | 25 | #include <linux/suspend.h> |
| 26 | #include <linux/err.h> | 26 | #include <linux/err.h> |
| 27 | #include <linux/slab.h> | ||
| 27 | #include <linux/clk/tegra.h> | 28 | #include <linux/clk/tegra.h> |
| 28 | 29 | ||
| 29 | #include <asm/smp_plat.h> | 30 | #include <asm/smp_plat.h> |
diff --git a/arch/arm/mach-tegra/tegra.c b/arch/arm/mach-tegra/tegra.c index 303a285d80fd..6191603379e1 100644 --- a/arch/arm/mach-tegra/tegra.c +++ b/arch/arm/mach-tegra/tegra.c | |||
| @@ -73,10 +73,20 @@ u32 tegra_uart_config[3] = { | |||
| 73 | static void __init tegra_init_cache(void) | 73 | static void __init tegra_init_cache(void) |
| 74 | { | 74 | { |
| 75 | #ifdef CONFIG_CACHE_L2X0 | 75 | #ifdef CONFIG_CACHE_L2X0 |
| 76 | static const struct of_device_id pl310_ids[] __initconst = { | ||
| 77 | { .compatible = "arm,pl310-cache", }, | ||
| 78 | {} | ||
| 79 | }; | ||
| 80 | |||
| 81 | struct device_node *np; | ||
| 76 | int ret; | 82 | int ret; |
| 77 | void __iomem *p = IO_ADDRESS(TEGRA_ARM_PERIF_BASE) + 0x3000; | 83 | void __iomem *p = IO_ADDRESS(TEGRA_ARM_PERIF_BASE) + 0x3000; |
| 78 | u32 aux_ctrl, cache_type; | 84 | u32 aux_ctrl, cache_type; |
| 79 | 85 | ||
| 86 | np = of_find_matching_node(NULL, pl310_ids); | ||
| 87 | if (!np) | ||
| 88 | return; | ||
| 89 | |||
| 80 | cache_type = readl(p + L2X0_CACHE_TYPE); | 90 | cache_type = readl(p + L2X0_CACHE_TYPE); |
| 81 | aux_ctrl = (cache_type & 0x700) << (17-8); | 91 | aux_ctrl = (cache_type & 0x700) << (17-8); |
| 82 | aux_ctrl |= 0x7C400001; | 92 | aux_ctrl |= 0x7C400001; |
