From: kernel test robot <lkp@intel.com>
To: Christophe Leroy <christophe.leroy@csgroup.eu>
Cc: linuxppc-dev@lists.ozlabs.org, kbuild-all@lists.01.org
Subject: [PATCH] powerpc/vdso: fix ptr_ret.cocci warnings
Date: Fri, 27 Nov 2020 23:38:46 +0800 [thread overview]
Message-ID: <20201127153846.GA13652@2897a8153423> (raw)
In-Reply-To: <202011272338.igId7uLV-lkp@intel.com>
From: kernel test robot <lkp@intel.com>
arch/powerpc/kernel/vdso.c:192:1-3: 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: 08bbcbede11f ("powerpc/vdso: Move to _install_special_mapping() and remove arch_vma_name()")
CC: Christophe Leroy <christophe.leroy@csgroup.eu>
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: kernel test robot <lkp@intel.com>
---
tree: https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git next-test
head: 278f4532318c176ef8a22a78f45a8c8a30abe40b
commit: 08bbcbede11f0a75d620799ef8fc1f081ac66c79 [89/109] powerpc/vdso: Move to _install_special_mapping() and remove arch_vma_name()
vdso.c | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
--- a/arch/powerpc/kernel/vdso.c
+++ b/arch/powerpc/kernel/vdso.c
@@ -189,10 +189,7 @@ static int __arch_setup_additional_pages
vma = _install_special_mapping(mm, vdso_base, vdso_size,
VM_READ | VM_EXEC | VM_MAYREAD |
VM_MAYWRITE | VM_MAYEXEC, vdso_spec);
- if (IS_ERR(vma))
- return PTR_ERR(vma);
-
- return 0;
+ return PTR_ERR_OR_ZERO(vma);
}
int arch_setup_additional_pages(struct linux_binprm *bprm, int uses_interp)
prev parent reply other threads:[~2020-11-27 15:42 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-11-27 15:38 [powerpc:next-test 89/109] arch/powerpc/kernel/vdso.c:192:1-3: WARNING: PTR_ERR_OR_ZERO can be used kernel test robot
2020-11-27 15:38 ` kernel test robot [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20201127153846.GA13652@2897a8153423 \
--to=lkp@intel.com \
--cc=christophe.leroy@csgroup.eu \
--cc=kbuild-all@lists.01.org \
--cc=linuxppc-dev@lists.ozlabs.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).