From patchwork Mon Sep 30 20:44:32 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Aaro Koskinen X-Patchwork-Id: 2966871 Return-Path: X-Original-To: patchwork-linux-pm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 2C8359F3C4 for ; Mon, 30 Sep 2013 20:45:29 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 6B14120161 for ; Mon, 30 Sep 2013 20:45:28 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 6888F2022F for ; Mon, 30 Sep 2013 20:45:27 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932070Ab3I3UpX (ORCPT ); Mon, 30 Sep 2013 16:45:23 -0400 Received: from filtteri6.pp.htv.fi ([213.243.153.189]:55143 "EHLO filtteri6.pp.htv.fi" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932094Ab3I3UpT (ORCPT ); Mon, 30 Sep 2013 16:45:19 -0400 Received: from localhost (localhost [127.0.0.1]) by filtteri6.pp.htv.fi (Postfix) with ESMTP id B31AD56F8FA; Mon, 30 Sep 2013 23:45:17 +0300 (EEST) X-Virus-Scanned: Debian amavisd-new at pp.htv.fi Received: from smtp4.welho.com ([213.243.153.38]) by localhost (filtteri6.pp.htv.fi [213.243.153.189]) (amavisd-new, port 10024) with ESMTP id ZOxYr9bbV5AL; Mon, 30 Sep 2013 23:45:12 +0300 (EEST) Received: from blackmetal.pp.htv.fi (cs181064211.pp.htv.fi [82.181.64.211]) by smtp4.welho.com (Postfix) with ESMTP id BD0E05BC019; Mon, 30 Sep 2013 23:45:12 +0300 (EEST) From: Aaro Koskinen To: "Rafael J. Wysocki" , Viresh Kumar , Benjamin Herrenschmidt , linux-pm@vger.kernel.org, linuxppc-dev@lists.ozlabs.org Cc: Aaro Koskinen Subject: [PATCH v2 RESEND 2/3] cpufreq: pmac64: provide cpufreq transition latency for older G5 models Date: Mon, 30 Sep 2013 23:44:32 +0300 Message-Id: <1380573873-14448-3-git-send-email-aaro.koskinen@iki.fi> X-Mailer: git-send-email 1.8.4.rc3 In-Reply-To: <1380573873-14448-1-git-send-email-aaro.koskinen@iki.fi> References: <1380573873-14448-1-git-send-email-aaro.koskinen@iki.fi> Sender: linux-pm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pm@vger.kernel.org X-Spam-Status: No, score=-7.5 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Currently cpufreq ondemand governor cannot used on older G5 models, because the transition latency is set to CPUFREQ_ETERNAL. Provide a value based on a measurement on Xserve G5, which happens to be also the highest allowed latency. Signed-off-by: Aaro Koskinen --- drivers/cpufreq/pmac64-cpufreq.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/cpufreq/pmac64-cpufreq.c b/drivers/cpufreq/pmac64-cpufreq.c index 46ae223..0196d60 100644 --- a/drivers/cpufreq/pmac64-cpufreq.c +++ b/drivers/cpufreq/pmac64-cpufreq.c @@ -647,8 +647,10 @@ static int __init g5_pm72_cpufreq_init(struct device_node *cpunode) g5_cpu_freqs[0].frequency = max_freq; g5_cpu_freqs[1].frequency = min_freq; + /* Based on a measurement on Xserve G5, rounded up. */ + transition_latency = 10 * NSEC_PER_MSEC; + /* Set callbacks */ - transition_latency = CPUFREQ_ETERNAL; g5_switch_volt = g5_pfunc_switch_volt; g5_switch_freq = g5_pfunc_switch_freq; g5_query_freq = g5_pfunc_query_freq;