From patchwork Wed Mar 19 21:33:00 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stratos Karafotis X-Patchwork-Id: 3861671 Return-Path: X-Original-To: patchwork-linux-pm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id A9129BF540 for ; Wed, 19 Mar 2014 21:42:37 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id D09A720212 for ; Wed, 19 Mar 2014 21:42:36 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 0BF24201FA for ; Wed, 19 Mar 2014 21:42:36 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754001AbaCSVmH (ORCPT ); Wed, 19 Mar 2014 17:42:07 -0400 Received: from sema.semaphore.gr ([78.46.194.137]:45158 "EHLO sema.semaphore.gr" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1750934AbaCSVmG (ORCPT ); Wed, 19 Mar 2014 17:42:06 -0400 Received: from albert.lan (ppp079166134095.access.hol.gr [79.166.134.95]) (using TLSv1 with cipher ECDHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) (Authenticated sender: stratosk) by sema.semaphore.gr (Postfix) with ESMTPSA id B4BA582BC7; Wed, 19 Mar 2014 22:33:00 +0100 (CET) Message-ID: <532A0D0C.50507@semaphore.gr> Date: Wed, 19 Mar 2014 23:33:00 +0200 From: Stratos Karafotis User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.3.0 MIME-Version: 1.0 To: "Rafael J. Wysocki" , Viresh Kumar CC: "cpufreq@vger.kernel.org" , "linux-pm@vger.kernel.org" , LKML Subject: [PATCH] cpufreq: Remove unnecessary braces Sender: linux-pm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pm@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Remove 3 sets of unnecessary braces Signed-off-by: Stratos Karafotis --- drivers/cpufreq/cpufreq.c | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/drivers/cpufreq/cpufreq.c b/drivers/cpufreq/cpufreq.c index 1eafd8c..ca3c01f 100644 --- a/drivers/cpufreq/cpufreq.c +++ b/drivers/cpufreq/cpufreq.c @@ -1325,17 +1325,16 @@ static int __cpufreq_remove_dev_prepare(struct device *dev, cpus = cpumask_weight(policy->cpus); up_read(&policy->rwsem); - if (cpu != policy->cpu) { + if (cpu != policy->cpu) sysfs_remove_link(&dev->kobj, "cpufreq"); - } else if (cpus > 1) { + else if (cpus > 1) { new_cpu = cpufreq_nominate_new_policy_cpu(policy, cpu); if (new_cpu >= 0) { update_policy_cpu(policy, new_cpu); - if (!cpufreq_suspended) { + if (!cpufreq_suspended) pr_debug("%s: policy Kobject moved to cpu: %d from: %d\n", __func__, new_cpu, cpu); - } } } @@ -2158,11 +2157,9 @@ int cpufreq_update_policy(unsigned int cpu) if (!policy->cur) { pr_debug("Driver did not initialize current freq\n"); policy->cur = new_policy.cur; - } else { - if (policy->cur != new_policy.cur && has_target()) + } else if (policy->cur != new_policy.cur && has_target()) cpufreq_out_of_sync(cpu, policy->cur, new_policy.cur); - } } ret = cpufreq_set_policy(policy, &new_policy);