HomeFreeBSD

Fix for mis-interpretation of PCB_KERNFPU.

Description

Fix for mis-interpretation of PCB_KERNFPU.

RIght now PCB_KERNFPU is used both as indication that kernel prepared
hardware FPU context to use and that the thread is fpu-kern
thread. This also breaks fpu_kern_enter(FPU_KERN_NOCTX), since
fpu_kern_leave() then clears PCB_KERNFPU.

Introduce new flag PCB_KERNFPU_THR which indicates that the thread is
fpu-kern. Do not clear PCB_KERNFPU if fpu-kern thread leaves noctx
fpu region.

Reported and tested by: jhb (amd64)
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D25511

Details

Provenance
kibAuthored on
Differential Revision
D25511: Fix for mis-interpretation of PCB_KERNFPU.
Parents
rS366712: Limit workaround for errata E400 to appropriate AMD cpus.
Branches
Unknown
Tags
Unknown