From: Julia Lawall <julia.lawall@inria.fr>
To: Jan Kara <jack@suse.cz>, Amir Goldstein <amir73il@gmail.com>
Cc: linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org,
kbuild-all@lists.01.org, Denis Efremov <efremov@linux.com>
Subject: [PATCH] inotify: fix minmax.cocci warnings
Date: Tue, 6 Apr 2021 22:49:26 +0200 (CEST) [thread overview]
Message-ID: <alpine.DEB.2.22.394.2104062246500.19097@hadrien> (raw)
From: kernel test robot <lkp@intel.com>
Opportunity for min().
Generated by: scripts/coccinelle/misc/minmax.cocci
Fixes: 8636e3295ce3 ("coccinelle: misc: add minmax script")
CC: Denis Efremov <efremov@linux.com>
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: kernel test robot <lkp@intel.com>
Signed-off-by: Julia Lawall <julia.lawall@inria.fr>
---
tree: https://git.kernel.org/pub/scm/linux/kernel/git/jlawall/linux.git for-5.12
head: cbc8ed0b4f7eeb782c153ec88d6d20bc0f0ca3a7
commit: 8636e3295ce33515c50ef728f0ff3800d97f9f44 [1/4] coccinelle: misc: add minmax script
:::::: branch date: 2 days ago
:::::: commit date: 2 weeks ago
inotify_user.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/fs/notify/inotify/inotify_user.c
+++ b/fs/notify/inotify/inotify_user.c
@@ -382,7 +382,7 @@ static int inotify_add_to_idr(struct idr
spin_unlock(idr_lock);
idr_preload_end();
- return ret < 0 ? ret : 0;
+ return min(ret, 0);
}
static struct inotify_inode_mark *inotify_idr_find_locked(struct fsnotify_group *group,
next reply other threads:[~2021-04-06 20:49 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-04-06 20:49 Julia Lawall [this message]
2021-04-07 16:05 ` [PATCH] inotify: fix minmax.cocci warnings Jan Kara
2021-04-07 17:02 ` Julia Lawall
2021-04-08 6:22 ` Denis Efremov
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=alpine.DEB.2.22.394.2104062246500.19097@hadrien \
--to=julia.lawall@inria.fr \
--cc=amir73il@gmail.com \
--cc=efremov@linux.com \
--cc=jack@suse.cz \
--cc=kbuild-all@lists.01.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.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).