Module Name: src Committed By: jmcneill Date: Fri Oct 19 14:06:13 UTC 2018
Modified Files: src/sys/dev/acpi: acpi_mcfg.c Log Message: Fix table offset when walking MCFG allocation subtables To generate a diff of this commit: cvs rdiff -u -r1.10 -r1.11 src/sys/dev/acpi/acpi_mcfg.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/dev/acpi/acpi_mcfg.c diff -u src/sys/dev/acpi/acpi_mcfg.c:1.10 src/sys/dev/acpi/acpi_mcfg.c:1.11 --- src/sys/dev/acpi/acpi_mcfg.c:1.10 Wed Oct 17 01:16:23 2018 +++ src/sys/dev/acpi/acpi_mcfg.c Fri Oct 19 14:06:13 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: acpi_mcfg.c,v 1.10 2018/10/17 01:16:23 jmcneill Exp $ */ +/* $NetBSD: acpi_mcfg.c,v 1.11 2018/10/19 14:06:13 jmcneill Exp $ */ /*- * Copyright (C) 2015 NONAKA Kimihiro <non...@netbsd.org> @@ -28,7 +28,7 @@ #include "opt_pci.h" #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: acpi_mcfg.c,v 1.10 2018/10/17 01:16:23 jmcneill Exp $"); +__KERNEL_RCSID(0, "$NetBSD: acpi_mcfg.c,v 1.11 2018/10/19 14:06:13 jmcneill Exp $"); #include <sys/param.h> #include <sys/device.h> @@ -304,7 +304,7 @@ acpimcfg_probe(struct acpi_softc *sc) ama->Address); nsegs++; offset += sizeof(ACPI_MCFG_ALLOCATION); - ama = ACPI_ADD_PTR(ACPI_MCFG_ALLOCATION, ama, offset); + ama = ACPI_ADD_PTR(ACPI_MCFG_ALLOCATION, mcfg, offset); } if (nsegs == 0) { mcfg = NULL; @@ -413,7 +413,7 @@ acpimcfg_init(bus_space_tag_t memt, cons next: offset += sizeof(ACPI_MCFG_ALLOCATION); - ama = ACPI_ADD_PTR(ACPI_MCFG_ALLOCATION, ama, offset); + ama = ACPI_ADD_PTR(ACPI_MCFG_ALLOCATION, mcfg, offset); } if (nsegs == 0) return ENOENT;