[lustre-devel] [PATCH] staging: lustre: o2iblnd: fix misleading indentation
Dan Carpenter
dan.carpenter at oracle.com
Thu Oct 22 12:48:19 PDT 2015
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 <luisbg at osg.samsung.com>
> ---
>
> 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
More information about the lustre-devel
mailing list