tree:
https://git.kernel.org/pub/scm/linux/kernel/git/djbw/nvdimm.git libnvdimm-pending
head: bb12557751a16ec04d801b01492257f720e4718e
commit: 52fd3e3473c7cd37c07071116b7d203f277d3394 [1/5] ACPI: Store pre-mapped registers in
APEI entries
config: x86_64-allyesconfig (attached as .config)
compiler: clang version 11.0.0 (
https://github.com/llvm/llvm-project
9d4cf5bd421fb6467ff5f00e26a37527246dd4d6)
reproduce:
wget
https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O
~/bin/make.cross
chmod +x ~/bin/make.cross
# install x86_64 cross compiling tool for clang build
# apt-get install binutils-x86-64-linux-gnu
git checkout 52fd3e3473c7cd37c07071116b7d203f277d3394
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=x86_64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kbuild test robot <lkp(a)intel.com>
All error/warnings (new ones prefixed by >>, old ones prefixed by <<):
> drivers/acpi/apei/erst.c:1203:1: warning: unused label
'err_map' [-Wunused-label]
err_map:
^~~~~~~~
1 warning generated.
--
> drivers/acpi/apei/einj.c:696:15: error: expected ';'
after expression
rc = -EINVAL
^
;
> drivers/acpi/apei/einj.c:775:8: error: use of undeclared
identifier 'einj_tbl'; did you mean 'einj_tab'?
kfree(einj_tbl);
^~~~~~~~
einj_tab
drivers/acpi/apei/einj.c:104:32: note: 'einj_tab' declared here
static struct acpi_table_einj *einj_tab;
^
2 errors generated.
vim +696 drivers/acpi/apei/einj.c
668
669 static int __init einj_init(void)
670 {
671 int rc;
672 unsigned int i;
673 acpi_status status;
674 struct apei_exec_context ctx;
675 struct acpi_table_header *table;
676
677 if (acpi_disabled) {
678 pr_warn("ACPI disabled.\n");
679 return -ENODEV;
680 }
681
682 status = acpi_get_table(ACPI_SIG_EINJ, 0, &table);
683 if (status == AE_NOT_FOUND) {
684 pr_warn("EINJ table not found.\n");
685 return -ENODEV;
686 }
687 else if (ACPI_FAILURE(status)) {
688 pr_err("Failed to get EINJ table: %s\n",
689 acpi_format_exception(status));
690 return -EINVAL;
691 }
692
693 rc = einj_check_table((struct acpi_table_einj *) table);
694 if (rc) {
695 pr_warn(FW_BUG "Invalid EINJ table.\n");
696 rc = -EINVAL
697 goto err_table;
698 }
699
700 /*
701 * Create a duplicate table where the physical address resources
702 * can be replaced with virtual mappings
703 */
704 einj_tab = kmemdup(table, table->length, GFP_KERNEL);
705 if (!einj_tab)
706 goto err_table;
707
708 rc = -ENOMEM;
709 einj_debug_dir = debugfs_create_dir("einj", apei_get_debugfs_dir());
710
711 debugfs_create_file("available_error_type", S_IRUSR, einj_debug_dir,
712 NULL, &available_error_type_fops);
713 debugfs_create_file_unsafe("error_type", 0600, einj_debug_dir,
714 NULL, &error_type_fops);
715 debugfs_create_file_unsafe("error_inject", 0200, einj_debug_dir,
716 NULL, &error_inject_fops);
717
718 apei_resources_init(&einj_resources);
719 einj_exec_ctx_init(&ctx);
720 rc = apei_exec_collect_resources(&ctx, &einj_resources);
721 if (rc) {
722 pr_err("Error collecting EINJ resources.\n");
723 goto err_fini;
724 }
725
726 rc = apei_resources_request(&einj_resources, "APEI EINJ");
727 if (rc) {
728 pr_err("Error requesting memory/port resources.\n");
729 goto err_fini;
730 }
731
732 rc = apei_exec_pre_map_gars(&ctx);
733 if (rc) {
734 pr_err("Error pre-mapping GARs.\n");
735 goto err_release;
736 }
737
738 rc = -ENOMEM;
739 einj_param = einj_get_parameter_address();
740 if ((param_extension || acpi5) && einj_param) {
741 debugfs_create_x32("flags", S_IRUSR | S_IWUSR, einj_debug_dir,
742 &error_flags);
743 debugfs_create_x64("param1", S_IRUSR | S_IWUSR, einj_debug_dir,
744 &error_param1);
745 debugfs_create_x64("param2", S_IRUSR | S_IWUSR, einj_debug_dir,
746 &error_param2);
747 debugfs_create_x64("param3", S_IRUSR | S_IWUSR, einj_debug_dir,
748 &error_param3);
749 debugfs_create_x64("param4", S_IRUSR | S_IWUSR, einj_debug_dir,
750 &error_param4);
751 debugfs_create_x32("notrigger", S_IRUSR | S_IWUSR,
752 einj_debug_dir, ¬rigger);
753 }
754
755 if (vendor_dev[0]) {
756 vendor_blob.data = vendor_dev;
757 vendor_blob.size = strlen(vendor_dev);
758 debugfs_create_blob("vendor", S_IRUSR, einj_debug_dir,
759 &vendor_blob);
760 debugfs_create_x32("vendor_flags", S_IRUSR | S_IWUSR,
761 einj_debug_dir, &vendor_flags);
762 }
763
764 pr_info("Error INJection is initialized.\n");
765 acpi_put_table(table);
766
767 return 0;
768
769 err_release:
770 apei_resources_release(&einj_resources);
771 err_fini:
772 apei_resources_fini(&einj_resources);
773 debugfs_remove_recursive(einj_debug_dir);
774 err_map:
775 kfree(einj_tbl);
776 err_table:
777 acpi_put_table(table);
778
779 return rc;
780 }
781
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org