summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sim-scripts/.cvsignore1
-rw-r--r--sim-scripts/ChangeLog6
-rw-r--r--sim-scripts/Makefile17
-rw-r--r--sim-scripts/README13
-rw-r--r--sim-scripts/erc32.in58
-rwxr-xr-xsim-scripts/gdb-sim-run.in13
6 files changed, 95 insertions, 13 deletions
diff --git a/sim-scripts/.cvsignore b/sim-scripts/.cvsignore
index ba1bd67..bb70278 100644
--- a/sim-scripts/.cvsignore
+++ b/sim-scripts/.cvsignore
@@ -4,6 +4,7 @@ csb337
csb350
csb360
edb7312
+erc32
ezkit533
h8sim
h8sim-gdb
diff --git a/sim-scripts/ChangeLog b/sim-scripts/ChangeLog
index c650837..3a57d95 100644
--- a/sim-scripts/ChangeLog
+++ b/sim-scripts/ChangeLog
@@ -1,5 +1,11 @@
2009-01-20 Joel Sherrill <joel.sherrill@oarcorp.com>
+ * .cvsignore, Makefile, README, gdb-sim-run.in: Add first cut at ERC32.
+ Need to test on machine with TSIM license.
+ * erc32.in: New file.
+
+2009-01-20 Joel Sherrill <joel.sherrill@oarcorp.com>
+
* .cvsignore, Makefile: Add rest of Skyeye configurations whether
they work completely at this point or not.
* ant5206.in, bf537Stamp.in, csb337.in, csb350.in, csb360.in,
diff --git a/sim-scripts/Makefile b/sim-scripts/Makefile
index eeda4ae..1caa746 100644
--- a/sim-scripts/Makefile
+++ b/sim-scripts/Makefile
@@ -3,14 +3,16 @@
#
INSTALL_DIR=../bin
-GENERATED_SCRIPTS=h8sim h8sim-gdb jmr3904 jmr3904-gdb \
+GDBSIM_SCRIPTS=h8sim h8sim-gdb jmr3904 jmr3904-gdb \
m32csim m32csim-gdb m32rsim m32rsim-gdb psim psim-gdb \
sis sis-gdb simsh simsh-gdb
SKYEYE_SCRIPTS=ant5206 bf537Stamp csb337 csb350 csb360 edb7312 ezkit533 \
rtl22xx smdk2410
+TSIM_SCRIPTS=erc32
+GENERATED_SCRIPTS=${GDBSIM_SCRIPTS} ${SKYEYE_SCRIPTS} ${TSIM_SCRIPTS}
COMPILED_PROGRAMS=usleep
-all: prep ${GENERATED_SCRIPTS} ${SKYEYE_SCRIPTS} ${COMPILED_PROGRAMS} install
+all: prep ${GENERATED_SCRIPTS} ${COMPILED_PROGRAMS} install
prep:
test -d ${INSTALL_DIR} || mkdir ${INSTALL_DIR}
@@ -46,6 +48,10 @@ smdk2410: gdb-sim-run.in smdk2410.in
ezkit533: gdb-sim-run.in ezkit533.in
./mkrun no Blackfin bfin ezkit533
+### TSIM Simulator BSPs
+erc32: gdb-sim-run.in erc32.in
+ ./mkrun no SPARC sparc erc32
+
### GDB Simulator BSPs
h8sim h8sim-gdb: gdb-sim-run.in gdb-sim.in h8sim.in
./mkrun yes H8300 h8300 h8sim
@@ -69,13 +75,10 @@ simsh simsh-gdb: gdb-sim-run.in gdb-sim.in simsh.in
./mkrun yes SuperH sh simsh
clean:
- rm -f ${GENERATED_SCRIPTS} ${COMPILED_PROGRAMS} ${SKYEYE_SCRIPTS}
+ rm -f ${GENERATED_SCRIPTS} ${COMPILED_PROGRAMS}
install:
- for i in ${COMPILED_PROGRAMS} ${SKYEYE_SCRIPTS}; do \
- cp $${i} ${INSTALL_DIR} ; \
- done
- for i in ${GENERATED_SCRIPTS} ; do \
+ for i in ${GENERATED_SCRIPTS} ${COMPILED_PROGRAMS} ; do \
cp $${i} ${INSTALL_DIR}/$${i} ; \
chmod +x ${INSTALL_DIR}/$${i} ; \
done
diff --git a/sim-scripts/README b/sim-scripts/README
index b5fdce6..67082a9 100644
--- a/sim-scripts/README
+++ b/sim-scripts/README
@@ -6,3 +6,16 @@ This directory contains a framework for running RTEMS applications
on simulators. These help run the simulators in a consistent manner
and detect programs which have faulted.
+NOTES:
+
+[1] The script name is intended to match the name of the BSP it will run
+ executables for. But there are a few scripts which can run multiple BSPs:
+ simsh -
+ h8sim - h8sim, h8sxsim
+
+[2] The BSPs ant5206, csb350, and csb360 do not run yet on Skyeye. This
+ is a known Skyeye issue being addressed.
+
+[3] The bf537Stamp and ezkit533 patches to Skyeye. This is expected to
+ be resolved eventually.
+
diff --git a/sim-scripts/erc32.in b/sim-scripts/erc32.in
new file mode 100644
index 0000000..0315cf8
--- /dev/null
+++ b/sim-scripts/erc32.in
@@ -0,0 +1,58 @@
+#
+# SPARC/ERC32 Support (on TSIM)
+#
+# $Id$
+#
+
+bspUsesGDBSimulator="no"
+runBSP=tsim-erc32
+
+type ${runBSP} >/dev/null 2>&1
+if [ $? -ne 0 ] ; then
+ echo "Unable to find ${runBSP} on PATH."
+ exit 1
+fi
+
+# required for this to run
+echo | ${runBSP} -nohaspnet >/dev/null
+if [ $? -ne 0 ] ; then
+ echo "No TSIM License for this machine."
+ exit 1
+fi
+
+runARGS()
+{
+ echo ${1}
+}
+
+checkBSPFaults()
+{
+ return 0
+}
+
+bspLimit()
+{
+ testname=$1
+ case ${tname} in
+ *stackchk*)limit=5 ;;
+ *fatal*) limit=1 ;;
+ *psxtime*) limit=180 ;;
+ *) limit=60 ;;
+ esac
+ return ${limit}
+}
+
+bspGeneratesDeviceTree="yes"
+bspTreeFile=erc32.conf
+
+### Generate the PSIM device tree based upon the type of application being run
+bspGenerateDeviceTree()
+{
+ if [ ${coverage} = yes ] ; then
+ echo "coverage enable"
+ fi
+ echo "go 0x2000000 ${limit} s"
+ if [ ${coverage} = yes ] ; then
+ echo "coverage save ${2}.cov"
+ fi
+}
diff --git a/sim-scripts/gdb-sim-run.in b/sim-scripts/gdb-sim-run.in
index aac9c76..7993d58 100755
--- a/sim-scripts/gdb-sim-run.in
+++ b/sim-scripts/gdb-sim-run.in
@@ -215,10 +215,15 @@ do
*fatal*) testtype="fatal" ;;
*) testtype="single" ;;
esac
+ # calculate the limit in case it is used by the simulator script
+ if [ ${limit} = "not_set" ] ; then
+ bspLimit ${toRun}
+ limit=$?
+ fi
- ## Some BSPs must generate device trees to provide to the simulator
+ ## Some BSPs must generate device trees or scripts to provide to the simulator
if [ ${bspGeneratesDeviceTree} = "yes" ] ; then
- bspGenerateDeviceTree ${baseToRun} >${bspTreeFile}
+ bspGenerateDeviceTree ${baseToRun} ${toRun} >${bspTreeFile}
if [ ${generate_tree_and_exit} = "yes" ] ; then
echo "Device tree generated and in ${bspTreeFile}"
exit 0
@@ -230,10 +235,6 @@ do
continue
fi
- if [ ${limit} = "not_set" ] ; then
- bspLimit ${toRun}
- limit=$?
- fi
if [ ${testtype} = "fatal" -a ${bspRunFatal} = "no" ] ; then
warn "Skipping fatal error test ${toRun}"
continue