diff options
Diffstat (limited to 'arch')
-rw-r--r-- | arch/sparc64/math-emu/math.c | 25 |
1 files changed, 23 insertions, 2 deletions
diff --git a/arch/sparc64/math-emu/math.c b/arch/sparc64/math-emu/math.c index 2ae05cd7b773..a93a3664c854 100644 --- a/arch/sparc64/math-emu/math.c +++ b/arch/sparc64/math-emu/math.c | |||
@@ -206,9 +206,30 @@ int do_mathemu(struct pt_regs *regs, struct fpustate *f) | |||
206 | case FSTOQ: TYPE(3,3,1,1,1,0,0); break; | 206 | case FSTOQ: TYPE(3,3,1,1,1,0,0); break; |
207 | case FDTOQ: TYPE(3,3,1,2,1,0,0); break; | 207 | case FDTOQ: TYPE(3,3,1,2,1,0,0); break; |
208 | case FQTOI: TYPE(3,1,0,3,1,0,0); break; | 208 | case FQTOI: TYPE(3,1,0,3,1,0,0); break; |
209 | |||
210 | /* We can get either unimplemented or unfinished | ||
211 | * for these cases. Pre-Niagara systems generate | ||
212 | * unfinished fpop for SUBNORMAL cases, and Niagara | ||
213 | * always gives unimplemented fpop for fsqrt{s,d}. | ||
214 | */ | ||
215 | case FSQRTS: { | ||
216 | unsigned long x = current_thread_info()->xfsr[0]; | ||
217 | |||
218 | x = (x >> 14) & 0xf; | ||
219 | TYPE(x,1,1,1,1,0,0); | ||
220 | printk("math-emu: type is %08x\n", type); | ||
221 | break; | ||
222 | } | ||
223 | |||
224 | case FSQRTD: { | ||
225 | unsigned long x = current_thread_info()->xfsr[0]; | ||
226 | |||
227 | x = (x >> 14) & 0xf; | ||
228 | TYPE(x,2,1,2,1,0,0); | ||
229 | break; | ||
230 | } | ||
231 | |||
209 | /* SUBNORMAL - ftt == 2 */ | 232 | /* SUBNORMAL - ftt == 2 */ |
210 | case FSQRTS: TYPE(2,1,1,1,1,0,0); break; | ||
211 | case FSQRTD: TYPE(2,2,1,2,1,0,0); break; | ||
212 | case FADDD: | 233 | case FADDD: |
213 | case FSUBD: | 234 | case FSUBD: |
214 | case FMULD: | 235 | case FMULD: |