svn commit: r304262 - in stable/10/sys: amd64/amd64 i386/i386
Konstantin Belousov
kib at FreeBSD.org
Wed Aug 17 07:09:24 UTC 2016
Author: kib
Date: Wed Aug 17 07:09:22 2016
New Revision: 304262
URL: https://svnweb.freebsd.org/changeset/base/304262
Log:
MFC r303913:
Unconditionally perform checks that FPU region was entered, when #NM
exception is caught in kernel mode.
Modified:
stable/10/sys/amd64/amd64/trap.c
stable/10/sys/i386/i386/trap.c
Directory Properties:
stable/10/ (props changed)
Modified: stable/10/sys/amd64/amd64/trap.c
==============================================================================
--- stable/10/sys/amd64/amd64/trap.c Wed Aug 17 07:07:29 2016 (r304261)
+++ stable/10/sys/amd64/amd64/trap.c Wed Aug 17 07:09:22 2016 (r304262)
@@ -448,8 +448,8 @@ trap(struct trapframe *frame)
goto out;
case T_DNA:
- KASSERT(!PCB_USER_FPU(td->td_pcb),
- ("Unregistered use of FPU in kernel"));
+ if (PCB_USER_FPU(td->td_pcb))
+ panic("Unregistered use of FPU in kernel");
fpudna();
goto out;
Modified: stable/10/sys/i386/i386/trap.c
==============================================================================
--- stable/10/sys/i386/i386/trap.c Wed Aug 17 07:07:29 2016 (r304261)
+++ stable/10/sys/i386/i386/trap.c Wed Aug 17 07:09:22 2016 (r304262)
@@ -534,8 +534,8 @@ trap(struct trapframe *frame)
case T_DNA:
#ifdef DEV_NPX
- KASSERT(!PCB_USER_FPU(td->td_pcb),
- ("Unregistered use of FPU in kernel"));
+ if (PCB_USER_FPU(td->td_pcb))
+ panic("Unregistered use of FPU in kernel");
if (npxdna())
goto out;
#endif
More information about the svn-src-stable
mailing list