Changeset df7f5cea in mainline for kernel/arch/ppc32/src/interrupt.c


Ignore:
Timestamp:
2014-08-25T23:03:50Z (10 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
1c635d6, 3ab2d1e
Parents:
6dbe7f68
Message:

Experimental support for hard-floats on ppc32.

  • By default disabled.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/arch/ppc32/src/interrupt.c

    r6dbe7f68 rdf7f5cea  
    112112{
    113113        uint8_t inum;
    114        
     114
    115115        while ((inum = pic_get_pending()) != 255) {
    116116                irq_t *irq = irq_dispatch_and_lock(inum);
     
    146146}
    147147
     148static void exception_fp_unavailable(unsigned int n, istate_t *istate)
     149{
     150#ifdef CONFIG_FPU_LAZY
     151        scheduler_fpu_lazy_request();
     152        /*
     153         * Propagate MSR_FP from MSR back to istate's SRR1, which will become
     154         * the next MSR.
     155         */
     156        istate->srr1 |= msr_read() & MSR_FP;
     157#else
     158        fault_if_from_uspace(istate, "FPU fault.");
     159        panic_badtrap(istate, n, "FPU fault.");
     160#endif
     161}
     162
    148163static void exception_decrementer(unsigned int n, istate_t *istate)
    149164{
     
    161176        exc_register(VECTOR_EXTERNAL, "external", true,
    162177            exception_external);
     178        exc_register(VECTOR_FP_UNAVAILABLE, "fp_unavailable", true,
     179            exception_fp_unavailable);
    163180        exc_register(VECTOR_DECREMENTER, "timer", true,
    164181            exception_decrementer);
Note: See TracChangeset for help on using the changeset viewer.