From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id DC779A04DB; Sun, 22 Nov 2020 18:45:07 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id B6E0072D8; Sun, 22 Nov 2020 18:45:04 +0100 (CET) Received: from wout3-smtp.messagingengine.com (wout3-smtp.messagingengine.com [64.147.123.19]) by dpdk.org (Postfix) with ESMTP id ABD85FFA; Sun, 22 Nov 2020 18:45:01 +0100 (CET) Received: from compute2.internal (compute2.nyi.internal [10.202.2.42]) by mailout.west.internal (Postfix) with ESMTP id 21FA3476; Sun, 22 Nov 2020 12:44:59 -0500 (EST) Received: from mailfrontend2 ([10.202.2.163]) by compute2.internal (MEProxy); Sun, 22 Nov 2020 12:44:59 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding:content-type; s=fm2; bh= kVjt00nYMHbDbevxC9BosctFCznabWo1yYnRxL38tp8=; b=sGCHoAPihD2VOH/5 3h/jxh12bCbKruoNswwGHIbGwv03RBkze38Y8qz1I9J1ht4xKRWjkiw4bXeDqKZR neNIQ/TXJfhdDTKDDovjIMkcOeGLI4Efb0/cQTBnl3EH3JgRHpJB1IoPLC8BJie9 MMdfdGaZQbw8DLb5YlQmWhzlFiHQ9Xs2/kTCQn6AnEBLkZbLDq7ycdJXKksfsHia ZEFVSznONllJ6HUtcUX6Y9Xccc5IrVnXnQHm0RTTxAMf8xc9cP8CrDHJF+DXUOMk 4KDD20iD/nHYPRGeIR2JWFW665fWenrXDe+H7t3/0A6dUtId3+E1iBiftJyVzJcn UUwuqQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm1; bh=kVjt00nYMHbDbevxC9BosctFCznabWo1yYnRxL38t p8=; b=DGWmwE1g0SoD2UrBhx1IBOM5gseZdDk5vBCRsuwzAj0tlt24M2WYTVoSG RkBPvMshKIYjjfRCRSb29PGPa+7Ji8h0Tvsoa2adU+k1mS5zfFXr/c+3v0seFzTb odyQ0k6iw9dVP4e88/mDHWQbvx9kRJ1aONKRCe34GiDPm42lZ/h31dEU++ctEdeW jtBjjhWP9XkEMBhx6xgLldfOVCXOvBaO2MnKF4S72njw6ZRMQPJE6xMuauTfxR7Q 3eiaoALG7HZDn+mKpMRLmKdlR82y8V0aSkq6yvyXAI5jSTPGaXSHqna2pYmEQ19T blMZLWrdeYEQe7Y82dyxEPPEyIlaQ== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedujedrudeggedguddtjecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfgh necuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmd enucfjughrpefhvffufffkjghfggfgtgesthfuredttddtvdenucfhrhhomhepvfhhohhm rghsucfoohhnjhgrlhhonhcuoehthhhomhgrshesmhhonhhjrghlohhnrdhnvghtqeenuc ggtffrrghtthgvrhhnpedugefgvdefudfftdefgeelgffhueekgfffhfeujedtteeutdej ueeiiedvffegheenucfkphepjeejrddufeegrddvtdefrddukeegnecuvehluhhsthgvrh fuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomhepthhhohhmrghssehmohhnjhgr lhhonhdrnhgvth X-ME-Proxy: Received: from xps.localnet (184.203.134.77.rev.sfr.net [77.134.203.184]) by mail.messagingengine.com (Postfix) with ESMTPA id 8D53E3064AAA; Sun, 22 Nov 2020 12:44:56 -0500 (EST) From: Thomas Monjalon To: wangyunjian Cc: "Burakov, Anatoly" , "dev@dpdk.org" , stable@dpdk.org, "rsanford2@gmail.com" , "Lilijun (Jerry)" , xudingke Date: Sun, 22 Nov 2020 18:44:55 +0100 Message-ID: <2171508.PB3JDZ5GFF@thomas> In-Reply-To: <34EFBCA9F01B0748BEB6B629CE643AE60DB077B2@DGGEMM533-MBX.china.huawei.com> References: <1605173475-18044-1-git-send-email-wangyunjian@huawei.com> <34EFBCA9F01B0748BEB6B629CE643AE60DB077B2@DGGEMM533-MBX.china.huawei.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Subject: Re: [dpdk-dev] [dpdk-stable] [PATCH] malloc: cleanup coding style X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" 12/11/2020 14:41, wangyunjian: > From: Burakov, Anatoly [mailto:anatoly.burakov@intel.com] > > On 12-Nov-20 9:31 AM, wangyunjian wrote: > > > From: Yunjian Wang > > > > > > Cleanup code style issue reported by kernel checkpatch. As follows: > > > * ERROR:CODE_INDENT: code indent should use tabs where possible > > > * ERROR:SPACING: spaces required around that '?' (ctx:VxE) > > > * WARNING:INDENTED_LABEL: labels should not be indented > > > > > > Fixes: b0489e7bca2f ("malloc: fix linear complexity") > > > Cc: stable@dpdk.org > > > > > > Signed-off-by: Yunjian Wang > > > --- > > > --- a/lib/librte_eal/common/malloc_elem.c > > > +++ b/lib/librte_eal/common/malloc_elem.c > > > @@ -391,14 +391,14 @@ malloc_elem_free_list_index(size_t size) > > > return 0; > > > > > > /* Find next power of 2 >= size. */ > > > - log2 = sizeof(size) * 8 - __builtin_clzl(size-1); > > > + log2 = sizeof(size) * 8 - __builtin_clzl(size - 1); > > > > > > /* Compute freelist index, based on log2(size). */ > > > index = (log2 - MALLOC_MINSIZE_LOG2 + > > MALLOC_LOG2_INCREMENT - 1) / > > > - MALLOC_LOG2_INCREMENT; > > > + MALLOC_LOG2_INCREMENT; > > > > Here and below, I believe we usually add two indents to the continuation > > line, to avoid confusing with things like if statements. > > It is already two indents in the patch. Please double check? No it is two indents from the beginning of the line, while Anatoly was asking for double additional indent. > > With that fixed, I fix it. > > Acked-by: Anatoly Burakov Applied, thanks