From patchwork Fri Sep 13 13:00:28 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 20136 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-ve0-f198.google.com (mail-ve0-f198.google.com [209.85.128.198]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 9144520358 for ; Fri, 13 Sep 2013 13:12:45 +0000 (UTC) Received: by mail-ve0-f198.google.com with SMTP id c14sf1226618vea.5 for ; Fri, 13 Sep 2013 06:12:45 -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=9ZkOAAFyNZ76imkEDiu+8XIqMPrxj2CG2bfbuI5NYWM=; b=HghHst3DGD6wWpwQn5AM+B5wiq88H5GTyz6gC78Q3qwByZUhQLODYV10N3FYmI4dPK QeVyF05dH/XR1DZ1AnGlD5gmAJzNuAd9D49W8zFx7lDptanQMy58tyIa+Hmqti8hr7jt s0iKTjDTRFGeGnjLl/qxphKIsadudasVz1cydVa4vnc9HPy4hNfapDfzHnozOWN1/h83 5uG6WpcJztMgE9n93RX6+HYJVwYuE6TZpCqDwfQZGEceWgpzO0clangBDMxXqQwnEs+/ Kz+QeOh6eG+DSwCMQ/TbRlN5KMveNVVeRYmOtuSaOL+OipWlULA88CDMfVKvlM+QQFf9 coag== X-Gm-Message-State: ALoCoQmOoAz+tcdYegIzMYCbka7j/wtfW3nm4bA4viG0DY9kvjsn9zz7+vXWUAsC7Q9wsLbr+7dL X-Received: by 10.236.85.6 with SMTP id t6mr4736734yhe.37.1379077965355; Fri, 13 Sep 2013 06:12:45 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.71.83 with SMTP id s19ls1171561qeu.7.gmail; Fri, 13 Sep 2013 06:12:45 -0700 (PDT) X-Received: by 10.58.207.103 with SMTP id lv7mr227252vec.33.1379077965122; Fri, 13 Sep 2013 06:12:45 -0700 (PDT) Received: from mail-ve0-f169.google.com (mail-ve0-f169.google.com [209.85.128.169]) by mx.google.com with ESMTPS id o5si3080229vdw.154.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 13 Sep 2013 06:12:45 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.128.169 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.128.169; Received: by mail-ve0-f169.google.com with SMTP id db12so973371veb.0 for ; Fri, 13 Sep 2013 06:12:45 -0700 (PDT) X-Received: by 10.58.196.132 with SMTP id im4mr1052629vec.28.1379077965016; Fri, 13 Sep 2013 06:12:45 -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 u4csp79929vcz; Fri, 13 Sep 2013 06:12:44 -0700 (PDT) X-Received: by 10.66.161.38 with SMTP id xp6mr15024934pab.145.1379077964105; Fri, 13 Sep 2013 06:12:44 -0700 (PDT) Received: from mail-pb0-f44.google.com (mail-pb0-f44.google.com [209.85.160.44]) by mx.google.com with ESMTPS id jx3si7418848pbc.204.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 13 Sep 2013 06:12:44 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.160.44 is neither permitted nor denied by best guess record for domain of viresh.kumar@linaro.org) client-ip=209.85.160.44; Received: by mail-pb0-f44.google.com with SMTP id xa7so1217021pbc.31 for ; Fri, 13 Sep 2013 06:12:43 -0700 (PDT) X-Received: by 10.68.238.34 with SMTP id vh2mr13378740pbc.101.1379077963697; Fri, 13 Sep 2013 06:12:43 -0700 (PDT) Received: from localhost ([122.167.78.148]) by mx.google.com with ESMTPSA id gh9sm11670532pbc.40.1969.12.31.16.00.00 (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Fri, 13 Sep 2013 06:12:43 -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 , Kukjin Kim Subject: [PATCH 082/228] cpufreq: s5pv210: Use generic cpufreq routines Date: Fri, 13 Sep 2013 18:30:28 +0530 Message-Id: <4c25cc8d8e42899f59559ec0fcdd3fdd3317b74a.1379063063.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-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.128.169 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: , Most of the CPUFreq drivers do similar things in .exit() and .verify() routines and .attr. So its better if we have generic routines for them which can be used by cpufreq drivers then. This patch uses these generic routines for this driver. Cc: Kukjin Kim Signed-off-by: Viresh Kumar --- drivers/cpufreq/s5pv210-cpufreq.c | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/drivers/cpufreq/s5pv210-cpufreq.c b/drivers/cpufreq/s5pv210-cpufreq.c index c266a7e..0eafc52 100644 --- a/drivers/cpufreq/s5pv210-cpufreq.c +++ b/drivers/cpufreq/s5pv210-cpufreq.c @@ -174,14 +174,6 @@ static void s5pv210_set_refresh(enum s5pv210_dmc_port ch, unsigned long freq) __raw_writel(tmp1, reg); } -static int s5pv210_verify_speed(struct cpufreq_policy *policy) -{ - if (policy->cpu) - return -EINVAL; - - return cpufreq_frequency_table_verify(policy, s5pv210_freq_table); -} - static unsigned int s5pv210_getspeed(unsigned int cpu) { if (cpu) @@ -603,7 +595,7 @@ static int s5pv210_cpufreq_reboot_notifier_event(struct notifier_block *this, static struct cpufreq_driver s5pv210_driver = { .flags = CPUFREQ_STICKY, - .verify = s5pv210_verify_speed, + .verify = cpufreq_generic_frequency_table_verify, .target = s5pv210_target, .get = s5pv210_getspeed, .init = s5pv210_cpu_init,