summaryrefslogtreecommitdiffstats
path: root/c/src/lib/libbsp/sparc/shared/bspclean.c
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>2000-11-13 22:31:22 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>2000-11-13 22:31:22 +0000
commit3eec211fd2cc583ace1f968f904144037ad0acce (patch)
tree56b7cfb176d4aa26d3e7d6eae66f2f21ae4639bf /c/src/lib/libbsp/sparc/shared/bspclean.c
parent2000-11-13 Jiri Gaisler <jgais@ws.estec.esa.nl> (diff)
downloadrtems-3eec211fd2cc583ace1f968f904144037ad0acce.tar.bz2
2000-11-13 Jiri Gaisler <jgais@ws.estec.esa.nl>
* ChangeLog, .cvsignore, Makefile.am, bspclean.c, bspstart.c, gnatcommon.c, start.S: New files. Largely moved from ERC32 BSP to be able to be shared with LEON and other SPARC BSPs.
Diffstat (limited to '')
-rw-r--r--c/src/lib/libbsp/sparc/shared/bspclean.c37
1 files changed, 37 insertions, 0 deletions
diff --git a/c/src/lib/libbsp/sparc/shared/bspclean.c b/c/src/lib/libbsp/sparc/shared/bspclean.c
new file mode 100644
index 0000000000..5e6cea2e2f
--- /dev/null
+++ b/c/src/lib/libbsp/sparc/shared/bspclean.c
@@ -0,0 +1,37 @@
+/* bspclean.c
+ *
+ * This file contains cleanup code executed when the application exits.
+ *
+ * COPYRIGHT (c) 1989-1999.
+ * On-Line Applications Research Corporation (OAR).
+ *
+ * The license and distribution terms for this file may be
+ * found in the file LICENSE in this distribution or at
+ * http://www.OARcorp.com/rtems/license.html.
+ *
+ * Ported to ERC32 implementation of the SPARC by On-Line Applications
+ * Research Corporation (OAR) under contract to the European Space
+ * Agency (ESA).
+ *
+ * ERC32 modifications of respective RTEMS file: COPYRIGHT (c) 1995.
+ * European Space Agency.
+ *
+ * $Id$
+ */
+
+#include <bsp.h>
+
+/*
+ * The app has "exited" (rtems_shutdown_executive returns control to main)
+ */
+
+void bsp_cleanup( void )
+{
+ /*
+ * "halt" by trapping to the simulator command line.
+ * set %g1 to 1 to detect clean exit.
+ */
+
+
+ asm volatile( "mov 1, %g1; ta 0" );
+}