From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751905AbdHGDeA (ORCPT ); Sun, 6 Aug 2017 23:34:00 -0400 Received: from mail-pg0-f45.google.com ([74.125.83.45]:38203 "EHLO mail-pg0-f45.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751442AbdHGDd6 (ORCPT ); Sun, 6 Aug 2017 23:33:58 -0400 Date: Mon, 7 Aug 2017 09:03:53 +0530 From: Viresh Kumar To: "Rafael J. Wysocki" Cc: Linux PM , LKML Subject: Re: [PATCH] cpufreq: Simplify cpufreq_can_do_remote_dvfs() Message-ID: <20170807033353.GD28857@vireshk-i7> References: <1957547.1DvPFJ11E3@aspire.rjw.lan> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1957547.1DvPFJ11E3@aspire.rjw.lan> User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 04-08-17, 14:57, Rafael J. Wysocki wrote: > From: Rafael J. Wysocki > > The if () in cpufreq_can_do_remote_dvfs() is superfluous, so drop > it and simply return the value of the expression under it. > > Signed-off-by: Rafael J. Wysocki > --- > > On top of the current linux-next. > > --- > include/linux/cpufreq.h | 7 ++----- > 1 file changed, 2 insertions(+), 5 deletions(-) > > Index: linux-pm/include/linux/cpufreq.h > =================================================================== > --- linux-pm.orig/include/linux/cpufreq.h > +++ linux-pm/include/linux/cpufreq.h > @@ -578,11 +578,8 @@ static inline bool cpufreq_can_do_remote > * - dvfs_possible_from_any_cpu flag is set > * - the local and remote CPUs share cpufreq policy > */ > - if (policy->dvfs_possible_from_any_cpu || > - cpumask_test_cpu(smp_processor_id(), policy->cpus)) > - return true; > - > - return false; > + return policy->dvfs_possible_from_any_cpu || > + cpumask_test_cpu(smp_processor_id(), policy->cpus); > } > > /********************************************************************* Acked-by: Viresh Kumar -- viresh