Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris...
[linux/fpc-iii.git] / arch / powerpc / include / asm / kvm_fpu.h
blob92daae13249245e31783b31756b3b88608f9cf68
1 /*
2 * This program is free software; you can redistribute it and/or modify
3 * it under the terms of the GNU General Public License, version 2, as
4 * published by the Free Software Foundation.
6 * This program is distributed in the hope that it will be useful,
7 * but WITHOUT ANY WARRANTY; without even the implied warranty of
8 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
9 * GNU General Public License for more details.
11 * You should have received a copy of the GNU General Public License
12 * along with this program; if not, write to the Free Software
13 * Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
15 * Copyright Novell Inc. 2010
17 * Authors: Alexander Graf <agraf@suse.de>
20 #ifndef __ASM_KVM_FPU_H__
21 #define __ASM_KVM_FPU_H__
23 #include <linux/types.h>
25 extern void fps_fres(u64 *fpscr, u32 *dst, u32 *src1);
26 extern void fps_frsqrte(u64 *fpscr, u32 *dst, u32 *src1);
27 extern void fps_fsqrts(u64 *fpscr, u32 *dst, u32 *src1);
29 extern void fps_fadds(u64 *fpscr, u32 *dst, u32 *src1, u32 *src2);
30 extern void fps_fdivs(u64 *fpscr, u32 *dst, u32 *src1, u32 *src2);
31 extern void fps_fmuls(u64 *fpscr, u32 *dst, u32 *src1, u32 *src2);
32 extern void fps_fsubs(u64 *fpscr, u32 *dst, u32 *src1, u32 *src2);
34 extern void fps_fmadds(u64 *fpscr, u32 *dst, u32 *src1, u32 *src2,
35 u32 *src3);
36 extern void fps_fmsubs(u64 *fpscr, u32 *dst, u32 *src1, u32 *src2,
37 u32 *src3);
38 extern void fps_fnmadds(u64 *fpscr, u32 *dst, u32 *src1, u32 *src2,
39 u32 *src3);
40 extern void fps_fnmsubs(u64 *fpscr, u32 *dst, u32 *src1, u32 *src2,
41 u32 *src3);
42 extern void fps_fsel(u64 *fpscr, u32 *dst, u32 *src1, u32 *src2,
43 u32 *src3);
45 #define FPD_ONE_IN(name) extern void fpd_ ## name(u64 *fpscr, u32 *cr, \
46 u64 *dst, u64 *src1);
47 #define FPD_TWO_IN(name) extern void fpd_ ## name(u64 *fpscr, u32 *cr, \
48 u64 *dst, u64 *src1, u64 *src2);
49 #define FPD_THREE_IN(name) extern void fpd_ ## name(u64 *fpscr, u32 *cr, \
50 u64 *dst, u64 *src1, u64 *src2, u64 *src3);
52 extern void fpd_fcmpu(u64 *fpscr, u32 *cr, u64 *src1, u64 *src2);
53 extern void fpd_fcmpo(u64 *fpscr, u32 *cr, u64 *src1, u64 *src2);
55 FPD_ONE_IN(fsqrts)
56 FPD_ONE_IN(frsqrtes)
57 FPD_ONE_IN(fres)
58 FPD_ONE_IN(frsp)
59 FPD_ONE_IN(fctiw)
60 FPD_ONE_IN(fctiwz)
61 FPD_ONE_IN(fsqrt)
62 FPD_ONE_IN(fre)
63 FPD_ONE_IN(frsqrte)
64 FPD_ONE_IN(fneg)
65 FPD_ONE_IN(fabs)
66 FPD_TWO_IN(fadds)
67 FPD_TWO_IN(fsubs)
68 FPD_TWO_IN(fdivs)
69 FPD_TWO_IN(fmuls)
70 FPD_TWO_IN(fcpsgn)
71 FPD_TWO_IN(fdiv)
72 FPD_TWO_IN(fadd)
73 FPD_TWO_IN(fmul)
74 FPD_TWO_IN(fsub)
75 FPD_THREE_IN(fmsubs)
76 FPD_THREE_IN(fmadds)
77 FPD_THREE_IN(fnmsubs)
78 FPD_THREE_IN(fnmadds)
79 FPD_THREE_IN(fsel)
80 FPD_THREE_IN(fmsub)
81 FPD_THREE_IN(fmadd)
82 FPD_THREE_IN(fnmsub)
83 FPD_THREE_IN(fnmadd)
85 extern void kvm_cvt_fd(u32 *from, u64 *to);
86 extern void kvm_cvt_df(u64 *from, u32 *to);
88 #endif