[PATCH v5 03/21] powerpc: Change calling convention for create_branch() et. al.

kbuild test robot lkp at intel.com
Mon Apr 6 20:25:42 AEST 2020


Hi Jordan,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on v5.6]
[also build test ERROR on next-20200406]
[cannot apply to powerpc/next kvm-ppc/kvm-ppc-next scottwood/next]
[if your patch is applied to the wrong git tree, please drop us a note to help
improve the system. BTW, we also suggest to use '--base' option to specify the
base tree in git format-patch, please see https://stackoverflow.com/a/37406982]

url:    https://github.com/0day-ci/linux/commits/Jordan-Niethe/Initial-Prefixed-Instruction-support/20200406-165215
base:    7111951b8d4973bda27ff663f2cf18b663d15b48
config: powerpc-allnoconfig (attached as .config)
compiler: powerpc-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
        # save the attached .config to linux build tree
        GCC_VERSION=9.3.0 make.cross ARCH=powerpc 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kbuild test robot <lkp at intel.com>

All errors (new ones prefixed by >>):

   arch/powerpc/kernel/setup_32.c: In function 'machine_init':
>> arch/powerpc/kernel/setup_32.c:91:21: error: passing argument 1 of 'create_cond_branch' from incompatible pointer type [-Werror=incompatible-pointer-types]
      91 |  create_cond_branch(&insn, addr, branch_target(addr), 0x820000);
         |                     ^~~~~
         |                     |
         |                     long unsigned int *
   In file included from arch/powerpc/kernel/setup_32.c:42:
   arch/powerpc/include/asm/code-patching.h:27:38: note: expected 'unsigned int *' but argument is of type 'long unsigned int *'
      27 | int create_cond_branch(unsigned int *instr, const unsigned int *addr,
         |                        ~~~~~~~~~~~~~~^~~~~
   cc1: all warnings being treated as errors

vim +/create_cond_branch +91 arch/powerpc/kernel/setup_32.c

    67	
    68	/*
    69	 * This is run before start_kernel(), the kernel has been relocated
    70	 * and we are running with enough of the MMU enabled to have our
    71	 * proper kernel virtual addresses
    72	 *
    73	 * We do the initial parsing of the flat device-tree and prepares
    74	 * for the MMU to be fully initialized.
    75	 */
    76	notrace void __init machine_init(u64 dt_ptr)
    77	{
    78		unsigned int *addr = (unsigned int *)patch_site_addr(&patch__memset_nocache);
    79		unsigned long insn;
    80	
    81		/* Configure static keys first, now that we're relocated. */
    82		setup_feature_keys();
    83	
    84		early_ioremap_setup();
    85	
    86		/* Enable early debugging if any specified (see udbg.h) */
    87		udbg_early_init();
    88	
    89		patch_instruction_site(&patch__memcpy_nocache, PPC_INST_NOP);
    90	
  > 91		create_cond_branch(&insn, addr, branch_target(addr), 0x820000);
    92		patch_instruction(addr, insn);	/* replace b by bne cr0 */
    93	
    94		/* Do some early initialization based on the flat device tree */
    95		early_init_devtree(__va(dt_ptr));
    96	
    97		early_init_mmu();
    98	
    99		setup_kdump_trampoline();
   100	}
   101	

---
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: 6411 bytes
Desc: not available
URL: <http://lists.ozlabs.org/pipermail/linuxppc-dev/attachments/20200406/f6e94fc4/attachment-0001.gz>


More information about the Linuxppc-dev mailing list