mirror of
https://github.com/opnsense/src.git
synced 2026-04-28 17:49:22 -04:00
Add the proper logic so that we don't try to do SSE stuff unless its
enabled.
This commit is contained in:
parent
e201f9ecd1
commit
63590b95ec
1 changed files with 11 additions and 0 deletions
|
|
@ -35,9 +35,17 @@ __FBSDID("$FreeBSD$");
|
|||
#include <machine/md_var.h>
|
||||
#include <machine/pcb.h>
|
||||
|
||||
#if !defined(CPU_ENABLE_SSE) && defined(I686_CPU)
|
||||
#define CPU_ENABLE_SSE
|
||||
#endif
|
||||
#if defined(CPU_DISABLE_SSE)
|
||||
#undef CPU_ENABLE_SSE
|
||||
#endif
|
||||
|
||||
int
|
||||
cpu_ptrace(struct thread *td, int req, void *addr, int data)
|
||||
{
|
||||
#ifdef CPU_ENABLE_SSE
|
||||
int error;
|
||||
|
||||
if (!cpu_fxsr)
|
||||
|
|
@ -59,4 +67,7 @@ cpu_ptrace(struct thread *td, int req, void *addr, int data)
|
|||
}
|
||||
|
||||
return (error);
|
||||
#else
|
||||
return (EINVAL);
|
||||
#endif
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue