summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWarner Losh <imp@FreeBSD.org>2017-02-25 06:11:59 +0000
committerWarner Losh <imp@FreeBSD.org>2017-02-25 06:11:59 +0000
commit28586889c23b86d81983c35c5754f55f0f4b877d (patch)
tree48b0904786141ce064bfe59fa128c875b7561884
parent8a1926c5c1691c2d1ff5a31b3843aa2e50588016 (diff)
Notes
-rw-r--r--sys/arm/mv/mv_pci.c2
-rw-r--r--sys/arm/nvidia/tegra_pcie.c1
-rw-r--r--sys/arm/versatile/versatile_pci.c1
-rw-r--r--sys/arm/xscale/i8134x/i81342_pci.c1
-rw-r--r--sys/arm/xscale/ixp425/ixp425_pci.c1
-rw-r--r--sys/dev/acpica/acpi_pcib_acpi.c60
-rw-r--r--sys/dev/hyperv/pcib/vmbus_pcib.c1
-rw-r--r--sys/dev/ofw/ofwpci.c1
-rw-r--r--sys/dev/pci/pci_host_generic_fdt.c1
-rw-r--r--sys/dev/pci/pci_pci.c30
-rw-r--r--sys/dev/pci/pcib_private.h1
-rw-r--r--sys/dev/xen/pcifront/pcifront.c1
-rw-r--r--sys/mips/adm5120/admpci.c1
-rw-r--r--sys/mips/atheros/ar71xx_pci.c1
-rw-r--r--sys/mips/atheros/ar724x_pci.c1
-rw-r--r--sys/mips/atheros/qca955x_pci.c1
-rw-r--r--sys/mips/cavium/octopci.c1
-rw-r--r--sys/mips/idt/idtpci.c1
-rw-r--r--sys/mips/malta/gt_pci.c1
-rw-r--r--sys/mips/mediatek/mtk_pcie.c1
-rw-r--r--sys/mips/nlm/xlp_pci.c1
-rw-r--r--sys/mips/rmi/xlr_pci.c1
-rw-r--r--sys/mips/rt305x/rt305x_pci.c1
-rw-r--r--sys/mips/sibyte/sb_zbpci.c1
-rw-r--r--sys/powerpc/ofw/ofw_pcib_pci.c1
-rw-r--r--sys/powerpc/powermac/cpcht.c1
-rw-r--r--sys/sparc64/pci/apb.c1
-rw-r--r--sys/sparc64/pci/fire.c1
-rw-r--r--sys/sparc64/pci/ofw_pcib.c1
-rw-r--r--sys/sparc64/pci/psycho.c1
-rw-r--r--sys/sparc64/pci/schizo.c1
-rw-r--r--sys/x86/pci/pci_bus.c1
32 files changed, 100 insertions, 21 deletions
diff --git a/sys/arm/mv/mv_pci.c b/sys/arm/mv/mv_pci.c
index b4e59f11cff5..56be077c08b4 100644
--- a/sys/arm/mv/mv_pci.c
+++ b/sys/arm/mv/mv_pci.c
@@ -368,7 +368,7 @@ static device_method_t mv_pcib_methods[] = {
DEVMETHOD(pcib_read_config, mv_pcib_read_config),
DEVMETHOD(pcib_write_config, mv_pcib_write_config),
DEVMETHOD(pcib_route_interrupt, mv_pcib_route_interrupt),
-
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
#if defined(SOC_MV_ARMADAXP)
DEVMETHOD(pcib_alloc_msi, mv_pcib_alloc_msi),
DEVMETHOD(pcib_release_msi, mv_pcib_release_msi),
diff --git a/sys/arm/nvidia/tegra_pcie.c b/sys/arm/nvidia/tegra_pcie.c
index e62f35308e41..f975208228aa 100644
--- a/sys/arm/nvidia/tegra_pcie.c
+++ b/sys/arm/nvidia/tegra_pcie.c
@@ -1601,6 +1601,7 @@ static device_method_t tegra_pcib_methods[] = {
DEVMETHOD(pcib_alloc_msi, tegra_pcib_alloc_msi),
DEVMETHOD(pcib_release_msi, tegra_pcib_release_msi),
DEVMETHOD(pcib_map_msi, tegra_pcib_map_msi),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
#ifdef TEGRA_PCIB_MSI_ENABLE
/* MSI/MSI-X */
diff --git a/sys/arm/versatile/versatile_pci.c b/sys/arm/versatile/versatile_pci.c
index 7db737cc0677..96684c73198a 100644
--- a/sys/arm/versatile/versatile_pci.c
+++ b/sys/arm/versatile/versatile_pci.c
@@ -505,6 +505,7 @@ static device_method_t versatile_pci_methods[] = {
DEVMETHOD(pcib_read_config, versatile_pci_read_config),
DEVMETHOD(pcib_write_config, versatile_pci_write_config),
DEVMETHOD(pcib_route_interrupt, versatile_pci_route_interrupt),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
DEVMETHOD_END
};
diff --git a/sys/arm/xscale/i8134x/i81342_pci.c b/sys/arm/xscale/i8134x/i81342_pci.c
index 32716a93acda..f0ff737b6e1b 100644
--- a/sys/arm/xscale/i8134x/i81342_pci.c
+++ b/sys/arm/xscale/i8134x/i81342_pci.c
@@ -529,6 +529,7 @@ static device_method_t i81342_pci_methods[] = {
DEVMETHOD(pcib_read_config, i81342_pci_read_config),
DEVMETHOD(pcib_write_config, i81342_pci_write_config),
DEVMETHOD(pcib_route_interrupt, i81342_pci_route_interrupt),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
DEVMETHOD_END
};
diff --git a/sys/arm/xscale/ixp425/ixp425_pci.c b/sys/arm/xscale/ixp425/ixp425_pci.c
index d9878783b40e..6822d124f5fd 100644
--- a/sys/arm/xscale/ixp425/ixp425_pci.c
+++ b/sys/arm/xscale/ixp425/ixp425_pci.c
@@ -466,6 +466,7 @@ static device_method_t ixppcib_methods[] = {
DEVMETHOD(pcib_read_config, ixppcib_read_config),
DEVMETHOD(pcib_write_config, ixppcib_write_config),
DEVMETHOD(pcib_route_interrupt, ixppcib_route_interrupt),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
DEVMETHOD_END
};
diff --git a/sys/dev/acpica/acpi_pcib_acpi.c b/sys/dev/acpica/acpi_pcib_acpi.c
index 9a66336e7c62..98e3b296219e 100644
--- a/sys/dev/acpica/acpi_pcib_acpi.c
+++ b/sys/dev/acpica/acpi_pcib_acpi.c
@@ -61,6 +61,7 @@ struct acpi_hpcib_softc {
device_t ap_dev;
ACPI_HANDLE ap_handle;
int ap_flags;
+ uint32_t ap_osc_ctl;
int ap_segment; /* PCI domain */
int ap_bus; /* bios-assigned bus number */
@@ -105,6 +106,8 @@ static int acpi_pcib_acpi_release_resource(device_t dev,
struct resource *r);
#endif
#endif
+static int acpi_pcib_request_feature(device_t pcib, device_t dev,
+ enum pci_feature feature);
static device_method_t acpi_pcib_acpi_methods[] = {
/* Device interface */
@@ -145,6 +148,7 @@ static device_method_t acpi_pcib_acpi_methods[] = {
DEVMETHOD(pcib_release_msix, pcib_release_msix),
DEVMETHOD(pcib_map_msi, acpi_pcib_map_msi),
DEVMETHOD(pcib_power_for_sleep, acpi_pcib_power_for_sleep),
+ DEVMETHOD(pcib_request_feature, acpi_pcib_request_feature),
DEVMETHOD_END
};
@@ -298,8 +302,8 @@ first_decoded_bus(struct acpi_hpcib_softc *sc, rman_res_t *startp)
}
#endif
-static void
-acpi_pcib_osc(struct acpi_hpcib_softc *sc)
+static int
+acpi_pcib_osc(struct acpi_hpcib_softc *sc, uint32_t osc_ctl)
{
ACPI_STATUS status;
uint32_t cap_set[3];
@@ -317,33 +321,27 @@ acpi_pcib_osc(struct acpi_hpcib_softc *sc)
PCIM_OSC_SUPPORT_MSI;
/* Control Field */
- cap_set[PCI_OSC_CTL] = 0;
-
-#ifdef PCI_HP
- /* Control Field: PCI Express Native Hot Plug */
- cap_set[PCI_OSC_CTL] |= PCIM_OSC_CTL_PCIE_HP;
-#endif
+ sc->ap_osc_ctl |= osc_ctl;
+ cap_set[PCI_OSC_CTL] = sc->ap_osc_ctl;
status = acpi_EvaluateOSC(sc->ap_handle, pci_host_bridge_uuid, 1,
nitems(cap_set), cap_set, cap_set, false);
if (ACPI_FAILURE(status)) {
if (status == AE_NOT_FOUND)
- return;
+ return (0);
device_printf(sc->ap_dev, "_OSC failed: %s\n",
AcpiFormatException(status));
- return;
+ return (EIO);
}
- if (cap_set[PCI_OSC_STATUS] != 0) {
- device_printf(sc->ap_dev, "_OSC returned error %#x\n",
- cap_set[0]);
- }
+ if (cap_set[PCI_OSC_STATUS] == 0)
+ sc->ap_osc_ctl = cap_set[PCI_OSC_CTL];
-#ifdef PCI_HP
- if ((cap_set[PCI_OSC_CTL] & PCIM_OSC_CTL_PCIE_HP) == 0 && bootverbose) {
- device_printf(sc->ap_dev, "_OSC didn't allow HP control\n");
- }
-#endif
+ if (cap_set[PCI_OSC_STATUS] != 0 ||
+ (cap_set[PCI_OSC_CTL] & osc_ctl) != osc_ctl)
+ return (EIO);
+
+ return (0);
}
static int
@@ -372,7 +370,7 @@ acpi_pcib_acpi_attach(device_t dev)
if (!acpi_DeviceIsPresent(dev))
return (ENXIO);
- acpi_pcib_osc(sc);
+ acpi_pcib_osc(sc, 0);
/*
* Get our segment number by evaluating _SEG.
@@ -722,3 +720,25 @@ acpi_pcib_acpi_release_resource(device_t dev, device_t child, int type, int rid,
}
#endif
#endif
+
+static int
+acpi_pcib_request_feature(device_t pcib, device_t dev, enum pci_feature feature)
+{
+ uint32_t osc_ctl;
+ struct acpi_hpcib_softc *sc;
+
+ sc = device_get_softc(dev);
+
+ switch (feature) {
+ case PCI_FEATURE_HP:
+ osc_ctl = PCIM_OSC_CTL_PCIE_HP;
+ break;
+ case PCI_FEATURE_AER:
+ osc_ctl = PCIM_OSC_CTL_PCIE_AER;
+ break;
+ default:
+ return (EINVAL);
+ }
+
+ return (acpi_pcib_osc(sc, osc_ctl));
+}
diff --git a/sys/dev/hyperv/pcib/vmbus_pcib.c b/sys/dev/hyperv/pcib/vmbus_pcib.c
index 0e8170848a31..08de4abaa440 100644
--- a/sys/dev/hyperv/pcib/vmbus_pcib.c
+++ b/sys/dev/hyperv/pcib/vmbus_pcib.c
@@ -1780,6 +1780,7 @@ static device_method_t vmbus_pcib_methods[] = {
DEVMETHOD(pcib_alloc_msix, vmbus_pcib_alloc_msix),
DEVMETHOD(pcib_release_msix, vmbus_pcib_release_msix),
DEVMETHOD(pcib_map_msi, vmbus_pcib_map_msi),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
DEVMETHOD_END
};
diff --git a/sys/dev/ofw/ofwpci.c b/sys/dev/ofw/ofwpci.c
index 1daafa644cf6..7b52704b79c8 100644
--- a/sys/dev/ofw/ofwpci.c
+++ b/sys/dev/ofw/ofwpci.c
@@ -123,6 +123,7 @@ static device_method_t ofw_pci_methods[] = {
/* pcib interface */
DEVMETHOD(pcib_maxslots, ofw_pci_maxslots),
DEVMETHOD(pcib_route_interrupt, ofw_pci_route_interrupt),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
/* ofw_bus interface */
DEVMETHOD(ofw_bus_get_node, ofw_pci_get_node),
diff --git a/sys/dev/pci/pci_host_generic_fdt.c b/sys/dev/pci/pci_host_generic_fdt.c
index 3ddf2b2c4e27..82002246950c 100644
--- a/sys/dev/pci/pci_host_generic_fdt.c
+++ b/sys/dev/pci/pci_host_generic_fdt.c
@@ -618,6 +618,7 @@ static device_method_t generic_pcie_fdt_methods[] = {
DEVMETHOD(pcib_release_msix, generic_pcie_fdt_release_msix),
DEVMETHOD(pcib_map_msi, generic_pcie_fdt_map_msi),
DEVMETHOD(pcib_get_id, generic_pcie_get_id),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
/* ofw_bus interface */
DEVMETHOD(ofw_bus_get_devinfo, generic_pcie_ofw_get_devinfo),
diff --git a/sys/dev/pci/pci_pci.c b/sys/dev/pci/pci_pci.c
index ae52c08a767c..8012f1645cbc 100644
--- a/sys/dev/pci/pci_pci.c
+++ b/sys/dev/pci/pci_pci.c
@@ -960,6 +960,17 @@ pcib_probe_hotplug(struct pcib_softc *sc)
}
}
+ /*
+ * Now that we're sure we want to do hot plug, ask the
+ * firmware, if any, if that's OK.
+ */
+ if (pcib_request_feature(device_get_parent(device_get_parent(dev)), dev,
+ PCI_FEATURE_HP) != 0) {
+ if (bootverbose)
+ device_printf(dev, "Unable to activate hot plug feature.\n");
+ return;
+ }
+
sc->flags |= PCIB_HOTPLUG;
}
@@ -2833,6 +2844,25 @@ pcib_try_enable_ari(device_t pcib, device_t dev)
return (0);
}
+int
+pcib_request_feature_allow(device_t pcib, device_t dev,
+ enum pci_feature feature)
+{
+ /*
+ * No host firmwrae we have to negotiate with, so we allow
+ * every valid feature requested.
+ */
+ switch (feature) {
+ case PCI_FEATURE_AER:
+ case PCI_FEATURE_HP:
+ break;
+ default:
+ return (EINVAL);
+ }
+
+ return (0);
+}
+
/*
* Pass the request to use this PCI feature up the tree. Either there's a
* firmware like ACPI that's using this feature that will approve (or deny) the
diff --git a/sys/dev/pci/pcib_private.h b/sys/dev/pci/pcib_private.h
index 9014cff714f2..1004e1339d74 100644
--- a/sys/dev/pci/pcib_private.h
+++ b/sys/dev/pci/pcib_private.h
@@ -193,5 +193,6 @@ int pcib_get_id(device_t pcib, device_t dev, enum pci_id_type type,
uintptr_t *id);
void pcib_decode_rid(device_t pcib, uint16_t rid, int *bus,
int *slot, int *func);
+int pcib_request_feature_allow(device_t pcib, device_t dev, enum pci_feature feature);
#endif
diff --git a/sys/dev/xen/pcifront/pcifront.c b/sys/dev/xen/pcifront/pcifront.c
index 833e38bd7e2f..9d808f745094 100644
--- a/sys/dev/xen/pcifront/pcifront.c
+++ b/sys/dev/xen/pcifront/pcifront.c
@@ -668,6 +668,7 @@ static device_method_t xpcib_methods[] = {
DEVMETHOD(pcib_read_config, xpcib_read_config),
DEVMETHOD(pcib_write_config, xpcib_write_config),
DEVMETHOD(pcib_route_interrupt, xpcib_route_interrupt),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
DEVMETHOD_END
};
diff --git a/sys/mips/adm5120/admpci.c b/sys/mips/adm5120/admpci.c
index 0fb0b54ca5cd..02f72b225c34 100644
--- a/sys/mips/adm5120/admpci.c
+++ b/sys/mips/adm5120/admpci.c
@@ -486,6 +486,7 @@ static device_method_t admpci_methods[] = {
DEVMETHOD(pcib_read_config, admpci_read_config),
DEVMETHOD(pcib_write_config, admpci_write_config),
DEVMETHOD(pcib_route_interrupt, admpci_route_interrupt),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
DEVMETHOD_END
};
diff --git a/sys/mips/atheros/ar71xx_pci.c b/sys/mips/atheros/ar71xx_pci.c
index f8fc255f1aec..6a765d64ea30 100644
--- a/sys/mips/atheros/ar71xx_pci.c
+++ b/sys/mips/atheros/ar71xx_pci.c
@@ -689,6 +689,7 @@ static device_method_t ar71xx_pci_methods[] = {
DEVMETHOD(pcib_read_config, ar71xx_pci_read_config),
DEVMETHOD(pcib_write_config, ar71xx_pci_write_config),
DEVMETHOD(pcib_route_interrupt, ar71xx_pci_route_interrupt),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
DEVMETHOD_END
};
diff --git a/sys/mips/atheros/ar724x_pci.c b/sys/mips/atheros/ar724x_pci.c
index 12419d16ad02..ad1ec75d5ee0 100644
--- a/sys/mips/atheros/ar724x_pci.c
+++ b/sys/mips/atheros/ar724x_pci.c
@@ -649,6 +649,7 @@ static device_method_t ar724x_pci_methods[] = {
DEVMETHOD(pcib_read_config, ar724x_pci_read_config),
DEVMETHOD(pcib_write_config, ar724x_pci_write_config),
DEVMETHOD(pcib_route_interrupt, ar724x_pci_route_interrupt),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
DEVMETHOD_END
};
diff --git a/sys/mips/atheros/qca955x_pci.c b/sys/mips/atheros/qca955x_pci.c
index b02517d3d3ae..e736942b0e84 100644
--- a/sys/mips/atheros/qca955x_pci.c
+++ b/sys/mips/atheros/qca955x_pci.c
@@ -589,6 +589,7 @@ static device_method_t qca955x_pci_methods[] = {
DEVMETHOD(pcib_read_config, qca955x_pci_read_config),
DEVMETHOD(pcib_write_config, qca955x_pci_write_config),
DEVMETHOD(pcib_route_interrupt, qca955x_pci_route_interrupt),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
DEVMETHOD_END
};
diff --git a/sys/mips/cavium/octopci.c b/sys/mips/cavium/octopci.c
index 48ef7e150f5a..8ab21bc47731 100644
--- a/sys/mips/cavium/octopci.c
+++ b/sys/mips/cavium/octopci.c
@@ -978,6 +978,7 @@ static device_method_t octopci_methods[] = {
DEVMETHOD(pcib_read_config, octopci_read_config),
DEVMETHOD(pcib_write_config, octopci_write_config),
DEVMETHOD(pcib_route_interrupt, octopci_route_interrupt),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
DEVMETHOD_END
};
diff --git a/sys/mips/idt/idtpci.c b/sys/mips/idt/idtpci.c
index 98d199697c71..6102bd683987 100644
--- a/sys/mips/idt/idtpci.c
+++ b/sys/mips/idt/idtpci.c
@@ -541,6 +541,7 @@ static device_method_t idtpci_methods[] = {
DEVMETHOD(pcib_read_config, idtpci_read_config),
DEVMETHOD(pcib_write_config, idtpci_write_config),
DEVMETHOD(pcib_route_interrupt, idtpci_route_interrupt),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
DEVMETHOD_END
};
diff --git a/sys/mips/malta/gt_pci.c b/sys/mips/malta/gt_pci.c
index 643943d430c5..2b7842d01cfe 100644
--- a/sys/mips/malta/gt_pci.c
+++ b/sys/mips/malta/gt_pci.c
@@ -758,6 +758,7 @@ static device_method_t gt_pci_methods[] = {
DEVMETHOD(pcib_read_config, gt_pci_read_config),
DEVMETHOD(pcib_write_config, gt_pci_write_config),
DEVMETHOD(pcib_route_interrupt, gt_pci_route_interrupt),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
DEVMETHOD_END
};
diff --git a/sys/mips/mediatek/mtk_pcie.c b/sys/mips/mediatek/mtk_pcie.c
index 930c924cfb86..635fa78d87b1 100644
--- a/sys/mips/mediatek/mtk_pcie.c
+++ b/sys/mips/mediatek/mtk_pcie.c
@@ -726,6 +726,7 @@ static device_method_t mtk_pci_methods[] = {
DEVMETHOD(pcib_read_config, mtk_pci_read_config),
DEVMETHOD(pcib_write_config, mtk_pci_write_config),
DEVMETHOD(pcib_route_interrupt, mtk_pci_route_interrupt),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
/* OFW bus interface */
DEVMETHOD(ofw_bus_get_compat, ofw_bus_gen_get_compat),
diff --git a/sys/mips/nlm/xlp_pci.c b/sys/mips/nlm/xlp_pci.c
index 51ae2b746c0a..f8bd54c06d67 100644
--- a/sys/mips/nlm/xlp_pci.c
+++ b/sys/mips/nlm/xlp_pci.c
@@ -557,6 +557,7 @@ static device_method_t xlp_pcib_methods[] = {
DEVMETHOD(pcib_read_config, xlp_pcib_read_config),
DEVMETHOD(pcib_write_config, xlp_pcib_write_config),
DEVMETHOD(pcib_route_interrupt, mips_pcib_route_interrupt),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
DEVMETHOD(pcib_alloc_msi, xlp_alloc_msi),
DEVMETHOD(pcib_release_msi, xlp_release_msi),
diff --git a/sys/mips/rmi/xlr_pci.c b/sys/mips/rmi/xlr_pci.c
index 3d985039d559..8b3cfe9cd7fe 100644
--- a/sys/mips/rmi/xlr_pci.c
+++ b/sys/mips/rmi/xlr_pci.c
@@ -638,6 +638,7 @@ static device_method_t xlr_pcib_methods[] = {
DEVMETHOD(pcib_read_config, xlr_pcib_read_config),
DEVMETHOD(pcib_write_config, xlr_pcib_write_config),
DEVMETHOD(pcib_route_interrupt, mips_pci_route_interrupt),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
DEVMETHOD(pcib_alloc_msi, xlr_alloc_msi),
DEVMETHOD(pcib_release_msi, xlr_release_msi),
diff --git a/sys/mips/rt305x/rt305x_pci.c b/sys/mips/rt305x/rt305x_pci.c
index 605a83f8b241..af39ac01659d 100644
--- a/sys/mips/rt305x/rt305x_pci.c
+++ b/sys/mips/rt305x/rt305x_pci.c
@@ -481,6 +481,7 @@ static device_method_t rt305x_pci_methods[] = {
DEVMETHOD(pcib_read_config, rt305x_pci_read_config),
DEVMETHOD(pcib_write_config, rt305x_pci_write_config),
DEVMETHOD(pcib_route_interrupt, rt305x_pci_route_interrupt),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
DEVMETHOD_END
};
diff --git a/sys/mips/sibyte/sb_zbpci.c b/sys/mips/sibyte/sb_zbpci.c
index 952fea80d355..3495a59000b3 100644
--- a/sys/mips/sibyte/sb_zbpci.c
+++ b/sys/mips/sibyte/sb_zbpci.c
@@ -446,6 +446,7 @@ static device_method_t zbpci_methods[] ={
DEVMETHOD(pcib_read_config, zbpci_read_config),
DEVMETHOD(pcib_write_config, zbpci_write_config),
DEVMETHOD(pcib_route_interrupt, zbpci_route_interrupt),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
{ 0, 0 }
};
diff --git a/sys/powerpc/ofw/ofw_pcib_pci.c b/sys/powerpc/ofw/ofw_pcib_pci.c
index 8a5c81f5d805..36ae15f09fda 100644
--- a/sys/powerpc/ofw/ofw_pcib_pci.c
+++ b/sys/powerpc/ofw/ofw_pcib_pci.c
@@ -61,6 +61,7 @@ static device_method_t ofw_pcib_pci_methods[] = {
/* pcib interface */
DEVMETHOD(pcib_route_interrupt, ofw_pcib_pci_route_interrupt),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
/* ofw_bus interface */
DEVMETHOD(ofw_bus_get_node, ofw_pcib_pci_get_node),
diff --git a/sys/powerpc/powermac/cpcht.c b/sys/powerpc/powermac/cpcht.c
index 3145689f3c41..92855d82c0b0 100644
--- a/sys/powerpc/powermac/cpcht.c
+++ b/sys/powerpc/powermac/cpcht.c
@@ -103,6 +103,7 @@ static device_method_t cpcht_methods[] = {
DEVMETHOD(pcib_alloc_msix, cpcht_alloc_msix),
DEVMETHOD(pcib_release_msix, cpcht_release_msix),
DEVMETHOD(pcib_map_msi, cpcht_map_msi),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
DEVMETHOD_END
};
diff --git a/sys/sparc64/pci/apb.c b/sys/sparc64/pci/apb.c
index 55f131382c33..23435a9ef1e7 100644
--- a/sys/sparc64/pci/apb.c
+++ b/sys/sparc64/pci/apb.c
@@ -92,6 +92,7 @@ static device_method_t apb_methods[] = {
/* pcib interface */
DEVMETHOD(pcib_route_interrupt, ofw_pcib_gen_route_interrupt),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
/* ofw_bus interface */
DEVMETHOD(ofw_bus_get_node, ofw_pcib_gen_get_node),
diff --git a/sys/sparc64/pci/fire.c b/sys/sparc64/pci/fire.c
index 26925b81ac94..54cebbf419ad 100644
--- a/sys/sparc64/pci/fire.c
+++ b/sys/sparc64/pci/fire.c
@@ -152,6 +152,7 @@ static device_method_t fire_methods[] = {
DEVMETHOD(pcib_alloc_msix, fire_alloc_msix),
DEVMETHOD(pcib_release_msix, fire_release_msix),
DEVMETHOD(pcib_map_msi, fire_map_msi),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
/* ofw_bus interface */
DEVMETHOD(ofw_bus_get_node, ofw_pci_get_node),
diff --git a/sys/sparc64/pci/ofw_pcib.c b/sys/sparc64/pci/ofw_pcib.c
index 77c2c35109f7..de6ca714cb65 100644
--- a/sys/sparc64/pci/ofw_pcib.c
+++ b/sys/sparc64/pci/ofw_pcib.c
@@ -72,6 +72,7 @@ static device_method_t ofw_pcib_methods[] = {
/* pcib interface */
DEVMETHOD(pcib_route_interrupt, ofw_pcib_gen_route_interrupt),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
/* ofw_bus interface */
DEVMETHOD(ofw_bus_get_node, ofw_pcib_gen_get_node),
diff --git a/sys/sparc64/pci/psycho.c b/sys/sparc64/pci/psycho.c
index 496df96895d4..6f54594c20d3 100644
--- a/sys/sparc64/pci/psycho.c
+++ b/sys/sparc64/pci/psycho.c
@@ -141,6 +141,7 @@ static device_method_t psycho_methods[] = {
DEVMETHOD(pcib_read_config, psycho_read_config),
DEVMETHOD(pcib_write_config, psycho_write_config),
DEVMETHOD(pcib_route_interrupt, psycho_route_interrupt),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
/* ofw_bus interface */
DEVMETHOD(ofw_bus_get_node, ofw_pci_get_node),
diff --git a/sys/sparc64/pci/schizo.c b/sys/sparc64/pci/schizo.c
index a96155bd94bf..e4a745ad5fcb 100644
--- a/sys/sparc64/pci/schizo.c
+++ b/sys/sparc64/pci/schizo.c
@@ -138,6 +138,7 @@ static device_method_t schizo_methods[] = {
DEVMETHOD(pcib_read_config, schizo_read_config),
DEVMETHOD(pcib_write_config, schizo_write_config),
DEVMETHOD(pcib_route_interrupt, schizo_route_interrupt),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
/* ofw_bus interface */
DEVMETHOD(ofw_bus_get_node, ofw_pci_get_node),
diff --git a/sys/x86/pci/pci_bus.c b/sys/x86/pci/pci_bus.c
index 6a6469ec28d2..5fd1ec294c69 100644
--- a/sys/x86/pci/pci_bus.c
+++ b/sys/x86/pci/pci_bus.c
@@ -663,6 +663,7 @@ static device_method_t legacy_pcib_methods[] = {
DEVMETHOD(pcib_alloc_msix, legacy_pcib_alloc_msix),
DEVMETHOD(pcib_release_msix, pcib_release_msix),
DEVMETHOD(pcib_map_msi, legacy_pcib_map_msi),
+ DEVMETHOD(pcib_request_feature, pcib_request_feature_allow),
DEVMETHOD_END
};