diff options
author | Thomas Doerfler <Thomas.Doerfler@embedded-brains.de> | 2009-10-23 07:32:46 +0000 |
---|---|---|
committer | Thomas Doerfler <Thomas.Doerfler@embedded-brains.de> | 2009-10-23 07:32:46 +0000 |
commit | 2d2de4eba16374ea05fc7ee9cd257ad0d4ebf2ca (patch) | |
tree | 45161e8d9a9d0a9c483b84d915085c0230b09ea0 /c/src/lib/libbsp/powerpc/qemuppc | |
parent | 2009-10-23 Ralf Corsépius <ralf.corsepius@rtems.org> (diff) | |
download | rtems-2d2de4eba16374ea05fc7ee9cd257ad0d4ebf2ca.tar.bz2 |
Update for exception support changes.
Diffstat (limited to 'c/src/lib/libbsp/powerpc/qemuppc')
-rw-r--r-- | c/src/lib/libbsp/powerpc/qemuppc/ChangeLog | 7 | ||||
-rw-r--r-- | c/src/lib/libbsp/powerpc/qemuppc/Makefile.am | 8 | ||||
-rw-r--r-- | c/src/lib/libbsp/powerpc/qemuppc/irq/irq_init.c | 3 | ||||
-rw-r--r-- | c/src/lib/libbsp/powerpc/qemuppc/preinstall.am | 12 | ||||
-rw-r--r-- | c/src/lib/libbsp/powerpc/qemuppc/startup/bspstart.c | 40 |
5 files changed, 28 insertions, 42 deletions
diff --git a/c/src/lib/libbsp/powerpc/qemuppc/ChangeLog b/c/src/lib/libbsp/powerpc/qemuppc/ChangeLog index 227431f1ed..7968d97c86 100644 --- a/c/src/lib/libbsp/powerpc/qemuppc/ChangeLog +++ b/c/src/lib/libbsp/powerpc/qemuppc/ChangeLog @@ -1,3 +1,10 @@ +2009-10-22 Sebastian Huber <sebastian.huber@embedded-brains.de> + + * Makefile.am, preinstall.am: Update for exception support changes. + * irq/irq_init.c: Changed exception header file includes. + * startup/bspstart.c: Changed exception header file includes. Update + for ppc_exc_initialize() changes. + 2009-10-21 Ralf Corsépius <ralf.corsepius@rtems.org> * make/custom/qemuppc.cfg: Remove RTEMS_BSP_FAMILY. diff --git a/c/src/lib/libbsp/powerpc/qemuppc/Makefile.am b/c/src/lib/libbsp/powerpc/qemuppc/Makefile.am index b3da6dd133..d7adc31ea6 100644 --- a/c/src/lib/libbsp/powerpc/qemuppc/Makefile.am +++ b/c/src/lib/libbsp/powerpc/qemuppc/Makefile.am @@ -56,18 +56,10 @@ noinst_LIBRARIES += libbsp.a libbsp_a_SOURCES = $(startup_SOURCES) $(clock_SOURCES) $(console_SOURCES) \ $(irq_SOURCES) -# ../../../libcpu/@RTEMS_CPU@/mpc6xx/clock.rel -include_bsp_HEADERS += ../../../libcpu/@RTEMS_CPU@/@exceptions@/bspsupport/vectors.h \ - ../../../libcpu/@RTEMS_CPU@/@exceptions@/bspsupport/irq_supp.h \ - ../../../libcpu/@RTEMS_CPU@/@exceptions@/bspsupport/ppc_exc_bspsupp.h - - libbsp_a_LIBADD = ../../../libcpu/@RTEMS_CPU@/shared/cpuIdent.rel \ ../../../libcpu/@RTEMS_CPU@/shared/stack.rel \ ../../../libcpu/@RTEMS_CPU@/@exceptions@/rtems-cpu.rel \ - ../../../libcpu/@RTEMS_CPU@/@exceptions@/raw_exception.rel \ ../../../libcpu/@RTEMS_CPU@/@exceptions@/exc_bspsupport.rel \ - ../../../libcpu/@RTEMS_CPU@/@exceptions@/irq_bspsupport.rel \ ../../../libcpu/@RTEMS_CPU@/mpc6xx/mmu.rel \ ../../../libcpu/@RTEMS_CPU@/mpc6xx/timer.rel diff --git a/c/src/lib/libbsp/powerpc/qemuppc/irq/irq_init.c b/c/src/lib/libbsp/powerpc/qemuppc/irq/irq_init.c index d1cc1e0520..f2787b0ec0 100644 --- a/c/src/lib/libbsp/powerpc/qemuppc/irq/irq_init.c +++ b/c/src/lib/libbsp/powerpc/qemuppc/irq/irq_init.c @@ -20,12 +20,10 @@ #include <rtems.h> #include <libcpu/powerpc-utility.h> -#include <libcpu/raw_exception.h> #include <bsp.h> #include <bsp/irq.h> #include <bsp/vectors.h> -#include <bsp/ppc_exc_bspsupp.h> int qemuppc_exception_handler( BSP_Exception_frame *frame, unsigned exception_number) { @@ -55,6 +53,7 @@ rtems_status_code bsp_interrupt_facility_initialize(void) return RTEMS_IO_ERROR; } + return RTEMS_SUCCESSFUL; } void bsp_interrupt_handler_default( rtems_vector_number vector) diff --git a/c/src/lib/libbsp/powerpc/qemuppc/preinstall.am b/c/src/lib/libbsp/powerpc/qemuppc/preinstall.am index 1216527715..306733fc24 100644 --- a/c/src/lib/libbsp/powerpc/qemuppc/preinstall.am +++ b/c/src/lib/libbsp/powerpc/qemuppc/preinstall.am @@ -81,15 +81,3 @@ $(PROJECT_INCLUDE)/bsp/irq-config.h: irq/irq-config.h $(PROJECT_INCLUDE)/bsp/$(d $(INSTALL_DATA) $< $(PROJECT_INCLUDE)/bsp/irq-config.h PREINSTALL_FILES += $(PROJECT_INCLUDE)/bsp/irq-config.h -$(PROJECT_INCLUDE)/bsp/vectors.h: ../../../libcpu/@RTEMS_CPU@/@exceptions@/bspsupport/vectors.h $(PROJECT_INCLUDE)/bsp/$(dirstamp) - $(INSTALL_DATA) $< $(PROJECT_INCLUDE)/bsp/vectors.h -PREINSTALL_FILES += $(PROJECT_INCLUDE)/bsp/vectors.h - -$(PROJECT_INCLUDE)/bsp/irq_supp.h: ../../../libcpu/@RTEMS_CPU@/@exceptions@/bspsupport/irq_supp.h $(PROJECT_INCLUDE)/bsp/$(dirstamp) - $(INSTALL_DATA) $< $(PROJECT_INCLUDE)/bsp/irq_supp.h -PREINSTALL_FILES += $(PROJECT_INCLUDE)/bsp/irq_supp.h - -$(PROJECT_INCLUDE)/bsp/ppc_exc_bspsupp.h: ../../../libcpu/@RTEMS_CPU@/@exceptions@/bspsupport/ppc_exc_bspsupp.h $(PROJECT_INCLUDE)/bsp/$(dirstamp) - $(INSTALL_DATA) $< $(PROJECT_INCLUDE)/bsp/ppc_exc_bspsupp.h -PREINSTALL_FILES += $(PROJECT_INCLUDE)/bsp/ppc_exc_bspsupp.h - diff --git a/c/src/lib/libbsp/powerpc/qemuppc/startup/bspstart.c b/c/src/lib/libbsp/powerpc/qemuppc/startup/bspstart.c index 751f9f3860..d8d089af74 100644 --- a/c/src/lib/libbsp/powerpc/qemuppc/startup/bspstart.c +++ b/c/src/lib/libbsp/powerpc/qemuppc/startup/bspstart.c @@ -16,19 +16,16 @@ #include <string.h> #include <fcntl.h> + +#include <libcpu/bat.h> +#include <libcpu/spr.h> +#include <libcpu/powerpc-utility.h> + #include <bsp.h> #include <bsp/irq.h> +#include <bsp/vectors.h> #include <bsp/bootcard.h> -#include <rtems/bspIo.h> -#include <rtems/powerpc/powerpc.h> -#include <libcpu/powerpc-utility.h> -#include <libcpu/raw_exception.h> #include <bsp/irq-generic.h> -#include <bsp/ppc_exc_bspsupp.h> - -#include <libcpu/cpuIdent.h> -#include <libcpu/bat.h> -#include <libcpu/spr.h> /* * CPU Bus Frequency @@ -65,10 +62,10 @@ static int default_decrementer_exception_handler( BSP_Exception_frame *frame, un void bsp_start( void ) { - uint32_t intrStackStart; - uint32_t intrStackSize; - int rv = 0; - rtems_status_code sc; + rtems_status_code sc = RTEMS_SUCCESSFUL; + uintptr_t intrStackStart; + uintptr_t intrStackSize; + /* * Note we can not get CPU identification dynamically, so * force current_ppc_cpu. @@ -86,30 +83,33 @@ void bsp_start( void ) /* * Initialize the interrupt related settings. */ - intrStackStart = (uint32_t) bsp_interrupt_stack_start; - intrStackSize = (uint32_t) bsp_interrupt_stack_size; + intrStackStart = (uintptr_t) bsp_interrupt_stack_start; + intrStackSize = (uintptr_t) bsp_interrupt_stack_size; BSP_mem_size = (uint32_t )RamSize; /* * Initialize default raw exception handlers. */ - ppc_exc_initialize( + sc = ppc_exc_initialize( PPC_INTERRUPT_DISABLE_MASK_DEFAULT, intrStackStart, intrStackSize ); + if (sc != RTEMS_SUCCESSFUL) { + BSP_panic("cannot initialize exceptions"); + } /* Install default handler for the decrementer exception */ - rv = ppc_exc_set_handler( ASM_DEC_VECTOR, default_decrementer_exception_handler); - if (rv < 0) { - BSP_panic( "Cannot install decrementer exception handler!\n"); + sc = ppc_exc_set_handler( ASM_DEC_VECTOR, default_decrementer_exception_handler); + if (sc != RTEMS_SUCCESSFUL) { + BSP_panic("cannot install decrementer exception handler"); } /* Initalize interrupt support */ sc = bsp_interrupt_initialize(); if (sc != RTEMS_SUCCESSFUL) { - BSP_panic( "Cannot intitialize interrupt support\n"); + BSP_panic("cannot intitialize interrupts"); } #if 0 |