From patchwork Fri Sep 13 13:02:17 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 20245 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-qc0-f198.google.com (mail-qc0-f198.google.com [209.85.216.198]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 0A40920358 for ; Fri, 13 Sep 2013 13:25:46 +0000 (UTC) Received: by mail-qc0-f198.google.com with SMTP id l13sf1208692qcy.9 for ; Fri, 13 Sep 2013 06:25: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=xNHRVxCcb/8z8mC2ylj+lx98WDF3lPZ4xi3J6L2+sek=; b=Bl2vyY3F/7JfXWBRwHIOadNO0twmTsgex9QLBLvias9NHmA57daAFlo+nN1Rp8kijt qidIBmGALSYNHu+viX2TjtQbqW5/K75s72sextfAwz9DOzgi+TEOWShdRgmjnXN3H6Lh IrN8nGdxXSyWtPw8eN8wLbak57+x8HivbOtlt5xibTo7YISwMCM7M8CIR7kM2PtXAArB 6tx4KNKul1SzY+fr1pIOQe8vt34sOTShev2YnyG9vWMnOttGR7aRgU9pSOFndf8r9uU0 HT6/ywIzSXwaVFSo0a3mjqhClVkITyqELe3Gj6NlF0mRJz3Y43lGVrZSN95Y/FTEb0Z6 5bZw== X-Gm-Message-State: ALoCoQlrwVx1PoQnYPD+LtQh0C4v8obaX3BFwDkLGZWrZqsFpfN2o6aewJBzG0mKBpMKw7zNibDu X-Received: by 10.236.172.34 with SMTP id s22mr4947313yhl.25.1379078745873; Fri, 13 Sep 2013 06:25:45 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.3.169 with SMTP id d9ls1207520qed.61.gmail; Fri, 13 Sep 2013 06:25:45 -0700 (PDT) X-Received: by 10.52.173.165 with SMTP id bl5mr10440502vdc.18.1379078745639; Fri, 13 Sep 2013 06:25:45 -0700 (PDT) Received: from mail-ve0-f174.google.com (mail-ve0-f174.google.com [209.85.128.174]) by mx.google.com with ESMTPS id lu1si3136103vcb.13.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 13 Sep 2013 06:25:45 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.128.174 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.174; Received: by mail-ve0-f174.google.com with SMTP id jy13so943515veb.33 for ; Fri, 13 Sep 2013 06:25:45 -0700 (PDT) X-Received: by 10.58.168.205 with SMTP id zy13mr10073652veb.19.1379078745564; Fri, 13 Sep 2013 06:25: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 u4csp80628vcz; Fri, 13 Sep 2013 06:25:44 -0700 (PDT) X-Received: by 10.66.119.172 with SMTP id kv12mr15140475pab.34.1379078744602; Fri, 13 Sep 2013 06:25:44 -0700 (PDT) Received: from mail-pb0-f45.google.com (mail-pb0-f45.google.com [209.85.160.45]) by mx.google.com with ESMTPS id hi6si11236083pac.142.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 13 Sep 2013 06:25:44 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.160.45 is neither permitted nor denied by best guess record for domain of viresh.kumar@linaro.org) client-ip=209.85.160.45; Received: by mail-pb0-f45.google.com with SMTP id mc17so1229898pbc.32 for ; Fri, 13 Sep 2013 06:25:44 -0700 (PDT) X-Received: by 10.68.171.164 with SMTP id av4mr2104238pbc.175.1379078744200; Fri, 13 Sep 2013 06:25:44 -0700 (PDT) Received: from localhost ([122.167.78.148]) by mx.google.com with ESMTPSA id ef10sm18131356pac.1.1969.12.31.16.00.00 (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Fri, 13 Sep 2013 06:25: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 Subject: [PATCH 191/228] cpufreq: elanfreq: remove calls to cpufreq_notify_transition() Date: Fri, 13 Sep 2013 18:32:17 +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.128.174 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 drivers do following in their ->target_index() routines: struct cpufreq_freqs freqs; freqs.old = old freq... freqs.new = new freq... cpufreq_notify_transition(policy, &freqs, CPUFREQ_PRECHANGE); /* Change rate here */ cpufreq_notify_transition(policy, &freqs, CPUFREQ_POSTCHANGE); This is replicated over all cpufreq drivers today and there doesn't exists a good enough reason why this shouldn't be moved to cpufreq core instead. Earlier patches have added support in cpufreq core to do cpufreq notification on frequency change, this one removes it from this driver. Some related minor cleanups are also done along with it. Signed-off-by: Viresh Kumar --- drivers/cpufreq/elanfreq.c | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/drivers/cpufreq/elanfreq.c b/drivers/cpufreq/elanfreq.c index 4ab4153..de08acf 100644 --- a/drivers/cpufreq/elanfreq.c +++ b/drivers/cpufreq/elanfreq.c @@ -108,17 +108,6 @@ static unsigned int elanfreq_get_cpu_frequency(unsigned int cpu) static int elanfreq_target(struct cpufreq_policy *policy, unsigned int state) { - struct cpufreq_freqs freqs; - - freqs.old = elanfreq_get_cpu_frequency(0); - freqs.new = elan_multiplier[state].clock; - - cpufreq_notify_transition(policy, &freqs, CPUFREQ_PRECHANGE); - - printk(KERN_INFO "elanfreq: attempting to set frequency to %i kHz\n", - elan_multiplier[state].clock); - - /* * Access to the Elan's internal registers is indexed via * 0x22: Chip Setup & Control Register Index Register (CSCI) @@ -149,8 +138,6 @@ static int elanfreq_target(struct cpufreq_policy *policy, udelay(10000); local_irq_enable(); - cpufreq_notify_transition(policy, &freqs, CPUFREQ_POSTCHANGE); - return 0; } /*