From 6823a5110b71d36caa21bab389656d463c863db7 Mon Sep 17 00:00:00 2001 From: Bernard Xiong Date: Sun, 16 Oct 2022 17:58:51 +0800 Subject: [Kernel] Add prioceiling feature in mutex --- include/rtdef.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'include/rtdef.h') diff --git a/include/rtdef.h b/include/rtdef.h index 12232c2d5c..57401115d9 100644 --- a/include/rtdef.h +++ b/include/rtdef.h @@ -771,11 +771,13 @@ struct rt_mutex { struct rt_ipc_object parent; /**< inherit from ipc_object */ + rt_uint8_t ceiling_priority; /**< the priority ceiling of mutexe */ rt_uint8_t priority; /**< the maximal priority for pending thread */ rt_uint8_t hold; /**< numbers of thread hold the mutex */ + rt_uint8_t reserv; struct rt_thread *owner; /**< current owner of mutex */ - rt_list_t taken_list; /**< the object list taken by thread */ + rt_list_t taken_list; /**< the object list taken by thread */ }; typedef struct rt_mutex *rt_mutex_t; #endif /* RT_USING_MUTEX */ -- cgit v1.3.1