Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev/acpi The MCFG base address field is the physical add...
details: https://anonhg.NetBSD.org/src/rev/fc64e46e3251
branches: trunk
changeset: 464609:fc64e46e3251
user: jmcneill <jmcneill%NetBSD.org@localhost>
date: Mon Oct 14 00:15:13 2019 +0000
description:
The MCFG base address field is the physical address of the base of mmio
space relative to bus 0, not the start bus number specified in the table
entry.
diffstat:
sys/dev/acpi/acpi_mcfg.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
diffs (36 lines):
diff -r bbb6e497aae8 -r fc64e46e3251 sys/dev/acpi/acpi_mcfg.c
--- a/sys/dev/acpi/acpi_mcfg.c Sun Oct 13 22:32:09 2019 +0000
+++ b/sys/dev/acpi/acpi_mcfg.c Mon Oct 14 00:15:13 2019 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: acpi_mcfg.c,v 1.16 2018/12/20 19:16:17 jmcneill Exp $ */
+/* $NetBSD: acpi_mcfg.c,v 1.17 2019/10/14 00:15:13 jmcneill Exp $ */
/*-
* Copyright (C) 2015 NONAKA Kimihiro <nonaka%NetBSD.org@localhost>
@@ -28,7 +28,7 @@
#include "opt_pci.h"
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: acpi_mcfg.c,v 1.16 2018/12/20 19:16:17 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: acpi_mcfg.c,v 1.17 2019/10/14 00:15:13 jmcneill Exp $");
#include <sys/param.h>
#include <sys/device.h>
@@ -575,7 +575,7 @@
return 0;
mb = &seg->ms_bus[boff];
- baddr = seg->ms_address + (boff * ACPIMCFG_SIZE_PER_BUS);
+ baddr = seg->ms_address + (bus * ACPIMCFG_SIZE_PER_BUS);
/* Map extended configration space of all dev/func. */
error = bus_space_map(seg->ms_bst, baddr, ACPIMCFG_SIZE_PER_BUS, 0,
@@ -832,7 +832,7 @@
for (b = seg->ms_bus_start; b <= seg->ms_bus_end; b++) {
boff = b - seg->ms_bus_start;
mb = &seg->ms_bus[boff];
- baddr = seg->ms_address + (boff * ACPIMCFG_SIZE_PER_BUS);
+ baddr = seg->ms_address + (b * ACPIMCFG_SIZE_PER_BUS);
/* Map extended configration space of all dev/func. */
error = bus_space_map(seg->ms_bst, baddr, ACPIMCFG_SIZE_PER_BUS, 0,
Home |
Main Index |
Thread Index |
Old Index