Commit 6460d7ba authored by Lorenzo Pieralisi's avatar Lorenzo Pieralisi Committed by Will Deacon
Browse files

ARM: cpuidle: Remove overzealous error logging



CPUidle back-end operations are not implemented in some platforms
but this should not be considered an error serious enough to be
logged. Check the arm_cpuidle_init() return value to detect whether
the failure must be reported or not in the kernel log and do
not log it if the platform does not support CPUidle operations.

Signed-off-by: default avatarLorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Acked-by: default avatarDaniel Lezcano <daniel.lezcano@linaro.org>
Reviewed-by: default avatarUlf Hansson <ulf.hansson@linaro.org>
Reviewed-by: default avatarSudeep Holla <sudeep.holla@arm.com>
Cc: Ulf Hansson <ulf.hansson@linaro.org>
Cc: Sudeep Holla <sudeep.holla@arm.com>
Cc: Daniel Lezcano <daniel.lezcano@linaro.org>
Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net>
Signed-off-by: default avatarWill Deacon <will@kernel.org>
parent 63e3ee61
Loading
Loading
Loading
Loading
+9 −3
Original line number Diff line number Diff line
@@ -105,10 +105,16 @@ static int __init arm_idle_init_cpu(int cpu)
	ret = arm_cpuidle_init(cpu);

	/*
	 * Allow the initialization to continue for other CPUs, if the reported
	 * failure is a HW misconfiguration/breakage (-ENXIO).
	 * Allow the initialization to continue for other CPUs, if the
	 * reported failure is a HW misconfiguration/breakage (-ENXIO).
	 *
	 * Some platforms do not support idle operations
	 * (arm_cpuidle_init() returning -EOPNOTSUPP), we should
	 * not flag this case as an error, it is a valid
	 * configuration.
	 */
	if (ret) {
		if (ret != -EOPNOTSUPP)
			pr_err("CPU %d failed to init idle CPU ops\n", cpu);
		ret = ret == -ENXIO ? 0 : ret;
		goto out_kfree_drv;