diff options
author | 2019-06-08 12:25:19 +0000 | |
---|---|---|
committer | 2019-06-08 12:25:19 +0000 | |
commit | 807b044c5c2d60960996a508b479e380e775b631 (patch) | |
tree | c02a703f8cfc891b7ea52d6f5d581c3a7c521477 | |
parent | Delete the display of the RSA_METHOD object (diff) | |
download | wireguard-openbsd-807b044c5c2d60960996a508b479e380e775b631.tar.xz wireguard-openbsd-807b044c5c2d60960996a508b479e380e775b631.zip |
When establishing the mapping between ACPI device nodes and PCI devices,
skip PCI host bridges and devices that aren't there.
ok patrick@
-rw-r--r-- | sys/dev/acpi/acpi.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/sys/dev/acpi/acpi.c b/sys/dev/acpi/acpi.c index eedad9c1914..37da92c91e6 100644 --- a/sys/dev/acpi/acpi.c +++ b/sys/dev/acpi/acpi.c @@ -1,4 +1,4 @@ -/* $OpenBSD: acpi.c,v 1.368 2019/06/07 15:40:41 kettenis Exp $ */ +/* $OpenBSD: acpi.c,v 1.369 2019/06/08 12:25:19 kettenis Exp $ */ /* * Copyright (c) 2005 Thorsten Lockert <tholo@sigmasoft.com> * Copyright (c) 2005 Jordan Hargrave <jordan@openbsd.org> @@ -574,8 +574,13 @@ acpi_getpci(struct aml_node *node, void *arg) pci_chipset_tag_t pc; pcitag_t tag; uint64_t val; + int64_t sta; uint32_t reg; + sta = acpi_getsta(sc, node); + if ((sta & STA_PRESENT) == 0) + return 0; + if (!node->value || node->value->type != AML_OBJTYPE_DEVICE) return 0; if (!aml_evalhid(node, &res)) { |