source: rtems/cpukit/score/cpu/nios2/nios2-fatal-halt.c @ 67518231

4.115
Last change on this file since 67518231 was e2d0c68, checked in by Sebastian Huber <sebastian.huber@…>, on Sep 1, 2011 at 3:52:12 PM

2011-09-01 Sebastian Huber <sebastian.huber@…>

  • cpu.c, cpu_asm.S: Removed files.
  • nios2-context-initialize.c, nios2-context-switch.S, nios2-fatal-halt.c, nios2-initialize-vectors.c, nios2-initialize.c, nios2-isr-get-level.c, nios2-isr-install-raw-handler.c, nios2-isr-install-vector.c, nios2-isr-is-in-progress.c, nios2-isr-set-level.c, nios2-thread-dispatch-disabled.c, rtems/score/nios2-utility.h: New files.
  • Makefile.am, preinstall.am: Reflect changes above.
  • irq.c: Update due to API changes.
  • rtems/score/cpu.h: New functions _CPU_Initialize_vectors(), _CPU_ISR_Set_level(), and _CPU_Fatal_halt() (instead of macros). Support for external interrupt controller (EIC). Documentation changes.
  • Property mode set to 100644
File size: 634 bytes
Line 
1/*
2 *  Copyright (c) 2011 embedded brains GmbH
3 *
4 *  Copyright (c) 2006 Kolja Waschk (rtemsdev/ixo.de)
5 *
6 *  COPYRIGHT (c) 1989-2004.
7 *  On-Line Applications Research Corporation (OAR).
8 *
9 *  The license and distribution terms for this file may be
10 *  found in the file LICENSE in this distribution or at
11 *  http://www.rtems.com/license/LICENSE.
12 *
13 *  $Id$
14 */
15
16#include <rtems/score/cpu.h>
17
18void _CPU_Fatal_halt( uint32_t _error )
19{
20  /* write 0 to status register (disable interrupts) */
21  __builtin_wrctl( 0, 0 );
22
23  /* write error code to ET register */
24  __asm__ volatile ("mov et, %z0" : : "rM" (_error));
25
26  while (1);
27}
Note: See TracBrowser for help on using the repository browser.