From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758120AbbJVTsl (ORCPT ); Thu, 22 Oct 2015 15:48:41 -0400 Received: from userp1040.oracle.com ([156.151.31.81]:40619 "EHLO userp1040.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1758012AbbJVTsj (ORCPT ); Thu, 22 Oct 2015 15:48:39 -0400 Date: Thu, 22 Oct 2015 22:48:19 +0300 From: Dan Carpenter To: Luis de Bethencourt Cc: linux-kernel@vger.kernel.org, devel@driverdev.osuosl.org, andreas.dilger@intel.com, gulsah.1004@gmail.com, gregkh@linuxfoundation.org, shuey@purdue.edu, oleg.drokin@intel.com, yejiayily@gmail.com, guillaume.matheron@ens.fr, lustre-devel@lists.lustre.org, amir.shehata@intel.com, he.huang@intel.com Subject: Re: [PATCH] staging: lustre: o2iblnd: fix misleading indentation Message-ID: <20151022194819.GR7340@mwanda> References: <1445449240-30305-1-git-send-email-luisbg@osg.samsung.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1445449240-30305-1-git-send-email-luisbg@osg.samsung.com> User-Agent: Mutt/1.5.21 (2010-09-15) X-Source-IP: aserv0022.oracle.com [141.146.126.234] Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Oct 21, 2015 at 06:40:40PM +0100, Luis de Bethencourt wrote: > The code is correct, the indentation is misleading. Only the the return rc > is part of the conditional statement if rc != 0. > > Fix a smatch warning: > drivers/staging/lustre/lnet/klnds/o2iblnd/o2iblnd.c:2157 > kiblnd_hdev_setup_mrs() warn: curly braces intended? > > Signed-off-by: Luis de Bethencourt > --- > > Hi, > > This patch gives a warning in checkpatch.pl for the line: > if (hdev->ibh_mrs == NULL) > > It would be cleaner if this was 'if (!hdev->ibh_mrs)' instead. I didn't fix > this as well because the file has 41 instances of comparisons with NULL. I > would be happy to do so in a patch in reply to this one if it would be good. > You did the right thing. One thing per patch. regards, dan carpenter