Changeset View
Changeset View
Standalone View
Standalone View
sys/amd64/include/fpu.h
Show First 20 Lines • Show All 41 Lines • ▼ Show 20 Lines | |||||
#ifndef _MACHINE_FPU_H_ | #ifndef _MACHINE_FPU_H_ | ||||
#define _MACHINE_FPU_H_ | #define _MACHINE_FPU_H_ | ||||
#include <x86/fpu.h> | #include <x86/fpu.h> | ||||
#ifdef _KERNEL | #ifdef _KERNEL | ||||
struct domainset; | |||||
struct fpu_kern_ctx; | struct fpu_kern_ctx; | ||||
#define PCB_USER_FPU(pcb) (((pcb)->pcb_flags & PCB_KERNFPU) == 0) | #define PCB_USER_FPU(pcb) (((pcb)->pcb_flags & PCB_KERNFPU) == 0) | ||||
#define XSAVE_AREA_ALIGN 64 | #define XSAVE_AREA_ALIGN 64 | ||||
void fpudna(void); | void fpudna(void); | ||||
void fpudrop(void); | void fpudrop(void); | ||||
void fpuexit(struct thread *td); | void fpuexit(struct thread *td); | ||||
int fpuformat(void); | int fpuformat(void); | ||||
int fpugetregs(struct thread *td); | int fpugetregs(struct thread *td); | ||||
void fpuinit(void); | void fpuinit(void); | ||||
void fpurestore(void *addr); | void fpurestore(void *addr); | ||||
void fpuresume(void *addr); | void fpuresume(void *addr); | ||||
void fpusave(void *addr); | void fpusave(void *addr); | ||||
int fpusetregs(struct thread *td, struct savefpu *addr, | int fpusetregs(struct thread *td, struct savefpu *addr, | ||||
char *xfpustate, size_t xfpustate_size); | char *xfpustate, size_t xfpustate_size); | ||||
int fpusetxstate(struct thread *td, char *xfpustate, | int fpusetxstate(struct thread *td, char *xfpustate, | ||||
size_t xfpustate_size); | size_t xfpustate_size); | ||||
void fpususpend(void *addr); | void fpususpend(void *addr); | ||||
int fputrap_sse(void); | int fputrap_sse(void); | ||||
int fputrap_x87(void); | int fputrap_x87(void); | ||||
void fpuuserinited(struct thread *td); | void fpuuserinited(struct thread *td); | ||||
struct fpu_kern_ctx *fpu_kern_alloc_ctx(u_int flags); | struct fpu_kern_ctx *fpu_kern_alloc_ctx(u_int flags); | ||||
struct fpu_kern_ctx *fpu_kern_alloc_ctx_domainset(struct domainset *, | |||||
u_int flags); | |||||
void fpu_kern_free_ctx(struct fpu_kern_ctx *ctx); | void fpu_kern_free_ctx(struct fpu_kern_ctx *ctx); | ||||
void fpu_kern_enter(struct thread *td, struct fpu_kern_ctx *ctx, | void fpu_kern_enter(struct thread *td, struct fpu_kern_ctx *ctx, | ||||
u_int flags); | u_int flags); | ||||
int fpu_kern_leave(struct thread *td, struct fpu_kern_ctx *ctx); | int fpu_kern_leave(struct thread *td, struct fpu_kern_ctx *ctx); | ||||
int fpu_kern_thread(u_int flags); | int fpu_kern_thread(u_int flags); | ||||
int is_fpu_kern_thread(u_int flags); | int is_fpu_kern_thread(u_int flags); | ||||
struct savefpu *fpu_save_area_alloc(void); | struct savefpu *fpu_save_area_alloc(void); | ||||
Show All 14 Lines |