linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Kent Overstreet <kmo@daterainc.com>
Cc: oe-kbuild-all@lists.linux.dev,
	Linux Memory Management List <linux-mm@kvack.org>
Subject: [linux-next:master 4164/6975] fs/bcachefs/fs-io-pagecache.c:25:35: sparse: sparse: invalid assignment: &=
Date: Fri, 22 Sep 2023 05:54:08 +0800	[thread overview]
Message-ID: <202309220540.Tdv1xssY-lkp@intel.com> (raw)

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head:   940fcc189c51032dd0282cbee4497542c982ac59
commit: 0060c68159fc4cc2beb2e184ba0b5677ff6ada05 [4164/6975] bcachefs: Split up fs-io.[ch]
config: x86_64-randconfig-122-20230922 (https://download.01.org/0day-ci/archive/20230922/202309220540.Tdv1xssY-lkp@intel.com/config)
compiler: gcc-11 (Debian 11.3.0-12) 11.3.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20230922/202309220540.Tdv1xssY-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202309220540.Tdv1xssY-lkp@intel.com/

sparse warnings: (new ones prefixed by >>)
>> fs/bcachefs/fs-io-pagecache.c:25:35: sparse: sparse: invalid assignment: &=
>> fs/bcachefs/fs-io-pagecache.c:25:35: sparse:    left side has type int
>> fs/bcachefs/fs-io-pagecache.c:25:35: sparse:    right side has type restricted fgf_t
>> fs/bcachefs/fs-io-pagecache.c:31:69: sparse: sparse: incorrect type in argument 3 (different base types) @@     expected restricted fgf_t [usertype] fgp_flags @@     got int fgp_flags @@
   fs/bcachefs/fs-io-pagecache.c:31:69: sparse:     expected restricted fgf_t [usertype] fgp_flags
   fs/bcachefs/fs-io-pagecache.c:31:69: sparse:     got int fgp_flags
>> fs/bcachefs/fs-io-pagecache.c:41:49: sparse: sparse: restricted fgf_t degrades to integer
--
>> fs/bcachefs/fs-io-buffered.c:833:65: sparse: sparse: incorrect type in argument 4 (different base types) @@     expected int @@     got restricted fgf_t @@
   fs/bcachefs/fs-io-buffered.c:833:65: sparse:     expected int
   fs/bcachefs/fs-io-buffered.c:833:65: sparse:     got restricted fgf_t

vim +25 fs/bcachefs/fs-io-pagecache.c

    13	
    14	int bch2_filemap_get_contig_folios_d(struct address_space *mapping,
    15					     loff_t start, u64 end,
    16					     int fgp_flags, gfp_t gfp,
    17					     folios *folios)
    18	{
    19		struct folio *f;
    20		u64 pos = start;
    21		int ret = 0;
    22	
    23		while (pos < end) {
    24			if ((u64) pos >= (u64) start + (1ULL << 20))
  > 25				fgp_flags &= ~FGP_CREAT;
    26	
    27			ret = darray_make_room_gfp(folios, 1, gfp & GFP_KERNEL);
    28			if (ret)
    29				break;
    30	
  > 31			f = __filemap_get_folio(mapping, pos >> PAGE_SHIFT, fgp_flags, gfp);
    32			if (IS_ERR_OR_NULL(f))
    33				break;
    34	
    35			BUG_ON(folios->nr && folio_pos(f) != pos);
    36	
    37			pos = folio_end_pos(f);
    38			darray_push(folios, f);
    39		}
    40	
  > 41		if (!folios->nr && !ret && (fgp_flags & FGP_CREAT))
    42			ret = -ENOMEM;
    43	
    44		return folios->nr ? 0 : ret;
    45	}
    46	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki


                 reply	other threads:[~2023-09-21 21:55 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=202309220540.Tdv1xssY-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=kmo@daterainc.com \
    --cc=linux-mm@kvack.org \
    --cc=oe-kbuild-all@lists.linux.dev \
    /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