From patchwork Thu Oct 25 01:31:01 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fengguang Wu X-Patchwork-Id: 10655343 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 5639714BB for ; Thu, 25 Oct 2018 01:31:13 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 498712B682 for ; Thu, 25 Oct 2018 01:31:13 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 3B01E2B68B; Thu, 25 Oct 2018 01:31:13 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=unavailable version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D1F562B671 for ; Thu, 25 Oct 2018 01:31:12 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726236AbeJYKBj (ORCPT ); Thu, 25 Oct 2018 06:01:39 -0400 Received: from mga06.intel.com ([134.134.136.31]:55847 "EHLO mga06.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726204AbeJYKBj (ORCPT ); Thu, 25 Oct 2018 06:01:39 -0400 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga007.fm.intel.com ([10.253.24.52]) by orsmga104.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 24 Oct 2018 18:31:09 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.54,422,1534834800"; d="scan'208";a="80714334" Received: from lkp-server01.sh.intel.com (HELO lkp-server01) ([10.239.97.150]) by fmsmga007.fm.intel.com with ESMTP; 24 Oct 2018 18:31:07 -0700 Received: from kbuild by lkp-server01 with local (Exim 4.89) (envelope-from ) id 1gFUUM-0008HY-QG; Thu, 25 Oct 2018 09:31:06 +0800 Date: Thu, 25 Oct 2018 09:31:01 +0800 From: kbuild test robot To: Olga Kornievskaia Cc: kbuild-all@01.org, trond.myklebust@hammerspace.com, anna.schumaker@netapp.com, viro@zeniv.linux.org.uk, smfrench@gmail.com, miklos@szeredi.hu, linux-nfs@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-cifs@vger.kernel.org, linux-unionfs@vger.kernel.org, linux-man@vger.kernel.org Subject: [PATCH] fix ptr_ret.cocci warnings Message-ID: <20181025013101.GA41139@lkp-g5> References: <20181024195837.35532-12-olga.kornievskaia@gmail.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20181024195837.35532-12-olga.kornievskaia@gmail.com> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-nfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: kbuild test robot fs/nfs/nfs4file.c:345:12-18: WARNING: PTR_ERR_OR_ZERO can be used Use PTR_ERR_OR_ZERO rather than if(IS_ERR(...)) + PTR_ERR Generated by: scripts/coccinelle/api/ptr_ret.cocci Fixes: 53b276379386 ("NFS inter ssc open") CC: Olga Kornievskaia Signed-off-by: kbuild test robot --- url: https://github.com/0day-ci/linux/commits/Olga-Kornievskaia/client-side-support-for-inter-SSC-copy/20181025-043859 base: git://git.linux-nfs.org/projects/trondmy/linux-nfs.git linux-next nfs4file.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/fs/nfs/nfs4file.c +++ b/fs/nfs/nfs4file.c @@ -342,7 +342,7 @@ nfs42_ssc_open(struct vfsmount *ss_mnt, res = filep; out: dprintk("<-- %s error %ld filep %p r_ino %p\n", - __func__, IS_ERR(res) ? PTR_ERR(res) : 0, res, r_ino); + __func__, PTR_ERR_OR_ZERO(res), res, r_ino); return res; out_stateowner: