From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753171AbdEPSxB (ORCPT ); Tue, 16 May 2017 14:53:01 -0400 Received: from Galois.linutronix.de ([146.0.238.70]:41261 "EHLO Galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752946AbdEPSwr (ORCPT ); Tue, 16 May 2017 14:52:47 -0400 Message-Id: <20170516184735.620023128@linutronix.de> User-Agent: quilt/0.63-1 Date: Tue, 16 May 2017 20:42:40 +0200 From: Thomas Gleixner To: LKML Cc: Peter Zijlstra , Ingo Molnar , Steven Rostedt , Mark Rutland , Greg Kroah-Hartman , Viresh Kumar , "Rafael J. Wysocki" , linuxppc-dev@lists.ozlabs.org Subject: [patch V2 09/17] cpufreq/pasemi: Adjust system_state check References: <20170516184231.564888231@linutronix.de> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-15 Content-Disposition: inline; filename=cpufreq-pasemi--Adjust-system_state-check.patch Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org To enable smp_processor_id() and might_sleep() debug checks earlier, it's required to add system states between SYSTEM_BOOTING and SYSTEM_RUNNING. Adjust the system_state check in pas_cpufreq_cpu_exit() to handle the extra states. Signed-off-by: Thomas Gleixner Acked-by: Viresh Kumar Cc: "Rafael J. Wysocki" Cc: linuxppc-dev@lists.ozlabs.org --- drivers/cpufreq/pasemi-cpufreq.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/cpufreq/pasemi-cpufreq.c +++ b/drivers/cpufreq/pasemi-cpufreq.c @@ -226,7 +226,7 @@ static int pas_cpufreq_cpu_exit(struct c * We don't support CPU hotplug. Don't unmap after the system * has already made it to a running state. */ - if (system_state != SYSTEM_BOOTING) + if (system_state >= SYSTEM_RUNNING) return 0; if (sdcasr_mapbase)