From patchwork Fri Sep 13 13:00:00 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 20108 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-qc0-f197.google.com (mail-qc0-f197.google.com [209.85.216.197]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 7F2D6202E6 for ; Fri, 13 Sep 2013 13:09:27 +0000 (UTC) Received: by mail-qc0-f197.google.com with SMTP id r5sf1194145qcx.0 for ; Fri, 13 Sep 2013 06:09:27 -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=x8ctS/W8bcfVfgMjOf0gGd5ZSt4MWAn6g968lwTkwHY=; b=XWNcdOenkuwLTQpNj/HfP1cD6i9sK4nQ+DXE5PwLhbUW1tWyDoN8e6qnMd2ZUEXNm2 qORygbPhqvpj7t+UGieW83WaxCXiB9tc6aBNyEE336Kk2IrI9+U6blUCXL3Yktql2E4c hA1RqCWJiEgj5MN9n0DWHdWytCV2mTggZ7xxRd0hUuG1Xsdsb0ktBVbgiDJy0kV1Tfsl T3KpBhPTSB/jhFwEMcwpwpe3ERcvsCn9m8DejOSdySwWJ2itPgqp2fppav41njOHtJrn pndJrM5YtfjmMppxYFTAKWoG29KqNHh+n+uvmxV7+/QbY6VrY3GDG+09bkihPZIlvCtU Dbrg== X-Gm-Message-State: ALoCoQmqRNsZTii8IpVxvP7y9p+/8zyYpBAf3LRZlEkJooLeNfsfXX1kOZODiVNm4VCQdpsvvH4X X-Received: by 10.236.4.69 with SMTP id 45mr4930115yhi.20.1379077767329; Fri, 13 Sep 2013 06:09:27 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.4.231 with SMTP id n7ls1101720qen.14.gmail; Fri, 13 Sep 2013 06:09:27 -0700 (PDT) X-Received: by 10.58.155.6 with SMTP id vs6mr220402veb.32.1379077767081; Fri, 13 Sep 2013 06:09:27 -0700 (PDT) Received: from mail-vc0-f176.google.com (mail-vc0-f176.google.com [209.85.220.176]) by mx.google.com with ESMTPS id m10si3090683veh.120.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 13 Sep 2013 06:09:27 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.220.176 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.176; Received: by mail-vc0-f176.google.com with SMTP id lf11so884443vcb.7 for ; Fri, 13 Sep 2013 06:09:27 -0700 (PDT) X-Received: by 10.52.157.134 with SMTP id wm6mr5831565vdb.26.1379077766991; Fri, 13 Sep 2013 06:09:26 -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 u4csp79772vcz; Fri, 13 Sep 2013 06:09:26 -0700 (PDT) X-Received: by 10.68.212.37 with SMTP id nh5mr13527944pbc.16.1379077766049; Fri, 13 Sep 2013 06:09:26 -0700 (PDT) Received: from mail-pd0-f176.google.com (mail-pd0-f176.google.com [209.85.192.176]) by mx.google.com with ESMTPS id mj9si11116990pab.335.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 13 Sep 2013 06:09:26 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.192.176 is neither permitted nor denied by best guess record for domain of viresh.kumar@linaro.org) client-ip=209.85.192.176; Received: by mail-pd0-f176.google.com with SMTP id q10so1228340pdj.21 for ; Fri, 13 Sep 2013 06:09:25 -0700 (PDT) X-Received: by 10.68.213.167 with SMTP id nt7mr13425725pbc.140.1379077765634; Fri, 13 Sep 2013 06:09:25 -0700 (PDT) Received: from localhost ([122.167.78.148]) by mx.google.com with ESMTPSA id oj6sm18014578pab.9.1969.12.31.16.00.00 (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Fri, 13 Sep 2013 06:09:25 -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 , "David S. Miller" , sparclinux@vger.kernel.org Subject: [PATCH 054/228] cpufreq: sparc: call cpufreq_frequency_table_put_attr() Date: Fri, 13 Sep 2013 18:30:00 +0530 Message-Id: <7baecf8302d921d18afa8fc7447e68e41eb434e8.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.220.176 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: , Drivers which have an exit path must call cpufreq_frequency_table_put_attr() if they have called cpufreq_frequency_table_get_attr() in their init path. This driver was missing this part and is fixed with this patch. Cc: David S. Miller Cc: sparclinux@vger.kernel.org Signed-off-by: Viresh Kumar --- drivers/cpufreq/sparc-us2e-cpufreq.c | 4 +++- drivers/cpufreq/sparc-us3-cpufreq.c | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/drivers/cpufreq/sparc-us2e-cpufreq.c b/drivers/cpufreq/sparc-us2e-cpufreq.c index e35840d..8db0c18 100644 --- a/drivers/cpufreq/sparc-us2e-cpufreq.c +++ b/drivers/cpufreq/sparc-us2e-cpufreq.c @@ -329,8 +329,10 @@ static int __init us2e_freq_cpu_init(struct cpufreq_policy *policy) static int us2e_freq_cpu_exit(struct cpufreq_policy *policy) { - if (cpufreq_us2e_driver) + if (cpufreq_us2e_driver) { + cpufreq_frequency_table_put_attr(policy->cpu); us2e_set_cpu_divider_index(policy, 0); + } return 0; } diff --git a/drivers/cpufreq/sparc-us3-cpufreq.c b/drivers/cpufreq/sparc-us3-cpufreq.c index 23f2d3b..120a2df 100644 --- a/drivers/cpufreq/sparc-us3-cpufreq.c +++ b/drivers/cpufreq/sparc-us3-cpufreq.c @@ -186,8 +186,10 @@ static int __init us3_freq_cpu_init(struct cpufreq_policy *policy) static int us3_freq_cpu_exit(struct cpufreq_policy *policy) { - if (cpufreq_us3_driver) + if (cpufreq_us3_driver) { + cpufreq_frequency_table_put_attr(policy->cpu); us3_set_cpu_divider_index(policy, 0); + } return 0; }