1 /* SPDX-License-Identifier: GPL-2.0 */ 1 2 /* fpumacro.h: FPU related macros. 3 * 4 * Copyright (C) 1997 Jakub Jelinek (jj@sunsit 5 * Copyright (C) 1997 David S. Miller (davem@c 6 */ 7 8 #ifndef _SPARC64_FPUMACRO_H 9 #define _SPARC64_FPUMACRO_H 10 11 #include <asm/asi.h> 12 #include <asm/visasm.h> 13 14 struct fpustate { 15 u32 regs[64]; 16 }; 17 18 #define FPUSTATE (struct fpustate *)(current_t 19 20 static inline unsigned long fprs_read(void) 21 { 22 unsigned long retval; 23 24 __asm__ __volatile__("rd %%fprs, %0" : 25 26 return retval; 27 } 28 29 static inline void fprs_write(unsigned long va 30 { 31 __asm__ __volatile__("wr %0, 0x0, %%fp 32 } 33 34 #endif /* !(_SPARC64_FPUMACRO_H) */ 35
Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.