Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:arch\x86\kernel\fpu\xstate.c Create Date:2022-07-28 07:50:33
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:When executing XSAVEOPT (or other optimized XSAVE instructions), if* a processor implementation detects that an FPU state component is still* (or is again) in its initialized state, it may clear the corresponding* bit in the header

Proto:void fpstate_sanitize_xstate(struct fpu *fpu)

Type:void

Parameter:

TypeParameterName
struct fpu *fpu
148  fx = fxsave
152  If Not FPU related CPU feature flag helper routines: Then Return
155  xfeatures = xfeatures
161  If (xfeatures & Mask of xstate features supported by the CPU and the kernel:) == Mask of xstate features supported by the CPU and the kernel: Then Return
167  If Not (xfeatures & XFEATURE_MASK_FP) Then
168  Control Word = 0x37f
169  Status Word = 0
170  Tag Word = 0
171  Last Instruction Opcode = 0
172  Instruction Pointer = 0
173  Data Pointer = 0
174  memset( & 8*16 bytes for each FP-reg = 128 bytes: [0], 0, 128)
180  If Not (xfeatures & XFEATURE_MASK_SSE) Then memset( & 16*16 bytes for each XMM-reg = 256 bytes: [0], 0, 256)
187  feature_bit = 0x2
188  xfeatures = (Mask of xstate features supported by the CPU and the kernel: & ~xfeatures) >> 2
195  When xfeatures cycle
196  If xfeatures & 0x1 Then
200  memcpy((void * )fx + offset, (void * ) & xsave + offset, size)
205  xfeatures >>= 1
206  feature_bit++
Caller
NameDescribe
xfpregs_set
xstateregs_get
fpregs_get
fpregs_set
xfpregs_get