summaryrefslogtreecommitdiffstats
path: root/cpukit/score/cpu/powerpc
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2017-11-21 12:00:49 +0100
committerSebastian Huber <sebastian.huber@embedded-brains.de>2017-11-22 09:40:23 +0100
commit07d96453a98c9df64be87eaf1f9023ba05e90297 (patch)
tree6d4b2e13511403419f36c5b8e50db71d1e9ca6b4 /cpukit/score/cpu/powerpc
parentpowerpc: Replace BSP_panic() with rtems_panic() (diff)
downloadrtems-07d96453a98c9df64be87eaf1f9023ba05e90297.tar.bz2
powerpc: Remove _BSP_Fatal_error()
BSPs can use the bsp_fatal_extension() to provide BSP-specific fatal error handling. There is no need for a _BSP_Fatal_error(). Close #3246.
Diffstat (limited to 'cpukit/score/cpu/powerpc')
-rw-r--r--cpukit/score/cpu/powerpc/rtems/score/cpu.h25
1 files changed, 12 insertions, 13 deletions
diff --git a/cpukit/score/cpu/powerpc/rtems/score/cpu.h b/cpukit/score/cpu/powerpc/rtems/score/cpu.h
index b8f00bf910..8c0f200641 100644
--- a/cpukit/score/cpu/powerpc/rtems/score/cpu.h
+++ b/cpukit/score/cpu/powerpc/rtems/score/cpu.h
@@ -675,22 +675,21 @@ static inline void _CPU_ISR_Set_level( uint32_t level )
_CPU_MSR_SET(msr);
}
-/* Fatal Error manager macros */
-
-/*
- * This routine copies _error into a known place -- typically a stack
- * location or a register, optionally disables interrupts, and
- * halts/stops the CPU.
- */
-
-void _BSP_Fatal_error(unsigned int);
-
#endif /* ASM */
#define _CPU_Fatal_halt( _source, _error ) \
- _BSP_Fatal_error(_error)
-
-/* end of Fatal Error manager macros */
+ do { \
+ ppc_interrupt_disable(); \
+ __asm__ volatile ( \
+ "mr 3, %0\n" \
+ "mr 4, %1\n" \
+ "1:\n" \
+ "b 1b\n" \
+ : \
+ : "r" (_source), "r" (_error) \
+ : "memory" \
+ ); \
+ } while ( 0 )
/*
* Should be large enough to run all RTEMS tests. This ensures