From 8419b87c6bd7be468239d0f68155631dfb5db103 Mon Sep 17 00:00:00 2001 From: Vegard Storheil Eriksen Date: Mon, 31 Dec 2012 13:55:56 +0100 Subject: Fixed FPU support. Selecting proper FPU flags in build_rules and enabling FPU during startup. --- cortex_m/fpu.h | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 cortex_m/fpu.h (limited to 'cortex_m') diff --git a/cortex_m/fpu.h b/cortex_m/fpu.h new file mode 100644 index 0000000..e5d4872 --- /dev/null +++ b/cortex_m/fpu.h @@ -0,0 +1,20 @@ +#ifndef FPU_H +#define FPU_H + +#include + +struct COPROC_t { + volatile uint32_t CPAC; +}; + +static COPROC_t& COPROC = *(COPROC_t*)0xe000ed88; + +struct FPU_t { + volatile uint32_t FPCC; + volatile uint32_t FPCA; + volatile uint32_t FPDSC; +}; + +static FPU_t& FPU = *(FPU_t*)0xe000ef34; + +#endif -- cgit v1.2.3