[powerpc:next-test 124/184] drivers/misc/lkdtm/powerpc.c:13:54: error: no member named 'sllp' in 'struct mmu_psize_def'

kernel test robot lkp at intel.com
Thu Dec 3 06:16:24 AEDT 2020


tree:   https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git next-test
head:   fb003959777a635dea8910cf71109b612c7f940c
commit: d1579010cfe439978f9830b5632f9795049c6717 [124/184] lkdtm/powerpc: Add SLB multihit test
config: powerpc64-randconfig-r013-20201202 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project 2671fccf0381769276ca8246ec0499adcb9b0355)
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/powerpc/linux.git/commit/?id=d1579010cfe439978f9830b5632f9795049c6717
        git remote add powerpc https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git
        git fetch --no-tags powerpc next-test
        git checkout d1579010cfe439978f9830b5632f9795049c6717
        # 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 at intel.com>

All errors (new ones prefixed by >>):

>> drivers/misc/lkdtm/powerpc.c:13:54: error: no member named 'sllp' in 'struct mmu_psize_def'
           flags = SLB_VSID_KERNEL | mmu_psize_defs[page_size].sllp;
                                     ~~~~~~~~~~~~~~~~~~~~~~~~~ ^
>> drivers/misc/lkdtm/powerpc.c:13:10: error: use of undeclared identifier 'SLB_VSID_KERNEL'
           flags = SLB_VSID_KERNEL | mmu_psize_defs[page_size].sllp;
                   ^
>> drivers/misc/lkdtm/powerpc.c:17:15: error: implicit declaration of function 'mk_vsid_data' [-Werror,-Wimplicit-function-declaration]
                        : "r" (mk_vsid_data(p, ssize, flags)),
                               ^
>> drivers/misc/lkdtm/powerpc.c:18:15: error: implicit declaration of function 'mk_esid_data' [-Werror,-Wimplicit-function-declaration]
                          "r" (mk_esid_data(p, ssize, SLB_NUM_BOLTED))
                               ^
   drivers/misc/lkdtm/powerpc.c:18:15: note: did you mean 'mk_vsid_data'?
   drivers/misc/lkdtm/powerpc.c:17:15: note: 'mk_vsid_data' declared here
                        : "r" (mk_vsid_data(p, ssize, flags)),
                               ^
>> drivers/misc/lkdtm/powerpc.c:18:38: error: use of undeclared identifier 'SLB_NUM_BOLTED'
                          "r" (mk_esid_data(p, ssize, SLB_NUM_BOLTED))
                                                      ^
   drivers/misc/lkdtm/powerpc.c:23:34: error: use of undeclared identifier 'SLB_NUM_BOLTED'
                             "r" (mk_esid_data(p, ssize, SLB_NUM_BOLTED + 1))
                                                         ^
>> drivers/misc/lkdtm/powerpc.c:37:37: error: use of undeclared identifier 'MMU_SEGSIZE_1T'
           insert_slb_entry((unsigned long)p, MMU_SEGSIZE_1T, mmu_vmalloc_psize);
                                              ^
>> drivers/misc/lkdtm/powerpc.c:37:53: error: use of undeclared identifier 'mmu_vmalloc_psize'
           insert_slb_entry((unsigned long)p, MMU_SEGSIZE_1T, mmu_vmalloc_psize);
                                                              ^
   drivers/misc/lkdtm/powerpc.c:56:37: error: use of undeclared identifier 'MMU_SEGSIZE_1T'
           insert_slb_entry((unsigned long)p, MMU_SEGSIZE_1T, mmu_linear_psize);
                                              ^
   drivers/misc/lkdtm/powerpc.c:85:18: error: use of undeclared identifier 'SLB_NUM_BOLTED'
                             "r" (esid | SLB_NUM_BOLTED)
                                         ^
   drivers/misc/lkdtm/powerpc.c:94:19: error: use of undeclared identifier 'SLB_NUM_BOLTED'
                             "r" (esid | (SLB_NUM_BOLTED + 1))
                                          ^
   11 errors generated.

vim +13 drivers/misc/lkdtm/powerpc.c

     7	
     8	/* Inserts new slb entries */
     9	static void insert_slb_entry(unsigned long p, int ssize, int page_size)
    10	{
    11		unsigned long flags;
    12	
  > 13		flags = SLB_VSID_KERNEL | mmu_psize_defs[page_size].sllp;
    14		preempt_disable();
    15	
    16		asm volatile("slbmte %0,%1" :
  > 17			     : "r" (mk_vsid_data(p, ssize, flags)),
  > 18			       "r" (mk_esid_data(p, ssize, SLB_NUM_BOLTED))
    19			     : "memory");
    20	
    21		asm volatile("slbmte %0,%1" :
    22				: "r" (mk_vsid_data(p, ssize, flags)),
    23				  "r" (mk_esid_data(p, ssize, SLB_NUM_BOLTED + 1))
    24				: "memory");
    25		preempt_enable();
    26	}
    27	
    28	/* Inject slb multihit on vmalloc-ed address i.e 0xD00... */
    29	static int inject_vmalloc_slb_multihit(void)
    30	{
    31		char *p;
    32	
    33		p = vmalloc(PAGE_SIZE);
    34		if (!p)
    35			return -ENOMEM;
    36	
  > 37		insert_slb_entry((unsigned long)p, MMU_SEGSIZE_1T, mmu_vmalloc_psize);
    38		/*
    39		 * This triggers exception, If handled correctly we must recover
    40		 * from this error.
    41		 */
    42		p[0] = '!';
    43		vfree(p);
    44		return 0;
    45	}
    46	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: .config.gz
Type: application/gzip
Size: 39304 bytes
Desc: not available
URL: <http://lists.ozlabs.org/pipermail/linuxppc-dev/attachments/20201203/3629249f/attachment-0001.gz>


More information about the Linuxppc-dev mailing list