diff options
Diffstat (limited to 'src/lib')
-rw-r--r-- | src/lib/cxxtest_stub.C | 11 | ||||
-rw-r--r-- | src/lib/makefile | 3 | ||||
-rw-r--r-- | src/lib/syscall_misc.C | 10 |
3 files changed, 23 insertions, 1 deletions
diff --git a/src/lib/cxxtest_stub.C b/src/lib/cxxtest_stub.C new file mode 100644 index 000000000..cbc98baee --- /dev/null +++ b/src/lib/cxxtest_stub.C @@ -0,0 +1,11 @@ +#include <stdint.h> + +namespace CxxTest +{ + +// This variable is to allow a code in a binary image not containing the +// testcase modules to query the number of failed tests +uint64_t g_FailedTests = 0; + +} + diff --git a/src/lib/makefile b/src/lib/makefile index 86735cf22..d4c4f70cb 100644 --- a/src/lib/makefile +++ b/src/lib/makefile @@ -2,6 +2,7 @@ ROOTPATH = ../.. OBJS = string.o stdlib.o assert.o stdio.o OBJS += syscall_stub.o syscall_task.o syscall_msg.o -OBJS += syscall_mmio.o syscall_time.o sync.o +OBJS += syscall_mmio.o syscall_time.o sync.o syscall_misc.o +OBJS += cxxtest_stub.o include ${ROOTPATH}/config.mk diff --git a/src/lib/syscall_misc.C b/src/lib/syscall_misc.C new file mode 100644 index 000000000..6a4ad1845 --- /dev/null +++ b/src/lib/syscall_misc.C @@ -0,0 +1,10 @@ +#include <sys/misc.h> +#include <sys/syscall.h> + +using namespace Systemcalls; + +void shutdown(uint64_t i_status) +{ + _syscall1(MISC_SHUTDOWN, reinterpret_cast<void*>(i_status)); +} + |