From 155ef8ed75b12442fde1d80e4ca880d0e7f7c1f1 Mon Sep 17 00:00:00 2001 From: gdisirio Date: Sat, 17 Aug 2013 11:52:50 +0000 Subject: git-svn-id: svn://svn.code.sf.net/p/chibios/svn/branches/kernel_3_dev@6169 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- os/hal/osal/chibios/osal.c | 29 ----------------------------- os/hal/osal/chibios/osal.h | 26 ++++++++++++++++++++++++-- 2 files changed, 24 insertions(+), 31 deletions(-) (limited to 'os/hal/osal') diff --git a/os/hal/osal/chibios/osal.c b/os/hal/osal/chibios/osal.c index ed291880b..52fc27041 100644 --- a/os/hal/osal/chibios/osal.c +++ b/os/hal/osal/chibios/osal.c @@ -36,13 +36,6 @@ /* Module exported variables. */ /*===========================================================================*/ -/** - * @brief Pointer to a halt error message. - * @note The message is meant to be retrieved by the debugger after the - * system halt caused by an unexpected error. - */ -const char *osal_halt_msg; - /*===========================================================================*/ /* Module local types. */ /*===========================================================================*/ @@ -59,26 +52,4 @@ const char *osal_halt_msg; /* Module exported functions. */ /*===========================================================================*/ -/** - * @brief OSAL module initialization. - * - * @api - */ -void osalInit(void) { - -} - -/** - * @brief System halt with error message. - * - * @param[in] reason the halt message pointer - * - * @api - */ -void osalSysHalt(const char *reason) { - - osal_halt_msg = reason; - chSysHalt(); -} - /** @} */ diff --git a/os/hal/osal/chibios/osal.h b/os/hal/osal/chibios/osal.h index b3d0fae2b..3633a1f02 100644 --- a/os/hal/osal/chibios/osal.h +++ b/os/hal/osal/chibios/osal.h @@ -55,6 +55,7 @@ #define OSAL_FAILED TRUE /** @} */ +#if 0 /** * @name Messages * @{ @@ -63,6 +64,7 @@ #define MSG_RESET RDY_RESET #define MSG_TIMEOUT RDY_TIMEOUT /** @} */ +#endif #if 0 /** @@ -257,8 +259,7 @@ typedef struct { #ifdef __cplusplus extern "C" { #endif - void osalInit(void); - void osalSysHalt(const char *reason); + #ifdef __cplusplus } #endif @@ -267,6 +268,27 @@ extern "C" { /* Module inline functions. */ /*===========================================================================*/ +/** + * @brief OSAL module initialization. + * + * @api + */ +static inline void osalInit(void) { + +} + +/** + * @brief System halt with error message. + * + * @param[in] reason the halt message pointer + * + * @api + */ +static inline void osalSysHalt(const char *reason) { + + chSysHalt(reason); +} + /** * @brief Enters a critical zone from thread context. * @note This function cannot be used for reentrant critical zones. -- cgit v1.2.3