From patchwork Tue Sep 2 03:41:24 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 36445 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-pd0-f199.google.com (mail-pd0-f199.google.com [209.85.192.199]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id C05D02032B for ; Tue, 2 Sep 2014 03:41:46 +0000 (UTC) Received: by mail-pd0-f199.google.com with SMTP id v10sf36705585pde.10 for ; Mon, 01 Sep 2014 20:41: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:sender:precedence:list-id:x-original-sender :x-original-authentication-results:mailing-list:list-post:list-help :list-archive:list-unsubscribe; bh=KotNRjkeiDyh4twFCPNr8kowdYdIuK87gwgLIQrNhZs=; b=J58NcCDEB+31XIGQPJpHWZL1VbQKL6xFTXupE4mW/Et1uJ53leO3fw9dQNC7pQzVd6 ylrF2l2kH9nWmvRhCCAAzPd4sh3FT7AsdjnGEx350I95DixOQzJtqFD36ug5z7gjBe8l ehXCXf60x7wUSf9GBinQmzSexF3NKQzYIp2oxDrat1gqx8aJtM+7Tqag+nyfDw66vMpg PVwFjwn4GjeXT3UvawTsQr8dNHHwd6JAIxrRA3b0l7xSDSYBZma5mlbBQWQkzTYgBCny 2r7hNmST6Elr3p6DTP2vl93u9GT58ORv4A2HvVeh/l22abHSKvotd2FvVSnrciVvXpVP yDKw== X-Gm-Message-State: ALoCoQkQC168SUI1vFHr5G159vglDf6mCJoRYKA2HqsZxiqOwDdMfpMGV93mwCtUZN/bPpFuTTfV X-Received: by 10.66.160.164 with SMTP id xl4mr6659pab.48.1409629305849; Mon, 01 Sep 2014 20:41:45 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.42.133 with SMTP id c5ls2254441qga.38.gmail; Mon, 01 Sep 2014 20:41:45 -0700 (PDT) X-Received: by 10.52.185.193 with SMTP id fe1mr24301071vdc.31.1409629305749; Mon, 01 Sep 2014 20:41:45 -0700 (PDT) Received: from mail-vc0-f180.google.com (mail-vc0-f180.google.com [209.85.220.180]) by mx.google.com with ESMTPS id uv6si1774560vcb.3.2014.09.01.20.41.45 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 01 Sep 2014 20:41:45 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.180 as permitted sender) client-ip=209.85.220.180; Received: by mail-vc0-f180.google.com with SMTP id lf12so6321577vcb.39 for ; Mon, 01 Sep 2014 20:41:45 -0700 (PDT) X-Received: by 10.52.137.2 with SMTP id qe2mr23842514vdb.11.1409629305637; Mon, 01 Sep 2014 20:41:45 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.221.45.67 with SMTP id uj3csp466219vcb; Mon, 1 Sep 2014 20:41:45 -0700 (PDT) X-Received: by 10.68.94.196 with SMTP id de4mr43431081pbb.18.1409629304807; Mon, 01 Sep 2014 20:41:44 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id hb11si3966030pbd.5.2014.09.01.20.41.44 for ; Mon, 01 Sep 2014 20:41:44 -0700 (PDT) Received-SPF: none (google.com: linux-pm-owner@vger.kernel.org does not designate permitted sender hosts) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752527AbaIBDln (ORCPT + 14 others); Mon, 1 Sep 2014 23:41:43 -0400 Received: from mail-pd0-f179.google.com ([209.85.192.179]:52952 "EHLO mail-pd0-f179.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752453AbaIBDlm (ORCPT ); Mon, 1 Sep 2014 23:41:42 -0400 Received: by mail-pd0-f179.google.com with SMTP id z10so7426007pdj.24 for ; Mon, 01 Sep 2014 20:41:42 -0700 (PDT) X-Received: by 10.70.102.200 with SMTP id fq8mr935191pdb.152.1409629302303; Mon, 01 Sep 2014 20:41:42 -0700 (PDT) Received: from localhost ([122.167.123.172]) by mx.google.com with ESMTPSA id ez8sm3414836pdb.63.2014.09.01.20.41.40 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Mon, 01 Sep 2014 20:41:41 -0700 (PDT) From: Viresh Kumar To: Rafael Wysocki , yuantian.tang@freescale.com Cc: linaro-kernel@lists.linaro.org, linux-pm@vger.kernel.org, hongbo.zhang@freescale.com, leoli@freescale.com, Viresh Kumar Subject: [PATCH 1/2] cpufreq: ppc-corenet: remove duplicate update of cpu_data Date: Tue, 2 Sep 2014 09:11:24 +0530 Message-Id: <09092df3d8b03df99ee475357c5f5c9cc439c61c.1409629117.git.viresh.kumar@linaro.org> X-Mailer: git-send-email 2.0.3.693.g996b0fd Sender: linux-pm-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-pm@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: viresh.kumar@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.180 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , 'cpu_data' is updated for policy->cpu first and then for all CPUs in policy->cpus. policy->cpus is guaranteed to contain policy->cpu as well and so the first write to 'cpu_data' for policy->cpu is redundant. Remove it. Signed-off-by: Viresh Kumar Acked-by: Tang Yuantian Acked-by: Tang Yuantian --- Hi Yuantian, I was looking into this driver due to issues reported by Hongtao (cc'd) and found that we can live without some code. These aren't fixing any bugs and are just cleanups. I didn't had a compiler for this and so this isn't even compiled. It would be great if you can please review/test these patches. drivers/cpufreq/ppc-corenet-cpufreq.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/cpufreq/ppc-corenet-cpufreq.c b/drivers/cpufreq/ppc-corenet-cpufreq.c index 3607070..bee5df7 100644 --- a/drivers/cpufreq/ppc-corenet-cpufreq.c +++ b/drivers/cpufreq/ppc-corenet-cpufreq.c @@ -199,7 +199,6 @@ static int corenet_cpufreq_cpu_init(struct cpufreq_policy *policy) } data->table = table; - per_cpu(cpu_data, cpu) = data; /* update ->cpus if we have cluster, no harm if not */ cpumask_copy(policy->cpus, per_cpu(cpu_mask, cpu));