On Wed, Feb 28, 2018 at 05:50:06AM +0000, SAITOH Masanobu wrote: > Module Name: src > Committed By: msaitoh > Date: Wed Feb 28 05:50:06 UTC 2018 > > Modified Files: > src/sys/dev/acpi: acpi_mcfg.c > src/sys/dev/pci: pci_quirks.c pcivar.h > > Log Message: > - Add new PCI quirk PCI_QUIRK_HASEXTCNF and PCI_QUIRK_NOEXTCNF. Some devices' > extended configuration area may be broken or violate spec. If an extended > configuration space is strange but it really exist, use PCI_QUIRK_HASEXTCNF. > If an extended configuration space is plausible to exist but it really > doesn't exist, use PCI_QUIRK_NOEXTCNF. > - Add PCI_PRODUCT_INTEL_XEOND_MEM_0_TTR_1(0x6fa8) and > PCI_PRODUCT_INTEL_COREI76K_IMC_0(0x6f68) with PCI_QUIRK_HASEXTCNF. The > document clearly states they violate spec and it support the extended > configuration space. > >
this is causing ia64 builds to fail. they have acpi, but not pci defined. then, pci_quirks.c is not built, and we get an undefined reference: http://releng.netbsd.org/builds/HEAD/201802282130Z/ia64.build.failed acpi_mcfg.c sounds like a very pci-only thing, from commit history. the following patch makes it explicitly a pci only thing, although I haven't tried to boot it. Is this the right thing? With this change, I can build amd64 and ia64 kernels.
Index: dev/acpi/acpi.c =================================================================== RCS file: /cvsroot/src/sys/dev/acpi/acpi.c,v retrieving revision 1.265 diff -u -r1.265 acpi.c --- dev/acpi/acpi.c 23 Nov 2017 15:48:24 -0000 1.265 +++ dev/acpi/acpi.c 1 Mar 2018 04:57:44 -0000 @@ -103,6 +103,7 @@ __KERNEL_RCSID(0, "$NetBSD: acpi.c,v 1.265 2017/11/23 15:48:24 jmcneill Exp $"); #include "opt_acpi.h" +#include "opt_pci.h" #include "opt_pcifixup.h" #include <sys/param.h> @@ -487,10 +488,12 @@ */ acpi_build_tree(sc); +#ifdef NPCI /* * Probe MCFG table */ acpimcfg_probe(sc); +#endif acpi_md_callback(sc); Index: dev/acpi/files.acpi =================================================================== RCS file: /cvsroot/src/sys/dev/acpi/files.acpi,v retrieving revision 1.100 diff -u -r1.100 files.acpi --- dev/acpi/files.acpi 10 Dec 2017 16:51:30 -0000 1.100 +++ dev/acpi/files.acpi 1 Mar 2018 04:57:44 -0000 @@ -19,7 +19,7 @@ file dev/acpi/acpi.c acpi file dev/acpi/acpi_debug.c acpi file dev/acpi/acpi_i2c.c acpi -file dev/acpi/acpi_mcfg.c acpi +file dev/acpi/acpi_mcfg.c acpi & pci file dev/acpi/acpi_pci.c acpi file dev/acpi/acpi_pci_link.c acpi file dev/acpi/acpi_power.c acpi