diff options
| -rw-r--r-- | arch/arm/boot/dts/exynos4.dtsi | 2 | ||||
| -rw-r--r-- | arch/arm/mach-exynos/hotplug.c | 8 | ||||
| -rw-r--r-- | arch/arm/mach-exynos/mcpm-exynos.c | 11 | ||||
| -rw-r--r-- | arch/arm/mach-exynos/pm.c | 15 | ||||
| -rw-r--r-- | drivers/clocksource/exynos_mct.c | 9 |
5 files changed, 20 insertions, 25 deletions
diff --git a/arch/arm/boot/dts/exynos4.dtsi b/arch/arm/boot/dts/exynos4.dtsi index b8ece4be41ca..fbaf426d2daa 100644 --- a/arch/arm/boot/dts/exynos4.dtsi +++ b/arch/arm/boot/dts/exynos4.dtsi | |||
| @@ -113,7 +113,7 @@ | |||
| 113 | compatible = "arm,cortex-a9-gic"; | 113 | compatible = "arm,cortex-a9-gic"; |
| 114 | #interrupt-cells = <3>; | 114 | #interrupt-cells = <3>; |
| 115 | interrupt-controller; | 115 | interrupt-controller; |
| 116 | reg = <0x10490000 0x1000>, <0x10480000 0x100>; | 116 | reg = <0x10490000 0x10000>, <0x10480000 0x10000>; |
| 117 | }; | 117 | }; |
| 118 | 118 | ||
| 119 | combiner: interrupt-controller@10440000 { | 119 | combiner: interrupt-controller@10440000 { |
diff --git a/arch/arm/mach-exynos/hotplug.c b/arch/arm/mach-exynos/hotplug.c index 69fa48397394..8a134d019cb3 100644 --- a/arch/arm/mach-exynos/hotplug.c +++ b/arch/arm/mach-exynos/hotplug.c | |||
| @@ -46,13 +46,7 @@ static inline void platform_do_lowpower(unsigned int cpu, int *spurious) | |||
| 46 | if (cpu == 1) | 46 | if (cpu == 1) |
| 47 | exynos_cpu_power_down(cpu); | 47 | exynos_cpu_power_down(cpu); |
| 48 | 48 | ||
| 49 | /* | 49 | wfi(); |
| 50 | * here's the WFI | ||
| 51 | */ | ||
| 52 | asm(".word 0xe320f003\n" | ||
| 53 | : | ||
| 54 | : | ||
| 55 | : "memory", "cc"); | ||
| 56 | 50 | ||
| 57 | if (pen_release == cpu_logical_map(cpu)) { | 51 | if (pen_release == cpu_logical_map(cpu)) { |
| 58 | /* | 52 | /* |
diff --git a/arch/arm/mach-exynos/mcpm-exynos.c b/arch/arm/mach-exynos/mcpm-exynos.c index 0498d0b887ef..ace0ed617476 100644 --- a/arch/arm/mach-exynos/mcpm-exynos.c +++ b/arch/arm/mach-exynos/mcpm-exynos.c | |||
| @@ -25,7 +25,6 @@ | |||
| 25 | 25 | ||
| 26 | #define EXYNOS5420_CPUS_PER_CLUSTER 4 | 26 | #define EXYNOS5420_CPUS_PER_CLUSTER 4 |
| 27 | #define EXYNOS5420_NR_CLUSTERS 2 | 27 | #define EXYNOS5420_NR_CLUSTERS 2 |
| 28 | #define MCPM_BOOT_ADDR_OFFSET 0x1c | ||
| 29 | 28 | ||
| 30 | /* | 29 | /* |
| 31 | * The common v7_exit_coherency_flush API could not be used because of the | 30 | * The common v7_exit_coherency_flush API could not be used because of the |
| @@ -343,11 +342,13 @@ static int __init exynos_mcpm_init(void) | |||
| 343 | pr_info("Exynos MCPM support installed\n"); | 342 | pr_info("Exynos MCPM support installed\n"); |
| 344 | 343 | ||
| 345 | /* | 344 | /* |
| 346 | * Future entries into the kernel can now go | 345 | * U-Boot SPL is hardcoded to jump to the start of ns_sram_base_addr |
| 347 | * through the cluster entry vectors. | 346 | * as part of secondary_cpu_start(). Let's redirect it to the |
| 347 | * mcpm_entry_point(). | ||
| 348 | */ | 348 | */ |
| 349 | __raw_writel(virt_to_phys(mcpm_entry_point), | 349 | __raw_writel(0xe59f0000, ns_sram_base_addr); /* ldr r0, [pc, #0] */ |
| 350 | ns_sram_base_addr + MCPM_BOOT_ADDR_OFFSET); | 350 | __raw_writel(0xe12fff10, ns_sram_base_addr + 4); /* bx r0 */ |
| 351 | __raw_writel(virt_to_phys(mcpm_entry_point), ns_sram_base_addr + 8); | ||
| 351 | 352 | ||
| 352 | iounmap(ns_sram_base_addr); | 353 | iounmap(ns_sram_base_addr); |
| 353 | 354 | ||
diff --git a/arch/arm/mach-exynos/pm.c b/arch/arm/mach-exynos/pm.c index 87c0d34c7fba..202ca73e49c4 100644 --- a/arch/arm/mach-exynos/pm.c +++ b/arch/arm/mach-exynos/pm.c | |||
| @@ -300,7 +300,7 @@ static int exynos_pm_suspend(void) | |||
| 300 | tmp = (S5P_USE_STANDBY_WFI0 | S5P_USE_STANDBY_WFE0); | 300 | tmp = (S5P_USE_STANDBY_WFI0 | S5P_USE_STANDBY_WFE0); |
| 301 | __raw_writel(tmp, S5P_CENTRAL_SEQ_OPTION); | 301 | __raw_writel(tmp, S5P_CENTRAL_SEQ_OPTION); |
| 302 | 302 | ||
| 303 | if (!soc_is_exynos5250()) | 303 | if (read_cpuid_part_number() == ARM_CPU_PART_CORTEX_A9) |
| 304 | exynos_cpu_save_register(); | 304 | exynos_cpu_save_register(); |
| 305 | 305 | ||
| 306 | return 0; | 306 | return 0; |
| @@ -334,7 +334,7 @@ static void exynos_pm_resume(void) | |||
| 334 | if (exynos_pm_central_resume()) | 334 | if (exynos_pm_central_resume()) |
| 335 | goto early_wakeup; | 335 | goto early_wakeup; |
| 336 | 336 | ||
| 337 | if (!soc_is_exynos5250()) | 337 | if (read_cpuid_part_number() == ARM_CPU_PART_CORTEX_A9) |
| 338 | exynos_cpu_restore_register(); | 338 | exynos_cpu_restore_register(); |
| 339 | 339 | ||
| 340 | /* For release retention */ | 340 | /* For release retention */ |
| @@ -353,7 +353,7 @@ static void exynos_pm_resume(void) | |||
| 353 | 353 | ||
| 354 | s3c_pm_do_restore_core(exynos_core_save, ARRAY_SIZE(exynos_core_save)); | 354 | s3c_pm_do_restore_core(exynos_core_save, ARRAY_SIZE(exynos_core_save)); |
| 355 | 355 | ||
| 356 | if (!soc_is_exynos5250()) | 356 | if (read_cpuid_part_number() == ARM_CPU_PART_CORTEX_A9) |
| 357 | scu_enable(S5P_VA_SCU); | 357 | scu_enable(S5P_VA_SCU); |
| 358 | 358 | ||
| 359 | early_wakeup: | 359 | early_wakeup: |
| @@ -440,15 +440,18 @@ static int exynos_cpu_pm_notifier(struct notifier_block *self, | |||
| 440 | case CPU_PM_ENTER: | 440 | case CPU_PM_ENTER: |
| 441 | if (cpu == 0) { | 441 | if (cpu == 0) { |
| 442 | exynos_pm_central_suspend(); | 442 | exynos_pm_central_suspend(); |
| 443 | exynos_cpu_save_register(); | 443 | if (read_cpuid_part_number() == ARM_CPU_PART_CORTEX_A9) |
| 444 | exynos_cpu_save_register(); | ||
| 444 | } | 445 | } |
| 445 | break; | 446 | break; |
| 446 | 447 | ||
| 447 | case CPU_PM_EXIT: | 448 | case CPU_PM_EXIT: |
| 448 | if (cpu == 0) { | 449 | if (cpu == 0) { |
| 449 | if (!soc_is_exynos5250()) | 450 | if (read_cpuid_part_number() == |
| 451 | ARM_CPU_PART_CORTEX_A9) { | ||
| 450 | scu_enable(S5P_VA_SCU); | 452 | scu_enable(S5P_VA_SCU); |
| 451 | exynos_cpu_restore_register(); | 453 | exynos_cpu_restore_register(); |
| 454 | } | ||
| 452 | exynos_pm_central_resume(); | 455 | exynos_pm_central_resume(); |
| 453 | } | 456 | } |
| 454 | break; | 457 | break; |
diff --git a/drivers/clocksource/exynos_mct.c b/drivers/clocksource/exynos_mct.c index 8d6420013a04..f71d55f5e6e5 100644 --- a/drivers/clocksource/exynos_mct.c +++ b/drivers/clocksource/exynos_mct.c | |||
| @@ -153,13 +153,10 @@ static void exynos4_mct_write(unsigned int value, unsigned long offset) | |||
| 153 | } | 153 | } |
| 154 | 154 | ||
| 155 | /* Clocksource handling */ | 155 | /* Clocksource handling */ |
| 156 | static void exynos4_mct_frc_start(u32 hi, u32 lo) | 156 | static void exynos4_mct_frc_start(void) |
| 157 | { | 157 | { |
| 158 | u32 reg; | 158 | u32 reg; |
| 159 | 159 | ||
| 160 | exynos4_mct_write(lo, EXYNOS4_MCT_G_CNT_L); | ||
| 161 | exynos4_mct_write(hi, EXYNOS4_MCT_G_CNT_U); | ||
| 162 | |||
| 163 | reg = __raw_readl(reg_base + EXYNOS4_MCT_G_TCON); | 160 | reg = __raw_readl(reg_base + EXYNOS4_MCT_G_TCON); |
| 164 | reg |= MCT_G_TCON_START; | 161 | reg |= MCT_G_TCON_START; |
| 165 | exynos4_mct_write(reg, EXYNOS4_MCT_G_TCON); | 162 | exynos4_mct_write(reg, EXYNOS4_MCT_G_TCON); |
| @@ -181,7 +178,7 @@ static cycle_t exynos4_frc_read(struct clocksource *cs) | |||
| 181 | 178 | ||
| 182 | static void exynos4_frc_resume(struct clocksource *cs) | 179 | static void exynos4_frc_resume(struct clocksource *cs) |
| 183 | { | 180 | { |
| 184 | exynos4_mct_frc_start(0, 0); | 181 | exynos4_mct_frc_start(); |
| 185 | } | 182 | } |
| 186 | 183 | ||
| 187 | struct clocksource mct_frc = { | 184 | struct clocksource mct_frc = { |
| @@ -200,7 +197,7 @@ static u64 notrace exynos4_read_sched_clock(void) | |||
| 200 | 197 | ||
| 201 | static void __init exynos4_clocksource_init(void) | 198 | static void __init exynos4_clocksource_init(void) |
| 202 | { | 199 | { |
| 203 | exynos4_mct_frc_start(0, 0); | 200 | exynos4_mct_frc_start(); |
| 204 | 201 | ||
| 205 | if (clocksource_register_hz(&mct_frc, clk_rate)) | 202 | if (clocksource_register_hz(&mct_frc, clk_rate)) |
| 206 | panic("%s: can't register clocksource\n", mct_frc.name); | 203 | panic("%s: can't register clocksource\n", mct_frc.name); |
