diff options
-rw-r--r-- | nuttx/arch/arm/src/lm3s/lm3s_irq.c | 155 | ||||
-rw-r--r-- | nuttx/arch/arm/src/lm3s/lm3s_lowputc.c | 1 | ||||
-rw-r--r-- | nuttx/configs/eagle100/ostest/defconfig | 6 | ||||
-rw-r--r-- | nuttx/configs/eagle100/ostest/ld.script | 2 |
4 files changed, 86 insertions, 78 deletions
diff --git a/nuttx/arch/arm/src/lm3s/lm3s_irq.c b/nuttx/arch/arm/src/lm3s/lm3s_irq.c index def4ce391..c9f47c0df 100644 --- a/nuttx/arch/arm/src/lm3s/lm3s_irq.c +++ b/nuttx/arch/arm/src/lm3s/lm3s_irq.c @@ -41,6 +41,8 @@ #include <nuttx/config.h> #include <sys/types.h> +#include <debug.h> + #include <nuttx/irq.h> #include <nuttx/arch.h> @@ -74,6 +76,83 @@ uint32 *current_regs; ****************************************************************************/ /**************************************************************************** + * Name: lm3s_nmi, lm3s_hardfault, lm3s_mpu, lm3s_busfault, lm3s_usagefault, + * lm3s_svcall, lm3s_dbgmonitor, lm3s_pendsv, lm3s_reserved + * + * Description: + * Handlers for various execptions. None are handled and all are fatal + * error conditions. The only advantage these provided over the default + * unexpected interrupt handler is that they provide a diagnostic output. + * + ****************************************************************************/ + +#ifdef CONFIG_DEBUG +static int lm3s_nmi(int irq, FAR void *context) +{ + (void)irqsave(); + dbg("PANIC!!! NMI received\n"); + PANIC(OSERR_UNEXPECTEDISR); + return 0; +} + +static int lm3s_hardfault(int irq, FAR void *context) +{ + (void)irqsave(); + dbg("PANIC!!! Hard fault received\n"); + PANIC(OSERR_UNEXPECTEDISR); + return 0; +} + +static int lm3s_mpu(int irq, FAR void *context) +{ + (void)irqsave(); + dbg("PANIC!!! MPU interrupt received\n"); + PANIC(OSERR_UNEXPECTEDISR); + return 0; +} + +static int lm3s_busfault(int irq, FAR void *context) +{ + (void)irqsave(); + dbg("PANIC!!! Bus fault recived\n"); + PANIC(OSERR_UNEXPECTEDISR); + return 0; +} + +static int lm3s_usagefault(int irq, FAR void *context) +{ + (void)irqsave(); + dbg("PANIC!!! Usage fault received\n"); + PANIC(OSERR_UNEXPECTEDISR); + return 0; +} + +static int lm3s_svcall(int irq, FAR void *context) +{ + (void)irqsave(); + dbg("PANIC!!! SVCALL received\n"); + PANIC(OSERR_UNEXPECTEDISR); + return 0; +} + +static int lm3s_dbgmonitor(int irq, FAR void *context) +{ + (void)irqsave(); + dbg("PANIC!!! Debug Monitor receieved\n"); + PANIC(OSERR_UNEXPECTEDISR); + return 0; +} + +static int lm3s_reserved(int irq, FAR void *context) +{ + (void)irqsave(); + dbg("PANIC!!! Reserved interrupt\n"); + PANIC(OSERR_UNEXPECTEDISR); + return 0; +} +#endif + +/**************************************************************************** * Name: lml3s_irqinfo * * Description: @@ -322,79 +401,3 @@ int up_prioritize_irq(int irq, int priority) return OK; } #endif - -/**************************************************************************** - * Name: lm3s_nmi, lm3s_hardfault, lm3s_mpu, lm3s_busfault, lm3s_usagefault, - * lm3s_svcall, lm3s_dbgmonitor, lm3s_pendsv, lm3s_reserved - * - * Description: - * Handlers for various execptions. None are handler and all are fatal - * error conditions. - * - ****************************************************************************/ - -#ifdef CONFIG_DEBUG -int lm3s_nmi(int irq, FAR void *context) -{ - (void)irqsave(); - dbg("PANIC!!! NMI received\n"); - PANIC(OSERR_UNEXPECTEDISR); - return 0; -} - -int lm3s_hardfault(int irq, FAR void *context) -{ - (void)irqsave(); - dbg("PANIC!!! Hard fault received\n"); - PANIC(OSERR_UNEXPECTEDISR); - return 0; -} - -int lm3s_mpu(int irq, FAR void *context) -{ - (void)irqsave(); - dbg("PANIC!!! MPU interrupt received\n"); - PANIC(OSERR_UNEXPECTEDISR); - return 0; -} - -int lm3s_busfault(int irq, FAR void *context) -{ - (void)irqsave(); - dbg("PANIC!!! Bus fault recived\n"); - PANIC(OSERR_UNEXPECTEDISR); - return 0; -} - -int lm3s_usagefault(int irq, FAR void *context) -{ - (void)irqsave(); - dbg("PANIC!!! Usage fault received\n"); - PANIC(OSERR_UNEXPECTEDISR); - return 0; -} - -int lm3s_svcall(int irq, FAR void *context) -{ - (void)irqsave(); - dbg("PANIC!!! SVCALL received\n"); - PANIC(OSERR_UNEXPECTEDISR); - return 0; -} - -int lm3s_dbgmonitor(int irq, FAR void *context) -{ - (void)irqsave(); - dbg("PANIC!!! Debug Monitor receieved\n"); - PANIC(OSERR_UNEXPECTEDISR); - return 0; -} - -int lm3s_reserved(int irq, FAR void *context) -{ - (void)irqsave(); - dbg("PANIC!!! Reserved interrupt\n"); - PANIC(OSERR_UNEXPECTEDISR); - return 0; -} -#endif diff --git a/nuttx/arch/arm/src/lm3s/lm3s_lowputc.c b/nuttx/arch/arm/src/lm3s/lm3s_lowputc.c index 7e675f110..1df228dec 100644 --- a/nuttx/arch/arm/src/lm3s/lm3s_lowputc.c +++ b/nuttx/arch/arm/src/lm3s/lm3s_lowputc.c @@ -220,7 +220,6 @@ void up_lowputc(char ch) void up_lowsetup(void) { - uint32 rcgc1; #if defined(HAVE_CONSOLE) && !defined(CONFIG_SUPPRESS_UART_CONFIG) uint32 ctl; diff --git a/nuttx/configs/eagle100/ostest/defconfig b/nuttx/configs/eagle100/ostest/defconfig index f30c50ff0..6310a02e3 100644 --- a/nuttx/configs/eagle100/ostest/defconfig +++ b/nuttx/configs/eagle100/ostest/defconfig @@ -131,6 +131,9 @@ CONFIG_LM3S_ETHLEDS=n # CONFIG_INTELHEX_BINARY - make the Intel HEX binary format # used with many different loaders using the GNU objcopy program # Should not be selected if you are not using the GNU toolchain. +# CONFIG_MOTOROLA_SREC - make the Motorola S-Record binary format +# used with many different loaders using the GNU objcopy program +# Should not be selected if you are not using the GNU toolchain. # CONFIG_RAW_BINARY - make a raw binary format file used with many # different loaders using the GNU objcopy program. This option # should not be selected if you are not using the GNU toolchain. @@ -138,7 +141,8 @@ CONFIG_LM3S_ETHLEDS=n # CONFIG_RRLOAD_BINARY=n CONFIG_INTELHEX_BINARY=n -CONFIG_RAW_BINARY=n +CONFIG_MOTOROLA_SREC=n +CONFIG_RAW_BINARY=y CONFIG_HAVE_LIBM=n # diff --git a/nuttx/configs/eagle100/ostest/ld.script b/nuttx/configs/eagle100/ostest/ld.script index 050022f94..df687adaa 100644 --- a/nuttx/configs/eagle100/ostest/ld.script +++ b/nuttx/configs/eagle100/ostest/ld.script @@ -52,10 +52,12 @@ SECTIONS { .text : { _stext = ABSOLUTE(.); + *(.vectors) *(.text) *(.fixup) *(.gnu.warning) *(.rodata) + *(.rodata.str1.1) *(.glue_7) *(.glue_7t) *(.got) /* Global offset table */ |