Fix typos in ARM port. Add _exit, _kill and _getpid to syscalls.c
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@13803 27425a3e-05d8-49a3-a47f-9c15f0e5edd8
This commit is contained in:
parent
5697059a00
commit
d96e7c10df
|
@ -301,7 +301,7 @@ void port_init(os_instance_t *oip) {
|
||||||
/**
|
/**
|
||||||
* @brief Setting up MPU region for the current thread.
|
* @brief Setting up MPU region for the current thread.
|
||||||
*/
|
*/
|
||||||
void _port_set_region(void) {
|
void __port_set_region(void) {
|
||||||
|
|
||||||
mpuSetRegionAddress(PORT_USE_GUARD_MPU_REGION,
|
mpuSetRegionAddress(PORT_USE_GUARD_MPU_REGION,
|
||||||
chThdGetSelfX()->wabase);
|
chThdGetSelfX()->wabase);
|
||||||
|
|
|
@ -578,11 +578,11 @@ struct port_context {
|
||||||
if ((stkalign_t *)(r13 - 1) < (otp)->wabase) { \
|
if ((stkalign_t *)(r13 - 1) < (otp)->wabase) { \
|
||||||
chSysHalt("stack overflow"); \
|
chSysHalt("stack overflow"); \
|
||||||
} \
|
} \
|
||||||
__port_switch(ntp, otp); \
|
__port_switch(ntp, otp); \
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
#define port_switch(ntp, otp) { \
|
#define port_switch(ntp, otp) { \
|
||||||
_port_switch(ntp, otp); \
|
__port_switch(ntp, otp); \
|
||||||
\
|
\
|
||||||
/* Setting up the guard page for the switched-in thread.*/ \
|
/* Setting up the guard page for the switched-in thread.*/ \
|
||||||
mpuSetRegionAddress(PORT_USE_GUARD_MPU_REGION, \
|
mpuSetRegionAddress(PORT_USE_GUARD_MPU_REGION, \
|
||||||
|
|
|
@ -169,4 +169,29 @@ int _isatty_r(struct _reent *r, int fd) {
|
||||||
return 1;
|
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 ***/
|
/*** EOF ***/
|
||||||
|
|
Loading…
Reference in New Issue