[PATCH] powerpc/kprobes: Blacklist functions running with MMU disabled on PPC32

kbuild test robot lkp at intel.com
Sun Feb 23 02:16:44 AEDT 2020


Hi Christophe,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on powerpc/next]
[also build test ERROR on v5.6-rc2 next-20200221]
[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/Christophe-Leroy/powerpc-kprobes-Blacklist-functions-running-with-MMU-disabled-on-PPC32/20200221-040310
base:   https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git next
config: powerpc-mgcoge_defconfig (attached as .config)
compiler: powerpc-linux-gcc (GCC) 7.5.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=7.5.0 make.cross ARCH=powerpc 

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

All errors (new ones prefixed by >>):

   arch/powerpc/platforms/82xx/pq2.c:32:1: error: return type defaults to 'int' [-Werror=return-type]
    NOKPROBE_SYMBOL(pq2_restart)
    ^~~~~~~~~~~~~~~
>> arch/powerpc/platforms/82xx/pq2.c:32:1: error: function declaration isn't a prototype [-Werror=strict-prototypes]
   arch/powerpc/platforms/82xx/pq2.c: In function 'NOKPROBE_SYMBOL':
>> arch/powerpc/platforms/82xx/pq2.c:37:1: error: expected '=', ',', ';', 'asm' or '__attribute__' before '{' token
    {
    ^
   arch/powerpc/platforms/82xx/pq2.c:45:1: error: expected '=', ',', ';', 'asm' or '__attribute__' before '{' token
    {
    ^
   arch/powerpc/platforms/82xx/pq2.c:70:1: error: expected '=', ',', ';', 'asm' or '__attribute__' before '{' token
    {
    ^
>> arch/powerpc/platforms/82xx/pq2.c:77:1: error: expected '{' at end of input
    }
    ^
   arch/powerpc/platforms/82xx/pq2.c:77:1: error: control reaches end of non-void function [-Werror=return-type]
    }
    ^
   cc1: all warnings being treated as errors

vim +32 arch/powerpc/platforms/82xx/pq2.c

    20	
    21	void __noreturn pq2_restart(char *cmd)
    22	{
    23		local_irq_disable();
    24		setbits32(&cpm2_immr->im_clkrst.car_rmr, RMR_CSRE);
    25	
    26		/* Clear the ME,EE,IR & DR bits in MSR to cause checkstop */
    27		mtmsr(mfmsr() & ~(MSR_ME | MSR_EE | MSR_IR | MSR_DR));
    28		in_8(&cpm2_immr->im_clkrst.res[0]);
    29	
    30		panic("Restart failed\n");
    31	}
  > 32	NOKPROBE_SYMBOL(pq2_restart)
    33	
    34	#ifdef CONFIG_PCI
    35	static int pq2_pci_exclude_device(struct pci_controller *hose,
    36	                                  u_char bus, u8 devfn)
  > 37	{
    38		if (bus == 0 && PCI_SLOT(devfn) == 0)
    39			return PCIBIOS_DEVICE_NOT_FOUND;
    40		else
    41			return PCIBIOS_SUCCESSFUL;
    42	}
    43	
    44	static void __init pq2_pci_add_bridge(struct device_node *np)
    45	{
    46		struct pci_controller *hose;
    47		struct resource r;
    48	
    49		if (of_address_to_resource(np, 0, &r) || r.end - r.start < 0x10b)
    50			goto err;
    51	
    52		pci_add_flags(PCI_REASSIGN_ALL_BUS);
    53	
    54		hose = pcibios_alloc_controller(np);
    55		if (!hose)
    56			return;
    57	
    58		hose->dn = np;
    59	
    60		setup_indirect_pci(hose, r.start + 0x100, r.start + 0x104, 0);
    61		pci_process_bridge_OF_ranges(hose, np, 1);
    62	
    63		return;
    64	
    65	err:
    66		printk(KERN_ERR "No valid PCI reg property in device tree\n");
    67	}
    68	
    69	void __init pq2_init_pci(void)
    70	{
    71		struct device_node *np;
    72	
    73		ppc_md.pci_exclude_device = pq2_pci_exclude_device;
    74	
    75		for_each_compatible_node(np, NULL, "fsl,pq2-pci")
    76			pq2_pci_add_bridge(np);
  > 77	}

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


More information about the Linuxppc-dev mailing list