Message ID | 1443807532.2845.25.camel@linaro.org |
---|---|
State | New |
Headers | show
Return-Path: <patchwork-forward+bncBD42NLN4UAJRBQ4CXOYAKGQECS3EJRQ@linaro.org> X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-la0-f70.google.com (mail-la0-f70.google.com [209.85.215.70]) by patches.linaro.org (Postfix) with ESMTPS id C9782218EF for <linaro@patches.linaro.org>; Fri, 2 Oct 2015 17:39:16 +0000 (UTC) Received: by laer8 with SMTP id r8sf50325953lae.2 for <linaro@patches.linaro.org>; Fri, 02 Oct 2015 10:39:15 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:message-id:subject:from:to:cc:date :content-type:mime-version:content-transfer-encoding:sender :precedence:list-id:x-original-sender :x-original-authentication-results:mailing-list:list-post:list-help :list-archive:list-unsubscribe; bh=s/j0n0aMHAi4V64TBQNaZ/W+chuZQASl78P7GZ3lsfg=; b=MqCfIbkGOiRTBFTkElifmlzUty9KUGnpsOu/cSoRY0NRsU+8zpi1NQl8HbxhS5CJhP mixb5kLxrRoXhu+71e6Lnpzqpqlvx3NYCCNff35qwYgDxWfosxNuzMpQrnFtQAIIwced qKUyOt/qJVbfoCsi8ZzzrpSYuZh1PEboxUbHy8en1JvVexlfjUO+rmbjybi+onWtdo4u MGTN7pnsyf/5FO06PHlEP09c+7EhoROASL5YU60NTuoiyUwu5+UTY+3n5Iv539HKVSIU A9gapDgLEatBCe7mGtt8IslJXXjJX/F5HgULbj12LmExDlLYKeQgMB3Al3AEP2wsz8lw Kvjw== X-Gm-Message-State: ALoCoQmiQICbM+GQlXWg9vcE/2eZBj3IAXrcAz+BfSBdJT8H3Uvbo8cM5l4HiXIenmpNrLLtMJEr X-Received: by 10.112.202.165 with SMTP id kj5mr2831116lbc.5.1443807555644; Fri, 02 Oct 2015 10:39:15 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.25.82.3 with SMTP id g3ls247159lfb.10.gmail; Fri, 02 Oct 2015 10:39:15 -0700 (PDT) X-Received: by 10.112.169.98 with SMTP id ad2mr6071322lbc.2.1443807555485; Fri, 02 Oct 2015 10:39:15 -0700 (PDT) Received: from mail-la0-f46.google.com (mail-la0-f46.google.com. [209.85.215.46]) by mx.google.com with ESMTPS id sg5si5701262lbb.162.2015.10.02.10.39.15 for <patchwork-forward@linaro.org> (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 02 Oct 2015 10:39:15 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.46 as permitted sender) client-ip=209.85.215.46; Received: by lafb9 with SMTP id b9so8392102laf.0 for <patchwork-forward@linaro.org>; Fri, 02 Oct 2015 10:39:15 -0700 (PDT) X-Received: by 10.112.146.104 with SMTP id tb8mr6344515lbb.35.1443807555346; Fri, 02 Oct 2015 10:39:15 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.59.35 with SMTP id w3csp1376625lbq; Fri, 2 Oct 2015 10:39:14 -0700 (PDT) X-Received: by 10.68.65.37 with SMTP id u5mr21712411pbs.154.1443807554029; Fri, 02 Oct 2015 10:39:14 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id jy15si18189484pbb.145.2015.10.02.10.39.05; Fri, 02 Oct 2015 10:39:14 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753869AbbJBRi7 (ORCPT <rfc822;pingbo.wen@linaro.org> + 30 others); Fri, 2 Oct 2015 13:38:59 -0400 Received: from smarthost01d.mail.zen.net.uk ([212.23.1.7]:44005 "EHLO smarthost01d.mail.zen.net.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753471AbbJBRi4 (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Fri, 2 Oct 2015 13:38:56 -0400 Received: from [82.69.122.217] (helo=linaro1) by smarthost01d.mail.zen.net.uk with esmtpsa (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.80) (envelope-from <tixy@linaro.org>) id 1Zi4IH-00020r-56; Fri, 02 Oct 2015 17:38:53 +0000 Message-ID: <1443807532.2845.25.camel@linaro.org> Subject: [PATCH] cpufreq: arm_big_little: fix frequency check when bL switcher is active From: "Jon Medhurst (Tixy)" <tixy@linaro.org> To: Viresh Kumar <viresh.kumar@linaro.org>, Sudeep Holla <sudeep.holla@arm.com>, "Rafael J. Wysocki" <rjw@rjwysocki.net> Cc: linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org, Michael Turquette <mike.turquette@linaro.org> Date: Fri, 02 Oct 2015 18:38:52 +0100 Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.12.9-1+b1 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit X-Originating-smarthost01d-IP: [82.69.122.217] Sender: linux-kernel-owner@vger.kernel.org Precedence: list List-ID: <patchwork-forward.linaro.org> X-Mailing-List: linux-kernel@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: tixy@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.46 as permitted sender) smtp.mailfrom=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: <http://groups.google.com/a/linaro.org/group/patchwork-forward/post>, <mailto:patchwork-forward@linaro.org> List-Help: <http://support.google.com/a/linaro.org/bin/topic.py?topic=25838>, <mailto:patchwork-forward+help@linaro.org> List-Archive: <http://groups.google.com/a/linaro.org/group/patchwork-forward/> List-Unsubscribe: <mailto:googlegroups-manage+836684582541+unsubscribe@googlegroups.com>, <http://groups.google.com/a/linaro.org/group/patchwork-forward/subscribe> |
diff --git a/drivers/cpufreq/arm_big_little.c b/drivers/cpufreq/arm_big_little.c index f1e42f8..71deddb 100644 --- a/drivers/cpufreq/arm_big_little.c +++ b/drivers/cpufreq/arm_big_little.c @@ -196,7 +196,7 @@ bL_cpufreq_set_rate(u32 cpu, u32 old_cluster, u32 new_cluster, u32 rate) * be reading only the cached value anyway. This needs to be removed * once clk core is fixed. */ - if (bL_cpufreq_get_rate(cpu) != new_rate) + if (!bLs && bL_cpufreq_get_rate(cpu) != new_rate) return -EIO; return 0; }
The check for correct frequency being set in bL_cpufreq_set_rate is broken when the big.LITTLE switcher is active, for two reasons. 1. The 'new_rate' variable gets overwritten before the test by the code calculating the frequency of the old cluster. 2. The frequency returned by bL_cpufreq_get_rate will be the virtual frequency, not the actual one the intended version of new_rate contains. This means the function always returns an error causing an endless stream of: "cpufreq: __target_index: Failed to change cpu frequency: -5" As the comment for the test indicates that it is temporary and limited lets not bother fixing it to work when the bL switcher is active and instead just bypass the test in that case. Fixes: 0a95e630b49a ("cpufreq: arm_big_little: check if the frequency is set correctly") Signed-off-by: Jon Medhurst <tixy@linaro.org> --- drivers/cpufreq/arm_big_little.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)