From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932355AbcE2PIx (ORCPT ); Sun, 29 May 2016 11:08:53 -0400 Received: from smtprelay0174.hostedemail.com ([216.40.44.174]:44806 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S932273AbcE2PIw (ORCPT ); Sun, 29 May 2016 11:08:52 -0400 X-Session-Marker: 6A6F6540706572636865732E636F6D X-Spam-Summary: 2,0,0,,d41d8cd98f00b204,joe@perches.com,:::::::::::::::::::::::,RULES_HIT:41:355:379:541:599:800:960:973:988:989:1260:1277:1311:1313:1314:1345:1359:1373:1437:1515:1516:1518:1534:1541:1593:1594:1711:1730:1747:1777:1792:2393:2559:2562:2828:3138:3139:3140:3141:3142:3150:3352:3622:3865:3867:3868:3870:3871:3872:4321:4823:5007:7576:10004:10400:10848:11026:11232:11658:11914:12296:12438:12517:12519:12740:13069:13161:13229:13255:13311:13357:13439:13894:14181:14659:14721:21080:21434:30012:30054:30064:30074:30091,0,RBL:none,CacheIP:none,Bayesian:0.5,0.5,0.5,Netcheck:none,DomainCache:0,MSF:not bulk,SPF:fn,MSBL:0,DNSBL:none,Custom_rules:0:0:0,LFtime:2,LUA_SUMMARY:none X-HE-Tag: bell83_4cda7484ad74c X-Filterd-Recvd-Size: 2164 Message-ID: <1464534527.14627.9.camel@perches.com> Subject: Re: [PATCH trivial] include/linux/memblock.h: Clean up code for several trivial details From: Joe Perches To: chengang@emindsoft.com.cn, akpm@linux-foundation.org, trivial@kernel.org Cc: kuleshovmail@gmail.com, tony.luck@intel.com, tangchen@cn.fujitsu.com, will.deacon@arm.com, holt@sgi.com, ard.biesheuvel@linaro.org, kirill.shutemov@linux.intel.com, linux-kernel@vger.kernel.org, Chen Gang Date: Sun, 29 May 2016 08:08:47 -0700 In-Reply-To: <1464532567-6353-1-git-send-email-chengang@emindsoft.com.cn> References: <1464532567-6353-1-git-send-email-chengang@emindsoft.com.cn> Content-Type: text/plain; charset="ISO-8859-1" X-Mailer: Evolution 3.18.5.2-0ubuntu1 Mime-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, 2016-05-29 at 22:36 +0800, chengang@emindsoft.com.cn wrote: > From: Chen Gang > > Correct the function parameters alignment, since original code already > use both tabs and white spaces together for the incorrect parameters > alignment functions. > > If one line can hold one statement within 80 columns, let it in one line > (original code did not consider about the tabs/spaces for 2nd line when > a statement is separated into 2 lines). > > Use "!!" to let the boolean function return boolean value directly. [] > diff --git a/include/linux/memblock.h b/include/linux/memblock.h [] > @@ -191,12 +190,12 @@ static inline bool movable_node_is_enabled(void) >   >  static inline bool memblock_is_mirror(struct memblock_region *m) >  { > - return m->flags & MEMBLOCK_MIRROR; > + return !!(m->flags & MEMBLOCK_MIRROR); These !! uses are't necessary. The compiler makes the bool return 0 or 1. >  } >   >  static inline bool memblock_is_nomap(struct memblock_region *m) >  { > - return m->flags & MEMBLOCK_NOMAP; > + return !!(m->flags & MEMBLOCK_NOMAP); >  }