diff --git a/arch/arm/configs/odroidxu4_defconfig b/arch/arm/configs/odroidxu4_defconfig index 7f6cf5576bf5a7..97b775f0a02e4b 100644 --- a/arch/arm/configs/odroidxu4_defconfig +++ b/arch/arm/configs/odroidxu4_defconfig @@ -720,7 +720,7 @@ CONFIG_CPU_IDLE_GOV_MENU=y # CONFIG_ARM_CPUIDLE is not set # CONFIG_ARM_BIG_LITTLE_CPUIDLE is not set CONFIG_ARM_EXYNOS_CPUIDLE=y -CONFIG_ARCH_NEEDS_CPU_IDLE_COUPLED=y +# CONFIG_ARCH_NEEDS_CPU_IDLE_COUPLED is not set # # Floating point emulation diff --git a/arch/arm/mach-exynos/exynos.c b/arch/arm/mach-exynos/exynos.c index 6197dbf9f48b99..c1e6d332578f9d 100644 --- a/arch/arm/mach-exynos/exynos.c +++ b/arch/arm/mach-exynos/exynos.c @@ -199,7 +199,10 @@ static void __init exynos_dt_machine_init(void) (of_machine_is_compatible("samsung,exynos4412") && of_machine_is_compatible("samsung,trats2")) || of_machine_is_compatible("samsung,exynos3250") || - of_machine_is_compatible("samsung,exynos5250")) + of_machine_is_compatible("samsung,exynos5250") || + of_machine_is_compatible("hardkernel,odroid-xu3") || + of_machine_is_compatible("hardkernel,odroid-xu3-lite") || + of_machine_is_compatible("hardkernel,odroid-xu4")) platform_device_register(&exynos_cpuidle); } diff --git a/drivers/cpuidle/cpuidle-exynos.c b/drivers/cpuidle/cpuidle-exynos.c index 00cd129b10a461..b59cc287119991 100644 --- a/drivers/cpuidle/cpuidle-exynos.c +++ b/drivers/cpuidle/cpuidle-exynos.c @@ -76,6 +76,21 @@ static int exynos_enter_lowpower(struct cpuidle_device *dev, return new_index; } +static struct cpuidle_driver exynos_idle_driver_5422 = { + .name = "exynos_idle", + .owner = THIS_MODULE, + .states = { + [0] = { + .enter = arm_cpuidle_simple_enter, + .exit_latency = 1, + .target_residency = 500, + .name = "WFI", + .desc = "ARM clock gating", + }, + }, + .state_count = 1, +}; + static struct cpuidle_driver exynos_idle_driver = { .name = "exynos_idle", .owner = THIS_MODULE, @@ -125,7 +140,14 @@ static int exynos_cpuidle_probe(struct platform_device *pdev) } else { exynos_enter_aftr = (void *)(pdev->dev.platform_data); - ret = cpuidle_register(&exynos_idle_driver, NULL); + if (of_machine_is_compatible("hardkernel,odroid-xu3") || + of_machine_is_compatible("hardkernel,odroid-xu3-lite") || + of_machine_is_compatible("hardkernel,odroid-xu4")) { + + ret = cpuidle_register(&exynos_idle_driver_5422, NULL); + } else { + ret = cpuidle_register(&exynos_idle_driver, NULL); + } } if (ret) {