tree:
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.git
linux-4.19.y
head: 030194a5b292bb7613407668d85af0b987bb9839
commit: 31ebc2fe02df202566d0e36c1106b4902d6e2f8c [2158/3560] powerpc/64s: flush L1D after
user accesses
config: powerpc64-randconfig-r025-20210311 (attached as .config)
compiler: clang version 13.0.0 (
https://github.com/llvm/llvm-project
574a9dabc63ba1e7a04c08d4bde2eacd61b44ce1)
reproduce (this is a W=1 build):
wget
https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O
~/bin/make.cross
chmod +x ~/bin/make.cross
# install powerpc64 cross compiling tool for clang build
# apt-get install binutils-powerpc64-linux-gnu
#
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.gi...
git remote add linux-stable-rc
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.git
git fetch --no-tags linux-stable-rc linux-4.19.y
git checkout 31ebc2fe02df202566d0e36c1106b4902d6e2f8c
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=powerpc64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All error/warnings (new ones prefixed by >>):
In file included from arch/powerpc/kernel/asm-offsets.c:16:
In file included from include/linux/compat.h:12:
In file included from include/linux/stat.h:19:
In file included from include/linux/time.h:6:
In file included from include/linux/seqlock.h:36:
In file included from include/linux/spinlock.h:54:
In file included from include/linux/irqflags.h:16:
In file included from arch/powerpc/include/asm/irqflags.h:12:
In file included from arch/powerpc/include/asm/hw_irq.h:64:
In file included from arch/powerpc/include/asm/paca.h:21:
In file included from arch/powerpc/include/asm/lppaca.h:36:
In file included from arch/powerpc/include/asm/mmu.h:313:
In file included from arch/powerpc/include/asm/book3s/64/mmu.h:30:
In file included from arch/powerpc/include/asm/book3s/64/mmu-hash.h:24:
arch/powerpc/include/asm/book3s/64/pgtable.h:1292:15: warning: 'const' type
qualifier on return type has no effect [-Wignored-qualifiers]
static inline const int pud_pfn(pud_t pud)
^~~~~~
In file included from arch/powerpc/kernel/asm-offsets.c:16:
In file included from include/linux/compat.h:19:
In file included from include/linux/uaccess.h:14:
In file included from arch/powerpc/include/asm/uaccess.h:9:
In file included from arch/powerpc/include/asm/kup.h:10:
> arch/powerpc/include/asm/book3s/64/kup-radix.h:5:1: warning:
declaration specifier missing, defaulting to 'int'
DECLARE_STATIC_KEY_FALSE(uaccess_flush_key);
^
int
> arch/powerpc/include/asm/book3s/64/kup-radix.h:5:26: error: a
parameter list without types is only allowed in a function definition
DECLARE_STATIC_KEY_FALSE(uaccess_flush_key);
^
> arch/powerpc/include/asm/book3s/64/kup-radix.h:18:6: error:
implicit declaration of function 'static_branch_unlikely'
[-Werror,-Wimplicit-function-declaration]
if
(static_branch_unlikely(&uaccess_flush_key))
^
> arch/powerpc/include/asm/book3s/64/kup-radix.h:18:30: error: use
of undeclared identifier 'uaccess_flush_key'
if
(static_branch_unlikely(&uaccess_flush_key))
^
In file included from arch/powerpc/kernel/asm-offsets.c:23:
include/linux/mman.h:133:9: warning: division by zero is undefined
[-Wdivision-by-zero]
_calc_vm_trans(flags, MAP_LOCKED, VM_LOCKED ) |
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/mman.h:111:21: note: expanded from macro '_calc_vm_trans'
: ((x) & (bit1)) / ((bit1) / (bit2))))
^ ~~~~~~~~~~~~~~~~~
include/linux/mman.h:134:9: warning: division by zero is undefined
[-Wdivision-by-zero]
_calc_vm_trans(flags, MAP_SYNC, VM_SYNC );
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/mman.h:110:48: note: expanded from macro '_calc_vm_trans'
((bit1) <= (bit2) ? ((x) & (bit1)) * ((bit2) / (bit1)) \
^ ~~~~~~
include/linux/mman.h:134:9: warning: division by zero is undefined
[-Wdivision-by-zero]
_calc_vm_trans(flags, MAP_SYNC, VM_SYNC );
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/mman.h:111:21: note: expanded from macro '_calc_vm_trans'
: ((x) & (bit1)) / ((bit1) / (bit2))))
^ ~~~~~~~~~~~~~~~~~
5 warnings and 3 errors generated.
--
In file included from arch/powerpc/kernel/asm-offsets.c:16:
In file included from include/linux/compat.h:12:
In file included from include/linux/stat.h:19:
In file included from include/linux/time.h:6:
In file included from include/linux/seqlock.h:36:
In file included from include/linux/spinlock.h:54:
In file included from include/linux/irqflags.h:16:
In file included from arch/powerpc/include/asm/irqflags.h:12:
In file included from arch/powerpc/include/asm/hw_irq.h:64:
In file included from arch/powerpc/include/asm/paca.h:21:
In file included from arch/powerpc/include/asm/lppaca.h:36:
In file included from arch/powerpc/include/asm/mmu.h:313:
In file included from arch/powerpc/include/asm/book3s/64/mmu.h:30:
In file included from arch/powerpc/include/asm/book3s/64/mmu-hash.h:24:
arch/powerpc/include/asm/book3s/64/pgtable.h:1292:15: warning: 'const' type
qualifier on return type has no effect [-Wignored-qualifiers]
static inline const int pud_pfn(pud_t pud)
^~~~~~
In file included from arch/powerpc/kernel/asm-offsets.c:16:
In file included from include/linux/compat.h:19:
In file included from include/linux/uaccess.h:14:
In file included from arch/powerpc/include/asm/uaccess.h:9:
In file included from arch/powerpc/include/asm/kup.h:10:
> arch/powerpc/include/asm/book3s/64/kup-radix.h:5:1: warning:
declaration specifier missing, defaulting to 'int'
DECLARE_STATIC_KEY_FALSE(uaccess_flush_key);
^
int
> arch/powerpc/include/asm/book3s/64/kup-radix.h:5:26: error: a
parameter list without types is only allowed in a function definition
DECLARE_STATIC_KEY_FALSE(uaccess_flush_key);
^
> arch/powerpc/include/asm/book3s/64/kup-radix.h:18:6: error:
implicit declaration of function 'static_branch_unlikely'
[-Werror,-Wimplicit-function-declaration]
if
(static_branch_unlikely(&uaccess_flush_key))
^
> arch/powerpc/include/asm/book3s/64/kup-radix.h:18:30: error: use
of undeclared identifier 'uaccess_flush_key'
if
(static_branch_unlikely(&uaccess_flush_key))
^
In file included from arch/powerpc/kernel/asm-offsets.c:23:
include/linux/mman.h:133:9: warning: division by zero is undefined
[-Wdivision-by-zero]
_calc_vm_trans(flags, MAP_LOCKED, VM_LOCKED ) |
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/mman.h:111:21: note: expanded from macro '_calc_vm_trans'
: ((x) & (bit1)) / ((bit1) / (bit2))))
^ ~~~~~~~~~~~~~~~~~
include/linux/mman.h:134:9: warning: division by zero is undefined
[-Wdivision-by-zero]
_calc_vm_trans(flags, MAP_SYNC, VM_SYNC );
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/mman.h:110:48: note: expanded from macro '_calc_vm_trans'
((bit1) <= (bit2) ? ((x) & (bit1)) * ((bit2) / (bit1)) \
^ ~~~~~~
include/linux/mman.h:134:9: warning: division by zero is undefined
[-Wdivision-by-zero]
_calc_vm_trans(flags, MAP_SYNC, VM_SYNC );
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/mman.h:111:21: note: expanded from macro '_calc_vm_trans'
: ((x) & (bit1)) / ((bit1) / (bit2))))
^ ~~~~~~~~~~~~~~~~~
5 warnings and 3 errors generated.
make[2]: *** [./Kbuild:56: arch/powerpc/kernel/asm-offsets.s] Error 1
make[2]: Target '__build' not remade because of errors.
make[1]: *** [Makefile:1123: prepare0] Error 2
make[1]: Target 'prepare' not remade because of errors.
make: *** [Makefile:146: sub-make] Error 2
make: Target 'prepare' not remade because of errors.
vim +5 arch/powerpc/include/asm/book3s/64/kup-radix.h
4
5 DECLARE_STATIC_KEY_FALSE(uaccess_flush_key);
6
7 /* Prototype for function defined in exceptions-64s.S */
8 void do_uaccess_flush(void);
9
10 static __always_inline void allow_user_access(void __user *to, const void __user
*from,
11 unsigned long size)
12 {
13 }
14
15 static inline void prevent_user_access(void __user *to, const void __user *from,
16 unsigned long size)
17 {
18 if (static_branch_unlikely(&uaccess_flush_key))
19 do_uaccess_flush();
20 }
21
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org