From: Dan Carpenter <dan.carpenter@oracle.com>
To: kbuild@lists.01.org, Pradeep P V K <ppvk@codeaurora.org>,
miklos@szeredi.hu, linux-fsdevel@vger.kernel.org,
willy@infradead.org
Cc: lkp@intel.com, kbuild-all@lists.01.org, stummala@codeaurora.org,
sayalil@codeaurora.org, Pradeep P V K <ppvk@codeaurora.org>
Subject: Re: [PATCH V3] fuse: Fix VM_BUG_ON_PAGE issue while accessing zero ref count page
Date: Mon, 7 Sep 2020 15:13:25 +0300 [thread overview]
Message-ID: <20200907121325.GK8299@kadam> (raw)
In-Reply-To: <1599412344-495-1-git-send-email-ppvk@codeaurora.org>
[-- Attachment #1: Type: text/plain, Size: 3601 bytes --]
Hi Pradeep,
Thank you for the patch! Perhaps something to improve:
[auto build test WARNING on fuse/for-next]
[also build test WARNING on v5.9-rc4 next-20200903]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/Pradeep-P-V-K/fuse-Fix-VM_BUG_ON_PAGE-issue-while-accessing-zero-ref-count-page/20200907-111835
base: https://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse.git for-next
config: i386-randconfig-m021-20200907 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
New smatch warnings:
fs/fuse/dev.c:904 fuse_ref_page() warn: inconsistent returns 'fc->lock'.
Old smatch warnings:
fs/fuse/dev.c:1223 fuse_dev_do_read() warn: inconsistent returns 'fiq->lock'.
# https://github.com/0day-ci/linux/commit/f99df00de1b2265fba75dceb63724c2a9b0f1e52
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Pradeep-P-V-K/fuse-Fix-VM_BUG_ON_PAGE-issue-while-accessing-zero-ref-count-page/20200907-111835
git checkout f99df00de1b2265fba75dceb63724c2a9b0f1e52
vim +904 fs/fuse/dev.c
c3021629a0d820 Miklos Szeredi 2010-05-25 877 static int fuse_ref_page(struct fuse_copy_state *cs, struct page *page,
f99df00de1b226 Pradeep P V K 2020-09-06 878 unsigned offset, unsigned count, struct fuse_conn *fc)
c3021629a0d820 Miklos Szeredi 2010-05-25 879 {
c3021629a0d820 Miklos Szeredi 2010-05-25 880 struct pipe_buffer *buf;
0d8e84b0432beb Miklos Szeredi 2015-07-01 881 int err;
c3021629a0d820 Miklos Szeredi 2010-05-25 882
6718b6f855a0b4 David Howells 2019-10-16 883 if (cs->nr_segs >= cs->pipe->max_usage)
c3021629a0d820 Miklos Szeredi 2010-05-25 884 return -EIO;
c3021629a0d820 Miklos Szeredi 2010-05-25 885
f99df00de1b226 Pradeep P V K 2020-09-06 886 spin_lock(&fc->lock);
dc00809a53edd1 Miklos Szeredi 2015-07-01 887 err = unlock_request(cs->req);
0d8e84b0432beb Miklos Szeredi 2015-07-01 888 if (err)
0d8e84b0432beb Miklos Szeredi 2015-07-01 889 return err;
^^^^^^^^^^
Unlock before returning?
0d8e84b0432beb Miklos Szeredi 2015-07-01 890
c3021629a0d820 Miklos Szeredi 2010-05-25 891 fuse_copy_finish(cs);
c3021629a0d820 Miklos Szeredi 2010-05-25 892
c3021629a0d820 Miklos Szeredi 2010-05-25 893 buf = cs->pipebufs;
09cbfeaf1a5a67 Kirill A. Shutemov 2016-04-01 894 get_page(page);
c3021629a0d820 Miklos Szeredi 2010-05-25 895 buf->page = page;
f99df00de1b226 Pradeep P V K 2020-09-06 896 spin_unlock(&fc->lock);
c3021629a0d820 Miklos Szeredi 2010-05-25 897 buf->offset = offset;
c3021629a0d820 Miklos Szeredi 2010-05-25 898 buf->len = count;
c3021629a0d820 Miklos Szeredi 2010-05-25 899
c3021629a0d820 Miklos Szeredi 2010-05-25 900 cs->pipebufs++;
c3021629a0d820 Miklos Szeredi 2010-05-25 901 cs->nr_segs++;
c3021629a0d820 Miklos Szeredi 2010-05-25 902 cs->len = 0;
c3021629a0d820 Miklos Szeredi 2010-05-25 903
c3021629a0d820 Miklos Szeredi 2010-05-25 @904 return 0;
c3021629a0d820 Miklos Szeredi 2010-05-25 905 }
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 36412 bytes --]
prev parent reply other threads:[~2020-09-07 12:15 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-06 17:12 [PATCH V3] fuse: Fix VM_BUG_ON_PAGE issue while accessing zero ref count page Pradeep P V K
2020-09-07 12:13 ` Dan Carpenter [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=20200907121325.GK8299@kadam \
--to=dan.carpenter@oracle.com \
--cc=kbuild-all@lists.01.org \
--cc=kbuild@lists.01.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=lkp@intel.com \
--cc=miklos@szeredi.hu \
--cc=ppvk@codeaurora.org \
--cc=sayalil@codeaurora.org \
--cc=stummala@codeaurora.org \
--cc=willy@infradead.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).