irqchip: Fix dependencies for archs w/o HAS_IOMEM
[linux/fpc-iii.git] / arch / s390 / include / asm / fpu / api.h
blob5e04f3cbd320d78e963c7ae18639c94d4b83952c
1 /*
2 * In-kernel FPU support functions
4 * Copyright IBM Corp. 2015
5 * Author(s): Hendrik Brueckner <brueckner@linux.vnet.ibm.com>
6 */
8 #ifndef _ASM_S390_FPU_API_H
9 #define _ASM_S390_FPU_API_H
11 void save_fpu_regs(void);
13 static inline int test_fp_ctl(u32 fpc)
15 u32 orig_fpc;
16 int rc;
18 asm volatile(
19 " efpc %1\n"
20 " sfpc %2\n"
21 "0: sfpc %1\n"
22 " la %0,0\n"
23 "1:\n"
24 EX_TABLE(0b,1b)
25 : "=d" (rc), "=d" (orig_fpc)
26 : "d" (fpc), "0" (-EINVAL));
27 return rc;
30 #endif /* _ASM_S390_FPU_API_H */