tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master head: 3f1fee3e7237347f09a2c7fa538119e6d9ea4b84 commit: e4e8bc1df691ba5ba749d1e2b67acf9827e51a35 [13115/15065] powerpc/kvm: Fix PR KVM with KUAP/MEM_KEYS enabled config: powerpc-randconfig-r034-20210426 (attached as .config) compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project d941863de2becb3d8d2e00676fc7125974934c7f) 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 powerpc cross compiling tool for clang build # apt-get install binutils-powerpc-linux-gnu # https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id=e4e8bc1df691ba5ba749d1e2b67acf9827e51a35 git remote add linux-next https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git git fetch --no-tags linux-next master git checkout e4e8bc1df691ba5ba749d1e2b67acf9827e51a35 # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 ARCH=powerpc If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot <lkp@xxxxxxxxx> All errors (new ones prefixed by >>): In file included from arch/powerpc/kvm/book3s_64_mmu_host.c:15: In file included from arch/powerpc/include/asm/book3s/64/pkeys.h:6: >> arch/powerpc/include/asm/book3s/64/hash-pkey.h:10:23: error: use of undeclared identifier 'VM_PKEY_BIT0' return (((vm_flags & VM_PKEY_BIT0) ? H_PTE_PKEY_BIT0 : 0x0UL) | ^ >> arch/powerpc/include/asm/book3s/64/hash-pkey.h:11:16: error: use of undeclared identifier 'VM_PKEY_BIT1' ((vm_flags & VM_PKEY_BIT1) ? H_PTE_PKEY_BIT1 : 0x0UL) | ^ >> arch/powerpc/include/asm/book3s/64/hash-pkey.h:12:16: error: use of undeclared identifier 'VM_PKEY_BIT2' ((vm_flags & VM_PKEY_BIT2) ? H_PTE_PKEY_BIT2 : 0x0UL) | ^ >> arch/powerpc/include/asm/book3s/64/hash-pkey.h:13:16: error: use of undeclared identifier 'VM_PKEY_BIT3' ((vm_flags & VM_PKEY_BIT3) ? H_PTE_PKEY_BIT3 : 0x0UL) | ^ >> arch/powerpc/include/asm/book3s/64/hash-pkey.h:14:16: error: use of undeclared identifier 'VM_PKEY_BIT4' ((vm_flags & VM_PKEY_BIT4) ? H_PTE_PKEY_BIT4 : 0x0UL)); ^ In file included from arch/powerpc/kvm/book3s_64_mmu_host.c:17: arch/powerpc/include/asm/mmu_context.h:287:19: error: redefinition of 'pte_to_hpte_pkey_bits' static inline u64 pte_to_hpte_pkey_bits(u64 pteflags, unsigned long flags) ^ arch/powerpc/include/asm/book3s/64/hash-pkey.h:17:19: note: previous definition is here static inline u64 pte_to_hpte_pkey_bits(u64 pteflags, unsigned long flags) ^ 6 errors generated. vim +/VM_PKEY_BIT0 +10 arch/powerpc/include/asm/book3s/64/hash-pkey.h d94b827e89dc3f Aneesh Kumar K.V 2020-11-27 7 b9658f83e721dd Aneesh Kumar K.V 2020-07-09 8 static inline u64 hash__vmflag_to_pte_pkey_bits(u64 vm_flags) b9658f83e721dd Aneesh Kumar K.V 2020-07-09 9 { b9658f83e721dd Aneesh Kumar K.V 2020-07-09 @10 return (((vm_flags & VM_PKEY_BIT0) ? H_PTE_PKEY_BIT0 : 0x0UL) | b9658f83e721dd Aneesh Kumar K.V 2020-07-09 @11 ((vm_flags & VM_PKEY_BIT1) ? H_PTE_PKEY_BIT1 : 0x0UL) | b9658f83e721dd Aneesh Kumar K.V 2020-07-09 @12 ((vm_flags & VM_PKEY_BIT2) ? H_PTE_PKEY_BIT2 : 0x0UL) | b9658f83e721dd Aneesh Kumar K.V 2020-07-09 @13 ((vm_flags & VM_PKEY_BIT3) ? H_PTE_PKEY_BIT3 : 0x0UL) | b9658f83e721dd Aneesh Kumar K.V 2020-07-09 @14 ((vm_flags & VM_PKEY_BIT4) ? H_PTE_PKEY_BIT4 : 0x0UL)); b9658f83e721dd Aneesh Kumar K.V 2020-07-09 15 } b9658f83e721dd Aneesh Kumar K.V 2020-07-09 16 :::::: The code at line 10 was first introduced by commit :::::: b9658f83e721ddfcee3e08b16a6628420de424c3 powerpc/book3s64/pkeys: pkeys are supported only on hash on book3s. :::::: TO: Aneesh Kumar K.V <aneesh.kumar@xxxxxxxxxxxxx> :::::: CC: Michael Ellerman <mpe@xxxxxxxxxxxxxx> --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx
Attachment:
.config.gz
Description: application/gzip