tree:
https://git.kernel.org/pub/scm/linux/kernel/git/djwong/xfs-linux.git
btree-private-unions
head: 30d91fbcef11ed07350f943fd3f695e0fb0635dd
commit: 35137236b91e958ca683fd4a045a29c0b5310938 [52/72] xfs: don't crash with
assfail
config: xtensa-allyesconfig (attached as .config)
compiler: xtensa-linux-gcc (GCC) 9.2.0
reproduce:
wget
https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O
~/bin/make.cross
chmod +x ~/bin/make.cross
git checkout 35137236b91e958ca683fd4a045a29c0b5310938
# save the attached .config to linux build tree
GCC_VERSION=9.2.0 make.cross ARCH=xtensa
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
In file included from include/linux/string.h:6,
from include/linux/uuid.h:12,
from fs///xfs/xfs_linux.h:10,
from fs///xfs/xfs.h:22,
from fs///xfs/xfs_trace.c:6:
include/linux/scatterlist.h: In function 'sg_set_buf':
> arch/xtensa/include/asm/page.h:193:9: warning: comparison of
unsigned expression >= 0 is always true [-Wtype-limits]
193 | ((pfn) >=
ARCH_PFN_OFFSET && ((pfn) - ARCH_PFN_OFFSET) < max_mapnr)
| ^~
include/linux/compiler.h:78:42: note: in definition of macro 'unlikely'
78 | # define unlikely(x) __builtin_expect(!!(x), 0)
| ^
include/linux/scatterlist.h:143:2: note: in expansion of macro 'BUG_ON'
143 | BUG_ON(!virt_addr_valid(buf));
| ^~~~~~
> arch/xtensa/include/asm/page.h:201:32: note: in expansion of
macro 'pfn_valid'
201 | #define virt_addr_valid(kaddr)
pfn_valid(__pa(kaddr) >> PAGE_SHIFT)
| ^~~~~~~~~
include/linux/scatterlist.h:143:10: note: in expansion of macro
'virt_addr_valid'
143 | BUG_ON(!virt_addr_valid(buf));
| ^~~~~~~~~~~~~~~
--
In file included from arch/xtensa/include/asm/processor.h:15,
from arch/xtensa/include/asm/atomic.h:18,
from include/linux/atomic.h:7,
from include/linux/iomap.h:5,
from fs///iomap/trace.c:5:
include/linux/scatterlist.h: In function 'sg_set_buf':
arch/xtensa/include/asm/page.h:193:9: error: comparison of unsigned expression >= 0
is always true [-Werror=type-limits]
193 | ((pfn) >= ARCH_PFN_OFFSET && ((pfn) - ARCH_PFN_OFFSET) <
max_mapnr)
| ^~
include/linux/compiler.h:78:42: note: in definition of macro 'unlikely'
78 | # define unlikely(x) __builtin_expect(!!(x), 0)
| ^
include/linux/scatterlist.h:143:2: note: in expansion of macro 'BUG_ON'
143 | BUG_ON(!virt_addr_valid(buf));
| ^~~~~~
> arch/xtensa/include/asm/page.h:201:32: note: in expansion of
macro 'pfn_valid'
201 | #define virt_addr_valid(kaddr)
pfn_valid(__pa(kaddr) >> PAGE_SHIFT)
| ^~~~~~~~~
include/linux/scatterlist.h:143:10: note: in expansion of macro
'virt_addr_valid'
143 | BUG_ON(!virt_addr_valid(buf));
| ^~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
vim +193 arch/xtensa/include/asm/page.h
c947a585ab13f3 arch/xtensa/include/asm/page.h Johannes Weiner 2009-03-04 163
2b83878dd74a7c arch/xtensa/include/asm/page.h Max Filippov 2017-03-29 164 #ifdef
CONFIG_MMU
2b83878dd74a7c arch/xtensa/include/asm/page.h Max Filippov 2017-03-29 165 static
inline unsigned long ___pa(unsigned long va)
2b83878dd74a7c arch/xtensa/include/asm/page.h Max Filippov 2017-03-29 166 {
2b83878dd74a7c arch/xtensa/include/asm/page.h Max Filippov 2017-03-29 167 unsigned
long off = va - PAGE_OFFSET;
2b83878dd74a7c arch/xtensa/include/asm/page.h Max Filippov 2017-03-29 168
2b83878dd74a7c arch/xtensa/include/asm/page.h Max Filippov 2017-03-29 169 if (off
>= XCHAL_KSEG_SIZE)
2b83878dd74a7c arch/xtensa/include/asm/page.h Max Filippov 2017-03-29 170 off -=
XCHAL_KSEG_SIZE;
2b83878dd74a7c arch/xtensa/include/asm/page.h Max Filippov 2017-03-29 171
7af710d988775a arch/xtensa/include/asm/page.h Max Filippov 2017-01-03 172 #ifndef
CONFIG_XIP_KERNEL
2b83878dd74a7c arch/xtensa/include/asm/page.h Max Filippov 2017-03-29 173 return
off + PHYS_OFFSET;
7af710d988775a arch/xtensa/include/asm/page.h Max Filippov 2017-01-03 174 #else
7af710d988775a arch/xtensa/include/asm/page.h Max Filippov 2017-01-03 175 if (off
< XCHAL_KSEG_SIZE)
7af710d988775a arch/xtensa/include/asm/page.h Max Filippov 2017-01-03 176 return
off + PHYS_OFFSET;
7af710d988775a arch/xtensa/include/asm/page.h Max Filippov 2017-01-03 177
7af710d988775a arch/xtensa/include/asm/page.h Max Filippov 2017-01-03 178 off -=
XCHAL_KSEG_SIZE;
7af710d988775a arch/xtensa/include/asm/page.h Max Filippov 2017-01-03 179 if (off
>= XCHAL_KIO_SIZE)
7af710d988775a arch/xtensa/include/asm/page.h Max Filippov 2017-01-03 180 off -=
XCHAL_KIO_SIZE;
7af710d988775a arch/xtensa/include/asm/page.h Max Filippov 2017-01-03 181
7af710d988775a arch/xtensa/include/asm/page.h Max Filippov 2017-01-03 182 return
off + XCHAL_KIO_PADDR;
7af710d988775a arch/xtensa/include/asm/page.h Max Filippov 2017-01-03 183 #endif
2b83878dd74a7c arch/xtensa/include/asm/page.h Max Filippov 2017-03-29 184 }
2b83878dd74a7c arch/xtensa/include/asm/page.h Max Filippov 2017-03-29 185 #define
__pa(x) ___pa((unsigned long)(x))
2b83878dd74a7c arch/xtensa/include/asm/page.h Max Filippov 2017-03-29 186 #else
a9f2fc628e3a26 arch/xtensa/include/asm/page.h Max Filippov 2016-04-13 187 #define
__pa(x) \
a9f2fc628e3a26 arch/xtensa/include/asm/page.h Max Filippov 2016-04-13 188
((unsigned long) (x) - PAGE_OFFSET + PHYS_OFFSET)
2b83878dd74a7c arch/xtensa/include/asm/page.h Max Filippov 2017-03-29 189 #endif
a9f2fc628e3a26 arch/xtensa/include/asm/page.h Max Filippov 2016-04-13 190 #define
__va(x) \
a9f2fc628e3a26 arch/xtensa/include/asm/page.h Max Filippov 2016-04-13 191 ((void
*)((unsigned long) (x) - PHYS_OFFSET + PAGE_OFFSET))
c4c4594b005d89 arch/xtensa/include/asm/page.h Chris Zankel 2012-11-28 192 #define
pfn_valid(pfn) \
c4c4594b005d89 arch/xtensa/include/asm/page.h Chris Zankel 2012-11-28 @193 ((pfn)
>= ARCH_PFN_OFFSET && ((pfn) - ARCH_PFN_OFFSET) < max_mapnr)
c4c4594b005d89 arch/xtensa/include/asm/page.h Chris Zankel 2012-11-28 194
655a0443470a73 include/asm-xtensa/page.h KAMEZAWA Hiroyuki 2006-03-27 195 #ifdef
CONFIG_DISCONTIGMEM
9a8fd558990215 include/asm-xtensa/page.h Chris Zankel 2005-06-23 196 # error
CONFIG_DISCONTIGMEM not supported
9a8fd558990215 include/asm-xtensa/page.h Chris Zankel 2005-06-23 197 #endif
9a8fd558990215 include/asm-xtensa/page.h Chris Zankel 2005-06-23 198
9a8fd558990215 include/asm-xtensa/page.h Chris Zankel 2005-06-23 199 #define
virt_to_page(kaddr) pfn_to_page(__pa(kaddr) >> PAGE_SHIFT)
9a8fd558990215 include/asm-xtensa/page.h Chris Zankel 2005-06-23 200 #define
page_to_virt(page) __va(page_to_pfn(page) << PAGE_SHIFT)
9a8fd558990215 include/asm-xtensa/page.h Chris Zankel 2005-06-23 @201 #define
virt_addr_valid(kaddr) pfn_valid(__pa(kaddr) >> PAGE_SHIFT)
9a8fd558990215 include/asm-xtensa/page.h Chris Zankel 2005-06-23 202 #define
page_to_phys(page) (page_to_pfn(page) << PAGE_SHIFT)
9a8fd558990215 include/asm-xtensa/page.h Chris Zankel 2005-06-23 203
:::::: The code at line 193 was first introduced by commit
:::::: c4c4594b005d89b56964071bbbdeb07daac5bc76 xtensa: clean up files to make them
code-style compliant
:::::: TO: Chris Zankel <chris(a)zankel.net>
:::::: CC: Chris Zankel <chris(a)zankel.net>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org