From patchwork Tue May 24 04:56:50 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 68435 Delivered-To: patch@linaro.org Received: by 10.140.92.199 with SMTP id b65csp432379qge; Mon, 23 May 2016 21:56:59 -0700 (PDT) X-Received: by 10.98.109.198 with SMTP id i189mr3734237pfc.106.1464065819317; Mon, 23 May 2016 21:56:59 -0700 (PDT) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m68si4673538pfi.168.2016.05.23.21.56.58; Mon, 23 May 2016 21:56:59 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-pm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org; spf=pass (google.com: best guess record for domain of linux-pm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-pm-owner@vger.kernel.org; dmarc=fail (p=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753279AbcEXE45 (ORCPT + 14 others); Tue, 24 May 2016 00:56:57 -0400 Received: from mail-pf0-f170.google.com ([209.85.192.170]:35019 "EHLO mail-pf0-f170.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751154AbcEXE45 (ORCPT ); Tue, 24 May 2016 00:56:57 -0400 Received: by mail-pf0-f170.google.com with SMTP id g64so2889615pfb.2 for ; Mon, 23 May 2016 21:56:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=WgyYx/xr/se7JnooIxm9YdEcUhzgIShQ22sWma0Yd9g=; b=at89jBJXcQ7FT0aZrdMl4A+XjL2TWJ5U0i6eTqW2dEm3fd8xdIl0ZN8zpINMeDVTwA r+kcqmGlMkivZSATOcM0tPlh8vhUIANBglZ1s25PHLzRc7tEbDmnthQBZtm6Mo5u8zRj uwSoy//ExLYqssawrFleCJX89LSM7SIm04rj8= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=WgyYx/xr/se7JnooIxm9YdEcUhzgIShQ22sWma0Yd9g=; b=ZogsCo1IhJJgeIbejxitfLBOy4U5e3G2WHDaiyVtuSw1zhFcThrUQyddsbzvDQldPe q19ww/V1heIRGfNsHVehSk+3Ii81b4dqumkf/9AsapQ7Tmr8knb60O4Cbaoh5vuMHXvT HaggS+CF/zNEyzvn9lq/6DuPF+CV+FML/ZDDEFR194w2VpO3E/1WIrYHxwLYi3pqG77U NMjJvSXBD8Wa4bsbjtXfS9NbtDdk9ZOyL75GuxjmRL3qRbGrM7vGl4gFANFxccOtS9zX vFX+hgK1w+u02CjfGEak9P1YbwlaSLrb5OcdMOY+9rxEBc7z36i1LshS3+T16QLc+a4Z Yqbw== X-Gm-Message-State: ALyK8tIYegGzcFXuLoY02VouGBMYVtKK6ZeILONv+8uWDAHcT6Se/UEA1R37gY0MyvPH6Xh5 X-Received: by 10.98.95.4 with SMTP id t4mr3738122pfb.162.1464065816505; Mon, 23 May 2016 21:56:56 -0700 (PDT) Received: from localhost ([122.172.42.124]) by smtp.gmail.com with ESMTPSA id k71sm1505641pfb.50.2016.05.23.21.56.55 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 23 May 2016 21:56:55 -0700 (PDT) From: Viresh Kumar To: Rafael Wysocki , Viresh Kumar Cc: linaro-kernel@lists.linaro.org, linux-pm@vger.kernel.org Subject: [PATCH] cpufreq: Send START policy notifier after sending CREATE Date: Tue, 24 May 2016 10:26:50 +0530 Message-Id: <5ad28985448ea96b9e952b5d722cfc4f70ab9549.1464065802.git.viresh.kumar@linaro.org> X-Mailer: git-send-email 2.7.1.410.g6faf27b Sender: linux-pm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pm@vger.kernel.org The sequence got a bit wrong as we are sending CPUFREQ_START notifier even before we have sent CPUFREQ_CREATE_POLICY. Fix it. Signed-off-by: Viresh Kumar --- drivers/cpufreq/cpufreq.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) -- 2.7.1.410.g6faf27b -- To unsubscribe from this list: send the line "unsubscribe linux-pm" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/cpufreq/cpufreq.c b/drivers/cpufreq/cpufreq.c index 36bc11a106aa..c3f950f0e5f0 100644 --- a/drivers/cpufreq/cpufreq.c +++ b/drivers/cpufreq/cpufreq.c @@ -1265,9 +1265,6 @@ static int cpufreq_online(unsigned int cpu) } } - blocking_notifier_call_chain(&cpufreq_policy_notifier_list, - CPUFREQ_START, policy); - if (new_policy) { ret = cpufreq_add_dev_interface(policy); if (ret) @@ -1280,6 +1277,9 @@ static int cpufreq_online(unsigned int cpu) write_unlock_irqrestore(&cpufreq_driver_lock, flags); } + blocking_notifier_call_chain(&cpufreq_policy_notifier_list, + CPUFREQ_START, policy); + ret = cpufreq_init_policy(policy); if (ret) { pr_err("%s: Failed to initialize policy for cpu: %d (%d)\n",