Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751856AbdCMNOC (ORCPT ); Mon, 13 Mar 2017 09:14:02 -0400 Received: from o1678950229.outbound-mail.sendgrid.net ([167.89.50.229]:15801 "EHLO o1678950229.outbound-mail.sendgrid.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750860AbdCMNNy (ORCPT ); Mon, 13 Mar 2017 09:13:54 -0400 Date: Mon, 13 Mar 2017 13:13:51 +0000 From: Craig Inches To: Dan Carpenter Cc: Greg KH , devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org, oleg.drokin@intel.com, andreas.dilger@intel.com, lustre-devel@lists.lustre.org Subject: Re: [PATCH] staging: lustre fix constant comparision style issue in lu_object.h Message-ID: <20170313131351.GA14108@starbase.xayto.local> References: <20170311130740.11488-1-Craig@craiginches.com> <20170312133722.GC27791@kroah.com> <20170313121110.GD4136@mwanda> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170313121110.GD4136@mwanda> User-Agent: Mutt/1.5.24 (2015-08-30) X-SG-EID: UsLXQ589HNP4HLBydmD9pgHURQozLYm9XliudupI8YtRqtLhmYQhLwgZN0w/D4YJE951mRUi+5hRIV JSBYCNrwQACp/T1NceRD2Gyek4n4CWhe/UnBla4rrp1+pdvhNaH3YDFPeU88VjDd/41pE3TE3FKznX PXAGmU62BuOVoso6d5kIRCHP13YzH0DpG2gdgtLvi7Jp7/iXTy4dSiBiL2MfrofUoM7+Cse558nAwp E= Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 735 Lines: 22 On Mon, Mar 13, 2017 at 03:11:10PM +0300, Dan Carpenter wrote: > On Sun, Mar 12, 2017 at 02:37:22PM +0100, Greg KH wrote: > > On Sat, Mar 11, 2017 at 01:07:40PM +0000, Craig Inches wrote: > > > This patch resolves the "Comparisons should place the constant on > > > the right side of the test" found with checkpatch tool. > > > > Both are constants, I think checkpatch is the thing that is wrong here, > > don't you agree? > > Sort of constant-ish... The sizeof(*value) changes each time the macro > is used. I feel like checkpatch is right. > > regads, > dan carpenter > That was my take aswell.. PAGE_SIZE is constant for each boot, but sizeof could change. Happy to be lead by the more experienced here though. Cheers Craig