From 784e4d4798344cb82fce632fb0853d4a31d98eaf Mon Sep 17 00:00:00 2001 From: cinsights Date: Thu, 6 Aug 2020 09:19:43 +0000 Subject: [PATCH] Add _exit, _kill and _getpid to syscalls.c git-svn-id: svn://svn.code.sf.net/p/chibios/svn/branches/stable_20.3.x@13804 27425a3e-05d8-49a3-a47f-9c15f0e5edd8 --- os/various/syscalls.c | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/os/various/syscalls.c b/os/various/syscalls.c index 8da8f755a..b2052e954 100644 --- a/os/various/syscalls.c +++ b/os/various/syscalls.c @@ -169,4 +169,29 @@ int _isatty_r(struct _reent *r, int fd) { return 1; } +/***************************************************************************/ + +__attribute__((used)) +void _exit(int status) { + (void) status; + chSysHalt("exit"); + abort(); +} + +/***************************************************************************/ + +__attribute__((used)) +int _kill(int pid, int sig) { + (void) pid; + (void) sig; + return -1; +} + +/***************************************************************************/ + +__attribute__((used)) +int _getpid(void) { + + return 1; +} /*** EOF ***/