diff options
Diffstat (limited to 'sys/arch/amd64')
-rw-r--r-- | sys/arch/amd64/amd64/acpi_machdep.c | 4 | ||||
-rw-r--r-- | sys/arch/amd64/amd64/machdep.c | 6 |
2 files changed, 8 insertions, 2 deletions
diff --git a/sys/arch/amd64/amd64/acpi_machdep.c b/sys/arch/amd64/amd64/acpi_machdep.c index f061a7296d7..ab7d11fa168 100644 --- a/sys/arch/amd64/amd64/acpi_machdep.c +++ b/sys/arch/amd64/amd64/acpi_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: acpi_machdep.c,v 1.9 2007/11/16 02:45:56 deraadt Exp $ */ +/* $OpenBSD: acpi_machdep.c,v 1.10 2007/11/25 09:11:12 jsg Exp $ */ /* * Copyright (c) 2005 Thorsten Lockert <tholo@sigmasoft.com> * @@ -152,6 +152,8 @@ havebase: void acpi_attach_machdep(struct acpi_softc *sc) { + extern void (*cpuresetfn)(void); sc->sc_interrupt = isa_intr_establish(NULL, sc->sc_fadt->sci_int, IST_LEVEL, IPL_TTY, acpi_interrupt, sc, sc->sc_dev.dv_xname); + cpuresetfn = acpi_reset; } diff --git a/sys/arch/amd64/amd64/machdep.c b/sys/arch/amd64/amd64/machdep.c index 3c8e1028a75..2acbc3a9671 100644 --- a/sys/arch/amd64/amd64/machdep.c +++ b/sys/arch/amd64/amd64/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.65 2007/11/03 22:23:35 mikeb Exp $ */ +/* $OpenBSD: machdep.c,v 1.66 2007/11/25 09:11:12 jsg Exp $ */ /* $NetBSD: machdep.c,v 1.3 2003/05/07 22:58:18 fvdl Exp $ */ /*- @@ -255,6 +255,7 @@ int cpu_dumpsize(void); u_long cpu_dump_mempagecnt(void); void dumpsys(void); void init_x86_64(paddr_t); +void (*cpuresetfn)(void); #ifdef KGDB #ifndef KGDB_DEVNAME @@ -1607,6 +1608,9 @@ cpu_reset(void) disable_intr(); + if (cpuresetfn) + (*cpuresetfn)(); + /* * The keyboard controller has 4 random output pins, one of which is * connected to the RESET pin on the CPU in many PCs. We tell the |