Re: [PATCHv2 01/12] acpi: Create subtable parsing infrastructure

From: kbuild test robot
Date: Thu Dec 13 2018 - 04:06:45 EST


Hi Keith,

I love your patch! Yet something to improve:

[auto build test ERROR on pm/linux-next]
[also build test ERROR on v4.20-rc6]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url: https://github.com/0day-ci/linux/commits/Keith-Busch/acpi-Create-subtable-parsing-infrastructure/20181211-154110
base: https://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git linux-next
config: ia64-allnoconfig (attached as .config)
compiler: ia64-linux-gcc (GCC) 8.1.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=8.1.0 make.cross ARCH=ia64

All errors (new ones prefixed by >>):

arch/ia64/kernel/acpi.c: In function 'early_acpi_boot_init':
>> arch/ia64/kernel/acpi.c:675:3: error: passing argument 2 of 'acpi_table_parse_madt' from incompatible pointer type [-Werror=incompatible-pointer-types]
acpi_parse_lsapic, NR_CPUS);
^~~~~~~~~~~~~~~~~
In file included from arch/ia64/kernel/acpi.c:43:
include/linux/acpi.h:250:29: note: expected 'acpi_tbl_entry_handler' {aka 'int (*)(union acpi_subtable_headers *, const long unsigned int)'} but argument is of type 'int (*)(struct acpi_subtable_header *, const long unsigned int)'
acpi_tbl_entry_handler handler,
~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
arch/ia64/kernel/acpi.c: In function 'acpi_boot_init':
arch/ia64/kernel/acpi.c:718:43: error: passing argument 2 of 'acpi_table_parse_madt' from incompatible pointer type [-Werror=incompatible-pointer-types]
(ACPI_MADT_TYPE_LOCAL_APIC_OVERRIDE, acpi_parse_lapic_addr_ovr, 0) < 0)
^~~~~~~~~~~~~~~~~~~~~~~~~
In file included from arch/ia64/kernel/acpi.c:43:
include/linux/acpi.h:250:29: note: expected 'acpi_tbl_entry_handler' {aka 'int (*)(union acpi_subtable_headers *, const long unsigned int)'} but argument is of type 'int (*)(struct acpi_subtable_header *, const long unsigned int)'
acpi_tbl_entry_handler handler,
~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
arch/ia64/kernel/acpi.c:722:59: error: passing argument 2 of 'acpi_table_parse_madt' from incompatible pointer type [-Werror=incompatible-pointer-types]
if (acpi_table_parse_madt(ACPI_MADT_TYPE_LOCAL_APIC_NMI, acpi_parse_lapic_nmi, 0)
^~~~~~~~~~~~~~~~~~~~
In file included from arch/ia64/kernel/acpi.c:43:
include/linux/acpi.h:250:29: note: expected 'acpi_tbl_entry_handler' {aka 'int (*)(union acpi_subtable_headers *, const long unsigned int)'} but argument is of type 'int (*)(struct acpi_subtable_header *, const long unsigned int)'
acpi_tbl_entry_handler handler,
~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
arch/ia64/kernel/acpi.c:729:32: error: passing argument 2 of 'acpi_table_parse_madt' from incompatible pointer type [-Werror=incompatible-pointer-types]
(ACPI_MADT_TYPE_IO_SAPIC, acpi_parse_iosapic, NR_IOSAPICS) < 1) {
^~~~~~~~~~~~~~~~~~
In file included from arch/ia64/kernel/acpi.c:43:
include/linux/acpi.h:250:29: note: expected 'acpi_tbl_entry_handler' {aka 'int (*)(union acpi_subtable_headers *, const long unsigned int)'} but argument is of type 'int (*)(struct acpi_subtable_header *, const long unsigned int)'
acpi_tbl_entry_handler handler,
~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
arch/ia64/kernel/acpi.c:738:40: error: passing argument 2 of 'acpi_table_parse_madt' from incompatible pointer type [-Werror=incompatible-pointer-types]
(ACPI_MADT_TYPE_INTERRUPT_SOURCE, acpi_parse_plat_int_src,
^~~~~~~~~~~~~~~~~~~~~~~
In file included from arch/ia64/kernel/acpi.c:43:
include/linux/acpi.h:250:29: note: expected 'acpi_tbl_entry_handler' {aka 'int (*)(union acpi_subtable_headers *, const long unsigned int)'} but argument is of type 'int (*)(struct acpi_subtable_header *, const long unsigned int)'
acpi_tbl_entry_handler handler,
~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
arch/ia64/kernel/acpi.c:744:42: error: passing argument 2 of 'acpi_table_parse_madt' from incompatible pointer type [-Werror=incompatible-pointer-types]
(ACPI_MADT_TYPE_INTERRUPT_OVERRIDE, acpi_parse_int_src_ovr, 0) < 0)
^~~~~~~~~~~~~~~~~~~~~~
In file included from arch/ia64/kernel/acpi.c:43:
include/linux/acpi.h:250:29: note: expected 'acpi_tbl_entry_handler' {aka 'int (*)(union acpi_subtable_headers *, const long unsigned int)'} but argument is of type 'int (*)(struct acpi_subtable_header *, const long unsigned int)'
acpi_tbl_entry_handler handler,
~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
arch/ia64/kernel/acpi.c:748:55: error: passing argument 2 of 'acpi_table_parse_madt' from incompatible pointer type [-Werror=incompatible-pointer-types]
if (acpi_table_parse_madt(ACPI_MADT_TYPE_NMI_SOURCE, acpi_parse_nmi_src, 0) < 0)
^~~~~~~~~~~~~~~~~~
In file included from arch/ia64/kernel/acpi.c:43:
include/linux/acpi.h:250:29: note: expected 'acpi_tbl_entry_handler' {aka 'int (*)(union acpi_subtable_headers *, const long unsigned int)'} but argument is of type 'int (*)(struct acpi_subtable_header *, const long unsigned int)'
acpi_tbl_entry_handler handler,
~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
cc1: some warnings being treated as errors

vim +/acpi_table_parse_madt +675 arch/ia64/kernel/acpi.c

^1da177e4 Linus Torvalds 2005-04-16 660
62ee0540f Doug Chapman 2008-11-05 661 int __init early_acpi_boot_init(void)
62ee0540f Doug Chapman 2008-11-05 662 {
62ee0540f Doug Chapman 2008-11-05 663 int ret;
62ee0540f Doug Chapman 2008-11-05 664
62ee0540f Doug Chapman 2008-11-05 665 /*
62ee0540f Doug Chapman 2008-11-05 666 * do a partial walk of MADT to determine how many CPUs
62ee0540f Doug Chapman 2008-11-05 667 * we have including offline CPUs
62ee0540f Doug Chapman 2008-11-05 668 */
62ee0540f Doug Chapman 2008-11-05 669 if (acpi_table_parse(ACPI_SIG_MADT, acpi_parse_madt)) {
62ee0540f Doug Chapman 2008-11-05 670 printk(KERN_ERR PREFIX "Can't find MADT\n");
62ee0540f Doug Chapman 2008-11-05 671 return 0;
62ee0540f Doug Chapman 2008-11-05 672 }
62ee0540f Doug Chapman 2008-11-05 673
62ee0540f Doug Chapman 2008-11-05 674 ret = acpi_table_parse_madt(ACPI_MADT_TYPE_LOCAL_SAPIC,
62ee0540f Doug Chapman 2008-11-05 @675 acpi_parse_lsapic, NR_CPUS);
62ee0540f Doug Chapman 2008-11-05 676 if (ret < 1)
62ee0540f Doug Chapman 2008-11-05 677 printk(KERN_ERR PREFIX
62ee0540f Doug Chapman 2008-11-05 678 "Error parsing MADT - no LAPIC entries\n");
247dba58a Baoquan He 2014-05-05 679 else
247dba58a Baoquan He 2014-05-05 680 acpi_lapic = 1;
62ee0540f Doug Chapman 2008-11-05 681

:::::: The code at line 675 was first introduced by commit
:::::: 62ee0540f5e5a804b79cae8b3c0185a85f02436b [IA64] fix boot panic caused by offline CPUs

:::::: TO: Doug Chapman <doug.chapman@xxxxxx>
:::::: CC: Tony Luck <tony.luck@xxxxxxxxx>

---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation

Attachment: .config.gz
Description: application/gzip