summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorShell <[email protected]>2024-05-01 00:17:56 +0800
committerMeco Man <[email protected]>2024-10-19 15:19:41 -0400
commit645b3c6015f7e96cec418a11c5492ba479715995 (patch)
treea23be7bfcdb6f46781b2204de2e3507c7d6c0d5f /include
parent76adf376db3ed6034fd1a19f053e1e48a08ff428 (diff)
feat: remove RT_USING_SCHED_THREAD_CTX
Prepare for the next release by removing the compatible codes for v5.1.0 and before. Changes: - Remove the compatible macros and Kconfig options for the old struct rt_thread layout. Signed-off-by: Shell <[email protected]>
Diffstat (limited to 'include')
-rw-r--r--include/rtsched.h43
1 files changed, 2 insertions, 41 deletions
diff --git a/include/rtsched.h b/include/rtsched.h
index d650e09e37..01951a2611 100644
--- a/include/rtsched.h
+++ b/include/rtsched.h
@@ -1,11 +1,11 @@
/*
- * Copyright (c) 2023-2024 RT-Thread Development Team
+ * Copyright (c) 2023-2024, RT-Thread Development Team
*
* SPDX-License-Identifier: Apache-2.0
*
* Change Logs:
* Date Author Notes
- * 2024-01-19 Shell Seperate schduling statements from rt_thread_t
+ * 2024-01-19 Shell Separate scheduling statements from rt_thread_t
* to rt_sched_thread_ctx. Add definitions of scheduler.
*/
#ifndef __RT_SCHED_H__
@@ -22,8 +22,6 @@ struct rt_thread;
typedef rt_uint8_t rt_sched_thread_status_t;
-#ifdef RT_USING_SCHED_THREAD_CTX
-
/**
* Scheduler private status binding on thread. Caller should never accessing
* these members.
@@ -85,43 +83,6 @@ struct rt_sched_thread_ctx
struct rt_thread, sched_thread_ctx)
#define RT_THREAD_LIST_NODE(thread) (RT_SCHED_CTX(thread).thread_list_node)
-#else /* !defined(RT_USING_SCHED_THREAD_CTX) */
-
-#if RT_THREAD_PRIORITY_MAX > 32
-#define _RT_SCHED_THREAD_CTX_PRIO_EXT \
- rt_uint8_t number; /**< priority low number */ \
- rt_uint8_t high_mask; /**< priority high mask */
-
-#else /* ! RT_THREAD_PRIORITY_MAX > 32 */
-
-#define _RT_SCHED_THREAD_CTX_PRIO_EXT
-#endif /* RT_THREAD_PRIORITY_MAX > 32 */
-
-#define RT_SCHED_THREAD_CTX \
- rt_list_t tlist; /**< node in thread list */ \
- rt_uint8_t stat; /**< thread status */ \
- rt_uint8_t sched_flag_locked:1; \
- /**< calling thread have the scheduler locked */ \
- rt_uint8_t sched_flag_ttmr_set:1; /**< thread timer is start */ \
- rt_tick_t init_tick; /**< thread's initialized tick */ \
- rt_tick_t remaining_tick; /**< remaining tick */ \
- rt_uint8_t current_priority; /**< current priority */ \
- rt_uint8_t init_priority; /**< initialized priority */ \
- _RT_SCHED_THREAD_CTX_PRIO_EXT \
- rt_uint32_t number_mask; /**< priority number mask */
-
-#define RT_SCHED_PRIV(thread) (*thread)
-#define RT_SCHED_CTX(thread) (*thread)
-
-/**
- * Convert a list node in container RT_SCHED_CTX(thread)->thread_list_node
- * to a thread pointer.
- */
-#define RT_THREAD_LIST_NODE_ENTRY(node) rt_list_entry((node), struct rt_thread, tlist)
-#define RT_THREAD_LIST_NODE(thread) (RT_SCHED_CTX(thread).tlist)
-
-#endif /* RT_USING_SCHED_THREAD_CTX */
-
/**
* System Scheduler Locking
*/