lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening linux-cve-announce PHC | |
Open Source and information security mailing list archives
| ||
|
Date: Fri, 7 Aug 2020 22:48:12 +0800 From: Gao Xiang <hsiangkao@....com> To: kernel test robot <lkp@...el.com> Cc: kbuild-all@...ts.01.org, linux-kernel@...r.kernel.org, Greg Kroah-Hartman <gregkh@...uxfoundation.org> Subject: Re: fs/erofs/zdata.c:198:22: sparse: sparse: non size-preserving integer to pointer cast Hi, On Fri, Aug 07, 2020 at 08:08:10PM +0800, kernel test robot wrote: > Hi Gao, > > First bad commit (maybe != root cause): > > tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master > head: 86cfccb66937dd6cbf26ed619958b9e587e6a115 > commit: 47e4937a4a7ca4184fd282791dfee76c6799966a erofs: move erofs out of staging > date: 12 months ago > config: s390-randconfig-s032-20200807 (attached as .config) > compiler: s390-linux-gcc (GCC) 9.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.2-118-ge1578773-dirty > git checkout 47e4937a4a7ca4184fd282791dfee76c6799966a > # save the attached .config to linux build tree > COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=s390 > > If you fix the issue, kindly add following tag as appropriate > Reported-by: kernel test robot <lkp@...el.com> > > > sparse warnings: (new ones prefixed by >>) > > >> fs/erofs/zdata.c:198:22: sparse: sparse: non size-preserving integer to pointer cast > fs/erofs/zdata.c:282:22: sparse: sparse: non size-preserving integer to pointer cast > fs/erofs/zdata.c:1094:24: sparse: sparse: non size-preserving integer to pointer cast I don't think these are valid warnings. All these three lines are using cmpxchg struct page * (which is equivalent to unsigned long in these cmpxchg macros) and nothing special at all in my opinion (Especially the last two lines). +198 if (!cmpxchg_relaxed(pages, NULL, tagptr_cast_ptr(t))) +282 if (!cmpxchg(clt->compressedpages++, NULL, page)) +1094 if (oldpage != cmpxchg(&pcl->compressed_pages[nr], oldpage, page)) { btw, recently sparse warnings quite confuse me (p.s. they're all on alpha/s390/sparc archs and relate to cmpxchg/xchg by accident), I have no idea what happened with sparse. Thanks, Gao Xiang
Powered by blists - more mailing lists