Fix ACPI suspend/resume on amd64, which was broken since r208833.
We need actual storage for FPU state to save and restore.
This commit is contained in:
parent
9ee2165f5d
commit
c977e11721
@ -245,7 +245,7 @@ acpi_sleep_machdep(struct acpi_softc *sc, int state)
|
||||
cr3 = rcr3();
|
||||
load_cr3(KPML4phys);
|
||||
|
||||
stopfpu = stopxpcbs[0]->xpcb_pcb.pcb_save;
|
||||
stopfpu = &stopxpcbs[0]->xpcb_pcb.pcb_user_save;
|
||||
if (acpi_savecpu(stopxpcbs[0])) {
|
||||
fpugetregs(curthread, stopfpu);
|
||||
|
||||
|
@ -1247,7 +1247,7 @@ cpususpend_handler(void)
|
||||
|
||||
rf = intr_disable();
|
||||
cr3 = rcr3();
|
||||
stopfpu = stopxpcbs[cpu]->xpcb_pcb.pcb_save;
|
||||
stopfpu = &stopxpcbs[cpu]->xpcb_pcb.pcb_user_save;
|
||||
if (savectx2(stopxpcbs[cpu])) {
|
||||
fpugetregs(curthread, stopfpu);
|
||||
wbinvd();
|
||||
|
Loading…
Reference in New Issue
Block a user