Subversion Repositories HelenOS

Rev

Rev 1880 | Rev 1883 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1880 Rev 1882
Line 35... Line 35...
35
 
35
 
36
#include <arch/trap/exception.h>
36
#include <arch/trap/exception.h>
37
#include <arch/interrupt.h>
37
#include <arch/interrupt.h>
38
#include <interrupt.h>
38
#include <interrupt.h>
39
#include <arch/asm.h>
39
#include <arch/asm.h>
-
 
40
#include <arch/register.h>
40
#include <debug.h>
41
#include <debug.h>
41
#include <typedefs.h>
42
#include <typedefs.h>
42
#include <symtab.h>
43
#include <symtab.h>
43
#include <print.h>
44
#include <print.h>
44
 
45
 
Line 79... Line 80...
79
    fault_if_from_uspace(istate, "%s\n", __FUNCTION__);
80
    fault_if_from_uspace(istate, "%s\n", __FUNCTION__);
80
    dump_istate(istate);
81
    dump_istate(istate);
81
    panic("%s\n", __FUNCTION__);
82
    panic("%s\n", __FUNCTION__);
82
}
83
}
83
 
84
 
-
 
85
/** Handle fp_disabled. (0x20) */
-
 
86
void fp_disabled(int n, istate_t *istate)
-
 
87
{
-
 
88
    fprs_reg_t fprs;
-
 
89
   
-
 
90
    fprs.value = fprs_read();
-
 
91
    if (!fprs.fef) {
-
 
92
        fprs.fef = true;
-
 
93
        fprs_write(fprs.value);
-
 
94
        return;
-
 
95
    }
-
 
96
 
-
 
97
#ifdef CONFIG_FPU_LAZY
-
 
98
    scheduler_fpu_lazy_request();
-
 
99
#else
-
 
100
    fault_if_from_uspace(istate, "%s\n", __FUNCTION__);
-
 
101
    dump_istate(istate);
-
 
102
    panic("%s\n", __FUNCTION__);
-
 
103
#endif
-
 
104
}
-
 
105
 
84
/** Handle division_by_zero. (0x28) */
106
/** Handle division_by_zero. (0x28) */
85
void division_by_zero(int n, istate_t *istate)
107
void division_by_zero(int n, istate_t *istate)
86
{
108
{
87
    fault_if_from_uspace(istate, "%s\n", __FUNCTION__);
109
    fault_if_from_uspace(istate, "%s\n", __FUNCTION__);
88
    dump_istate(istate);
110
    dump_istate(istate);