Changeset ffc277e in mainline for arch/mips/src/fpu_context.c
- Timestamp:
- 2005-09-10T00:52:13Z (20 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- f3a6c8e5
- Parents:
- b02e5d1
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
arch/mips/src/fpu_context.c
rb02e5d1 rffc277e 29 29 30 30 #include <fpu_context.h> 31 #include <arch.h> 32 #include <arch/cp0.h> 31 33 32 void fpu_context_save(fpu_context_t *fctx) 33 { 34 void fpu_disable(void) 35 { 36 #ifdef HAVE_FPU 37 cp0_status_write(cp0_status_read() & ~cp0_status_fpu_bit); 38 if (THREAD && THREAD->pstate) 39 THREAD->pstate->status &= ~cp0_status_fpu_bit; 40 #endif 34 41 } 35 42 36 37 void fpu_context_restore(fpu_context_t *fctx) 43 void fpu_enable(void) 38 44 { 45 #ifdef HAVE_FPU 46 cp0_status_write(cp0_status_read() | cp0_status_fpu_bit); 47 if (THREAD && THREAD->pstate) 48 THREAD->pstate->status |= cp0_status_fpu_bit; 49 #endif 39 50 } 40 51 52 void fpu_init(void) 53 { 54 /* TODO: Zero all registers */ 55 }
Note:
See TracChangeset
for help on using the changeset viewer.