add_ping_req memory corruption fix, neighbor state switching, honor states in generat...
[cor_2_6_31.git] / arch / powerpc / math-emu / fctiw.c
blobf694440ddc003a276ef5630f4ad3d5b259a18cc4
1 #include <linux/types.h>
2 #include <linux/errno.h>
3 #include <asm/uaccess.h>
5 #include <asm/sfp-machine.h>
6 #include <math-emu/soft-fp.h>
7 #include <math-emu/double.h>
9 int
10 fctiw(u32 *frD, void *frB)
12 FP_DECL_D(B);
13 FP_DECL_EX;
14 unsigned int r;
16 FP_UNPACK_DP(B, frB);
17 FP_TO_INT_D(r, B, 32, 1);
18 frD[1] = r;
20 #ifdef DEBUG
21 printk("%s: D %p, B %p: ", __func__, frD, frB);
22 dump_double(frD);
23 printk("\n");
24 #endif
26 return 0;