LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* [gfs2:for-next.mmap-fault 3/12] mm/gup.c:1685:23: sparse: sparse: Using plain integer as NULL pointer
@ 2021-08-03 12:01 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2021-08-03 12:01 UTC (permalink / raw)
  To: Andreas Gruenbacher; +Cc: kbuild-all, cluster-devel, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 2383 bytes --]

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/gfs2/linux-gfs2.git for-next.mmap-fault
head:   bfd94d74183df4cc99a705b96f2be61a865e5564
commit: 88a42059bb37be7ced7c0f4a62de07195bd7074e [3/12] Turn fault_in_pages_{readable,writeable} into fault_in_{readable,writeable}
config: s390-randconfig-s031-20210803 (attached as .config)
compiler: s390-linux-gcc (GCC) 10.3.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # apt-get install sparse
        # sparse version: v0.6.3-341-g8af24329-dirty
        # https://git.kernel.org/pub/scm/linux/kernel/git/gfs2/linux-gfs2.git/commit/?id=88a42059bb37be7ced7c0f4a62de07195bd7074e
        git remote add gfs2 https://git.kernel.org/pub/scm/linux/kernel/git/gfs2/linux-gfs2.git
        git fetch --no-tags gfs2 for-next.mmap-fault
        git checkout 88a42059bb37be7ced7c0f4a62de07195bd7074e
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-10.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=s390 SHELL=/bin/bash

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>


sparse warnings: (new ones prefixed by >>)
>> mm/gup.c:1685:23: sparse: sparse: Using plain integer as NULL pointer
   mm/gup.c:1711:23: sparse: sparse: Using plain integer as NULL pointer

vim +1685 mm/gup.c

  1671	
  1672	size_t fault_in_writeable(char __user *uaddr, size_t size)
  1673	{
  1674		char __user *start = uaddr, *end;
  1675	
  1676		if (unlikely(size == 0))
  1677			return 0;
  1678		if ((unsigned long)uaddr & ~PAGE_MASK) {
  1679			if (unlikely(__put_user(0, uaddr) != 0))
  1680				return 0;
  1681			uaddr = (char __user *)((unsigned long)uaddr | ~PAGE_MASK) + 1;
  1682		}
  1683		end = (char __user *)PAGE_ALIGN((unsigned long)uaddr + size);
  1684		if (unlikely(end < uaddr))
> 1685			end = 0;
  1686		while (uaddr != end) {
  1687			if (unlikely(__put_user(0, uaddr) != 0))
  1688				goto out;
  1689			uaddr += PAGE_SIZE;
  1690		}
  1691	
  1692	out:
  1693		return min_t(size_t, uaddr - start, size);
  1694	}
  1695	EXPORT_SYMBOL(fault_in_writeable);
  1696	

---
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: 41764 bytes --]

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-08-03 12:02 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-03 12:01 [gfs2:for-next.mmap-fault 3/12] mm/gup.c:1685:23: sparse: sparse: Using plain integer as NULL pointer kernel test robot

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).