From 64940cb4a748fd179e7e36f8404db8a56be77ec7 Mon Sep 17 00:00:00 2001 From: Giovanni Di Sirio Date: Thu, 24 Dec 2020 15:06:58 +0000 Subject: [PATCH] MISRA-related fixes. git-svn-id: svn://svn.code.sf.net/p/chibios/svn/branches/stable_20.3.x@13980 27425a3e-05d8-49a3-a47f-9c15f0e5edd8 --- os/rt/include/chschd.h | 23 +++++++++-------------- 1 file changed, 9 insertions(+), 14 deletions(-) diff --git a/os/rt/include/chschd.h b/os/rt/include/chschd.h index 90c468cd8..9b0a40a79 100644 --- a/os/rt/include/chschd.h +++ b/os/rt/include/chschd.h @@ -119,11 +119,11 @@ /*===========================================================================*/ /** - * @brief Type of a threads queue. + * @brief Structure representing a threads queue. */ -typedef struct ch_threads_queue { +struct ch_threads_queue { ch_queue_t queue; /**< @brief Threads queue header. */ -} threads_queue_t; +}; /** * @brief Structure representing a thread. @@ -301,11 +301,6 @@ struct ch_thread { #endif }; -/** - * @brief Type of a Virtual Timer callback function. - */ -typedef void (*vtfunc_t)(void *p); - /** * @brief Type of a Virtual Timer structure. */ @@ -321,23 +316,23 @@ struct ch_delta_list { }; /** - * @brief Type of a Virtual Timer. + * @brief Structure representing a Virtual Timer. */ -typedef struct ch_virtual_timer { +struct ch_virtual_timer { delta_list_t dlist; /**< @brief Delta list element. */ vtfunc_t func; /**< @brief Timer callback function pointer. */ void *par; /**< @brief Timer callback function parameter. */ -} virtual_timer_t; +}; /** - * @brief Type of virtual timers list header. + * @brief Structure representing a virtual timers list header. * @note The timers list is implemented as a double link bidirectional list * in order to make the unlink time constant, the reset of a virtual * timer is often used in the code. */ -typedef struct ch_virtual_timers_list { +struct ch_virtual_timers_list { delta_list_t dlist; /**< @brief Delta list header. */ #if (CH_CFG_ST_TIMEDELTA == 0) || defined(__DOXYGEN__) volatile systime_t systime; /**< @brief System Time counter. */ @@ -349,7 +344,7 @@ typedef struct ch_virtual_timers_list { systime_t lasttime; /**< @brief System time of the last tick event. */ #endif -} virtual_timers_list_t; +}; /** * @extends threads_queue_t