Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752239AbbGVThr (ORCPT ); Wed, 22 Jul 2015 15:37:47 -0400 Received: from smtp102.biz.mail.bf1.yahoo.com ([98.139.221.61]:26675 "EHLO smtp102.biz.mail.bf1.yahoo.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751756AbbGVThp (ORCPT ); Wed, 22 Jul 2015 15:37:45 -0400 X-Yahoo-Newman-Property: ymail-3 X-YMail-OSG: ePeweAcVM1kycevA8pT5XeO669SOlhQZ30goZc3FYA4pvzU zMycqcJSrT5wqmr9L11RqpN80s5O30RqPnSLnGwHzvqeHPjnMpaFqmTcPq9W trqHbbtjm3h2suEVXzQPPLADTvCGW1_ZSWyvM5LbLDVrTTz67SaEqRsPrjK9 oXNDz39wj2cfP3DZp0PFeYxuBtbbAT9bLVoPHvYWJ0qdCgzeEgB8EjqXiIY7 ZyQxz59eWzIGy3.8MHr5_8gYQBV8GlN6oTy7SXVhHRerDT8a7My4MXdWhql4 vbXFfcirV8pixX7wKEAj33xXs4usSLzf9SXBYMdLKWICDd21u30G8WSR5ztj C53b1Ts58pemOISEAfNvtoAyud.msPCx_qDR9NpGmF7RJRX0T79Eq6bDkrLT J.b6iENZBsIGGatSfIQML00.q3csZZOq2FqG1FnBEzVJLUBKV7H4ViHvAiHE Qh9O3VnL7EQAq7Pej0FFpTxizXNTuT2ACjvEVmviHDfHseffXivHjH6_aSjh wFakM0TaP6m6V8ghfMTb3B2EnAbem5ZFNVQ-- X-Yahoo-SMTP: OIJXglSswBDfgLtXluJ6wiAYv6_cnw-- Subject: Re: [PATCH] sysfs: fix simple_return.cocci warnings To: kbuild test robot , "Eric W. Biederman" References: <201506240705.vNc0oiCA%fengguang.wu@intel.com> <20150623234107.GA102996@lkp-sb04> Cc: kbuild-all@01.org, James Morris , "Serge E. Hallyn" , linux-security-module@vger.kernel.org, linux-kernel@vger.kernel.org From: Casey Schaufler Message-ID: <55AFF118.2050302@schaufler-ca.com> Date: Wed, 22 Jul 2015 12:38:00 -0700 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.1.0 MIME-Version: 1.0 In-Reply-To: <20150623234107.GA102996@lkp-sb04> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1461 Lines: 46 On 6/23/2015 4:41 PM, kbuild test robot wrote: > security/smack/smackfs.c:2251:1-4: WARNING: end returns can be simpified and declaration on line 2250 can be dropped > > Simplify a trivial if-return sequence. Possibly combine with a > preceding function call. > > Generated by: scripts/coccinelle/misc/simple_return.cocci > > Signed-off-by: Fengguang Wu Acked-by: Casey Schaufler Applied to https://github.com/cschaufler/smack-next.git#smack-for-4.3 > --- > > smackfs.c | 6 +----- > 1 file changed, 1 insertion(+), 5 deletions(-) > > --- a/security/smack/smackfs.c > +++ b/security/smack/smackfs.c > @@ -2247,11 +2247,7 @@ static const struct file_operations smk_ > */ > static int smk_init_sysfs(void) > { > - int err; > - err = sysfs_create_mount_point(fs_kobj, "smackfs"); > - if (err) > - return err; > - return 0; > + return sysfs_create_mount_point(fs_kobj, "smackfs"); > } > > /** > -- > To unsubscribe from this list: send the line "unsubscribe linux-kernel" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html > Please read the FAQ at http://www.tux.org/lkml/ > -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/