From patchwork Thu Aug 8 13:48:05 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 2841113 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 8A51CBF546 for ; Thu, 8 Aug 2013 13:50:49 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 640DD20439 for ; Thu, 8 Aug 2013 13:50:48 +0000 (UTC) Received: from casper.infradead.org (casper.infradead.org [85.118.1.10]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id EF2ED2042A for ; Thu, 8 Aug 2013 13:50:46 +0000 (UTC) Received: from merlin.infradead.org ([2001:4978:20e::2]) by casper.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1V7QbW-0002o8-9N; Thu, 08 Aug 2013 13:50:14 +0000 Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1V7QbE-0004Bx-Qb; Thu, 08 Aug 2013 13:49:56 +0000 Received: from mail-pa0-f46.google.com ([209.85.220.46]) by merlin.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1V7Qau-00045B-AK for linux-arm-kernel@lists.infradead.org; Thu, 08 Aug 2013 13:49:42 +0000 Received: by mail-pa0-f46.google.com with SMTP id fa1so3486234pad.19 for ; Thu, 08 Aug 2013 06:49:14 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:in-reply-to:references; bh=LQgA/aycCbMDKH9uMZYExjhsp2Je4Y/HjAyWxfon22c=; b=Gr0WwPipbZ/F/OT7C/SPp5ENheHwf4FuGp3D0D33CPlmaGf3jT6GC3pJfbA0z2+oZv pj4tVUpuDhz3GA6QEO70BFU9lwYtKJiZYpVxefB3Zdb/Vjp2et/6S9rYCo6VrQU3abfp 7orXn81ygr6h9ziIA2hEeR+EJ5/AxNkvPnWywRA3FH7cJlabKqNvoECPC0Aj/VgSGp9Z L5WFHGb8VP53IX9JBJEY0dgbZkwEFQk8suX7sA8E0sC9X7Wc4+aKkSj9ZoU4NxaS3rMd eduKndquPc8TCe02Idg8V6d4AujlDb7e6dXX4184OcN/aLR8w75yNNWsqg2XDKWLwVfD aIDw== X-Gm-Message-State: ALoCoQm2V6tUbqinirCCktq6a7pnyznVWmQur0C3sp9+hM7LoZMkGu+BJ/DQzmxXNwn6OKFluxiZ X-Received: by 10.68.181.163 with SMTP id dx3mr6068109pbc.186.1375969754861; Thu, 08 Aug 2013 06:49:14 -0700 (PDT) Received: from localhost ([122.172.193.46]) by mx.google.com with ESMTPSA id in2sm11118178pbc.37.2013.08.08.06.49.10 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Thu, 08 Aug 2013 06:49:14 -0700 (PDT) From: Viresh Kumar To: rjw@sisk.pl Subject: [PATCH 03/35] cpufreq: s3cx4xx: call cpufreq_frequency_table_get_attr() Date: Thu, 8 Aug 2013 19:18:05 +0530 Message-Id: <4af1a6a5a2d952f0a2ca641109ba185b346dfe5d.1375964117.git.viresh.kumar@linaro.org> X-Mailer: git-send-email 1.7.12.rc2.18.g61b472e In-Reply-To: References: In-Reply-To: References: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20130808_094936_503746_422F9E43 X-CRM114-Status: GOOD ( 13.61 ) X-Spam-Score: -2.6 (--) Cc: linaro-kernel@lists.linaro.org, linux-pm@vger.kernel.org, Viresh Kumar , patches@linaro.org, linux-kernel@vger.kernel.org, cpufreq@vger.kernel.org, Kukjin Kim , linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, 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 This exposes frequency table of driver to cpufreq core and is required for core to guess what the index for a target frequency is, when it calls cpufreq_frequency_table_target(). And so this driver needs to expose it. Cc: Kukjin Kim Signed-off-by: Viresh Kumar --- drivers/cpufreq/s3c24xx-cpufreq.c | 4 +++- drivers/cpufreq/s3c64xx-cpufreq.c | 3 +++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/drivers/cpufreq/s3c24xx-cpufreq.c b/drivers/cpufreq/s3c24xx-cpufreq.c index f169ee5..8843454 100644 --- a/drivers/cpufreq/s3c24xx-cpufreq.c +++ b/drivers/cpufreq/s3c24xx-cpufreq.c @@ -386,8 +386,10 @@ static int s3c_cpufreq_init(struct cpufreq_policy *policy) /* feed the latency information from the cpu driver */ policy->cpuinfo.transition_latency = cpu_cur.info->latency; - if (ftab) + if (ftab) { cpufreq_frequency_table_cpuinfo(policy, ftab); + cpufreq_frequency_table_get_attr(ftab, policy->cpu); + } return 0; } diff --git a/drivers/cpufreq/s3c64xx-cpufreq.c b/drivers/cpufreq/s3c64xx-cpufreq.c index 8a72b0c..9024043 100644 --- a/drivers/cpufreq/s3c64xx-cpufreq.c +++ b/drivers/cpufreq/s3c64xx-cpufreq.c @@ -257,6 +257,9 @@ static int s3c64xx_cpufreq_driver_init(struct cpufreq_policy *policy) ret); regulator_put(vddarm); clk_put(armclk); + } else { + cpufreq_frequency_table_get_attr(s3c64xx_freq_table, + policy->cpu); } return ret;