Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1750977AbdGMBZI (ORCPT ); Wed, 12 Jul 2017 21:25:08 -0400 Received: from LGEAMRELO11.lge.com ([156.147.23.51]:35187 "EHLO lgeamrelo11.lge.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750741AbdGMBZH (ORCPT ); Wed, 12 Jul 2017 21:25:07 -0400 X-Original-SENDERIP: 156.147.1.126 X-Original-MAILFROM: byungchul.park@lge.com X-Original-SENDERIP: 10.177.222.33 X-Original-MAILFROM: byungchul.park@lge.com Date: Thu, 13 Jul 2017 10:24:21 +0900 From: Byungchul Park To: Juri Lelli Cc: peterz@infradead.org, mingo@kernel.org, linux-kernel@vger.kernel.org, juri.lelli@gmail.com, rostedt@goodmis.org, bristot@redhat.com, kernel-team@lge.com Subject: Re: [PATCH v5 2/4] sched/deadline: Change return value of cpudl_find() Message-ID: <20170713012420.GE20323@X58A-UD3R> References: <1495504859-10960-1-git-send-email-byungchul.park@lge.com> <1495504859-10960-3-git-send-email-byungchul.park@lge.com> <20170712132232.kj6nxavxfglymsuy@e106622-lin> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170712132232.kj6nxavxfglymsuy@e106622-lin> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1438 Lines: 47 On Wed, Jul 12, 2017 at 02:22:32PM +0100, Juri Lelli wrote: > Hi, > > On 23/05/17 11:00, Byungchul Park wrote: > > Currently cpudl_find() returns the best cpu that means it has the > > maximum dl, however, the value is already kept in later_mask and the > > return value is not referred directly any more. > > > > Now, it's enough to return whether CPUs were found or not, like rt. > > > > I'd reword as > > cpudl_find() users are only interested in knowing if suitable CPU(s) > were found or not (and then they look at later_mask to know which). > > Change cpudl_find() return type accordingly. Hi, Much better. Thank you very much. I will change it. > > > Signed-off-by: Byungchul Park > > --- > > kernel/sched/cpudeadline.c | 26 +++++++++++++------------- > > kernel/sched/deadline.c | 6 +++--- > > 2 files changed, 16 insertions(+), 16 deletions(-) > > > > diff --git a/kernel/sched/cpudeadline.c b/kernel/sched/cpudeadline.c > > index fba235c..7408cbe 100644 > > --- a/kernel/sched/cpudeadline.c > > +++ b/kernel/sched/cpudeadline.c > > @@ -119,29 +119,29 @@ static inline int cpudl_maximum(struct cpudl *cp) > > * @p: the task > > * @later_mask: a mask to fill in with the selected CPUs (or NULL) > > * > > - * Returns: int - best CPU (heap maximum if suitable) > > + * Returns: (int)bool - CPUs were found > > Why not simply bool? I just did it same as rt. > Thanks, > > - Juri