Lines Matching refs:fpstate

45 extern void __copy_xstate_to_uabi_buf(struct membuf to, struct fpstate *fpstate,
49 extern int copy_uabi_from_kernel_to_xstate(struct fpstate *fpstate, const void *kbuf, u32 *pkru);
144 extern void xfd_validate_state(struct fpstate *fpstate, u64 mask, bool rstor);
146 static inline void xfd_validate_state(struct fpstate *fpstate, u64 mask, bool rstor) { } in xfd_validate_state() argument
150 static inline void xfd_update_state(struct fpstate *fpstate) in xfd_update_state() argument
153 u64 xfd = fpstate->xfd; in xfd_update_state()
164 static inline void xfd_update_state(struct fpstate *fpstate) { } in xfd_update_state() argument
177 static inline void os_xsave(struct fpstate *fpstate) in os_xsave() argument
179 u64 mask = fpstate->xfeatures; in os_xsave()
185 xfd_validate_state(fpstate, mask, false); in os_xsave()
187 XSTATE_XSAVE(&fpstate->regs.xsave, lmask, hmask, err); in os_xsave()
198 static inline void os_xrstor(struct fpstate *fpstate, u64 mask) in os_xrstor() argument
203 xfd_validate_state(fpstate, mask, true); in os_xrstor()
204 XSTATE_XRESTORE(&fpstate->regs.xsave, lmask, hmask); in os_xrstor()
208 static inline void os_xrstor_supervisor(struct fpstate *fpstate) in os_xrstor_supervisor() argument
214 XSTATE_XRESTORE(&fpstate->regs.xsave, lmask, hmask); in os_xrstor_supervisor()
263 struct fpstate *fpstate = current->thread.fpu.fpstate; in xsave_to_user_sigframe() local
264 u64 mask = fpstate->user_xfeatures; in xsave_to_user_sigframe()
275 xfd_validate_state(fpstate, mask, false); in xsave_to_user_sigframe()
294 xfd_validate_state(current->thread.fpu.fpstate, mask, true); in xrstor_from_user_sigframe()
307 static inline int os_xrstor_safe(struct fpstate *fpstate, u64 mask) in os_xrstor_safe() argument
309 struct xregs_state *xstate = &fpstate->regs.xsave; in os_xrstor_safe()
315 xfd_update_state(fpstate); in os_xrstor_safe()