From patchwork Fri Sep 13 12:59:40 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 20088 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-vc0-f199.google.com (mail-vc0-f199.google.com [209.85.220.199]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 25967202E6 for ; Fri, 13 Sep 2013 13:07:07 +0000 (UTC) Received: by mail-vc0-f199.google.com with SMTP id gf11sf1191343vcb.6 for ; Fri, 13 Sep 2013 06:07:06 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:in-reply-to:references :x-original-sender:x-original-authentication-results:precedence :mailing-list:list-id:list-post:list-help:list-archive :list-unsubscribe; bh=wVkf1ZhPYvP8s8RODelQfxjLNrHsQqXeFrg15Auzj54=; b=ACTXH4JXnQh5rqlqsukLsw76iWZHrBo3VLxd6W2DioYHISaf7xf0YESgJXnt28qOcy TlED38K6wBTWoMfM/lJvPeS9Qdssd6NGrJqSecB+CHhiqClVez2fQaYUbWvfL9QdHczY QWZecULb0qnTrfh7aobXf30cllsQyjjG845i8GM35B//gSOpEtWJ+gTL7oAvaiuiZ3iR vnKjWdQjOnUTJp4WYC9NDPRdMCASv6IlZtedNNOpI59Fz+L+PhkXjY+SAqoTnulnaX9d 7Lw1JFH6EapfVM09lCvGpuibnBRcSp0COlkAdK0YluSkyta8wKWwjDhZT/ZJl2MVihuu 6B4Q== X-Gm-Message-State: ALoCoQkoLsPZoH5w2cVDIo2Y9v2QPvBqTfYMdgbDq6174v7GZGF57wPioM3kLVH0IZpAgMMraEk0 X-Received: by 10.236.6.134 with SMTP id 6mr5276982yhn.7.1379077626888; Fri, 13 Sep 2013 06:07:06 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.15.198 with SMTP id z6ls1141187qec.63.gmail; Fri, 13 Sep 2013 06:07:06 -0700 (PDT) X-Received: by 10.220.164.70 with SMTP id d6mr11763925vcy.19.1379077626665; Fri, 13 Sep 2013 06:07:06 -0700 (PDT) Received: from mail-vc0-f179.google.com (mail-vc0-f179.google.com [209.85.220.179]) by mx.google.com with ESMTPS id jc7si3093285vdb.65.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 13 Sep 2013 06:07:06 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.220.179 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.220.179; Received: by mail-vc0-f179.google.com with SMTP id ht10so871544vcb.38 for ; Fri, 13 Sep 2013 06:07:06 -0700 (PDT) X-Received: by 10.220.1.203 with SMTP id 11mr11898387vcg.15.1379077626582; Fri, 13 Sep 2013 06:07:06 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.220.174.196 with SMTP id u4csp79636vcz; Fri, 13 Sep 2013 06:07:06 -0700 (PDT) X-Received: by 10.68.196.2 with SMTP id ii2mr13517042pbc.86.1379077625661; Fri, 13 Sep 2013 06:07:05 -0700 (PDT) Received: from mail-pa0-f54.google.com (mail-pa0-f54.google.com [209.85.220.54]) by mx.google.com with ESMTPS id mj9si11192160pab.103.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 13 Sep 2013 06:07:05 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.220.54 is neither permitted nor denied by best guess record for domain of viresh.kumar@linaro.org) client-ip=209.85.220.54; Received: by mail-pa0-f54.google.com with SMTP id kx10so2526162pab.27 for ; Fri, 13 Sep 2013 06:07:05 -0700 (PDT) X-Received: by 10.66.234.131 with SMTP id ue3mr14934610pac.35.1379077625230; Fri, 13 Sep 2013 06:07:05 -0700 (PDT) Received: from localhost ([122.167.78.148]) by mx.google.com with ESMTPSA id ye1sm17973490pab.19.1969.12.31.16.00.00 (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Fri, 13 Sep 2013 06:07:04 -0700 (PDT) From: Viresh Kumar To: rjw@sisk.pl Cc: linaro-kernel@lists.linaro.org, patches@linaro.org, cpufreq@vger.kernel.org, linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Viresh Kumar Subject: [PATCH 034/228] cpufreq: ppc: use cpufreq_table_validate_and_show() Date: Fri, 13 Sep 2013 18:29:40 +0530 Message-Id: X-Mailer: git-send-email 1.7.12.rc2.18.g61b472e In-Reply-To: References: In-Reply-To: References: X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: viresh.kumar@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.220.179 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Precedence: list Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Lets use cpufreq_table_validate_and_show() instead of calling cpufreq_frequency_table_cpuinfo() and cpufreq_frequency_table_get_attr(). Signed-off-by: Viresh Kumar --- drivers/cpufreq/ppc-corenet-cpufreq.c | 3 +-- drivers/cpufreq/ppc_cbe_cpufreq.c | 4 +--- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/drivers/cpufreq/ppc-corenet-cpufreq.c b/drivers/cpufreq/ppc-corenet-cpufreq.c index 60e81d5..5716b44 100644 --- a/drivers/cpufreq/ppc-corenet-cpufreq.c +++ b/drivers/cpufreq/ppc-corenet-cpufreq.c @@ -202,7 +202,7 @@ static int corenet_cpufreq_cpu_init(struct cpufreq_policy *policy) table[i].frequency = CPUFREQ_TABLE_END; /* set the min and max frequency properly */ - ret = cpufreq_frequency_table_cpuinfo(policy, table); + ret = cpufreq_table_validate_and_show(policy, table); if (ret) { pr_err("invalid frequency table: %d\n", ret); goto err_nomem1; @@ -219,7 +219,6 @@ static int corenet_cpufreq_cpu_init(struct cpufreq_policy *policy) policy->cpuinfo.transition_latency = CPUFREQ_ETERNAL; policy->cur = corenet_cpufreq_get_speed(policy->cpu); - cpufreq_frequency_table_get_attr(table, cpu); of_node_put(np); return 0; diff --git a/drivers/cpufreq/ppc_cbe_cpufreq.c b/drivers/cpufreq/ppc_cbe_cpufreq.c index 2e448f0..6c5be63 100644 --- a/drivers/cpufreq/ppc_cbe_cpufreq.c +++ b/drivers/cpufreq/ppc_cbe_cpufreq.c @@ -123,11 +123,9 @@ static int cbe_cpufreq_cpu_init(struct cpufreq_policy *policy) cpumask_copy(policy->cpus, cpu_sibling_mask(policy->cpu)); #endif - cpufreq_frequency_table_get_attr(cbe_freqs, policy->cpu); - /* this ensures that policy->cpuinfo_min * and policy->cpuinfo_max are set correctly */ - return cpufreq_frequency_table_cpuinfo(policy, cbe_freqs); + return cpufreq_table_validate_and_show(policy, cbe_freqs); } static int cbe_cpufreq_cpu_exit(struct cpufreq_policy *policy)