File tree 3 files changed +46
-31
lines changed
3 files changed +46
-31
lines changed Original file line number Diff line number Diff line change @@ -208,37 +208,6 @@ void _check_stack_sentinel(void)
208
208
}
209
209
#endif
210
210
211
- /*
212
- * Common thread entry point function (used by all threads)
213
- *
214
- * This routine invokes the actual thread entry point function and passes
215
- * it three arguments. It also handles graceful termination of the thread
216
- * if the entry point function ever returns.
217
- *
218
- * This routine does not return, and is marked as such so the compiler won't
219
- * generate preamble code that is only used by functions that actually return.
220
- */
221
- FUNC_NORETURN void _thread_entry (k_thread_entry_t entry ,
222
- void * p1 , void * p2 , void * p3 )
223
- {
224
- entry (p1 , p2 , p3 );
225
-
226
- #ifdef CONFIG_MULTITHREADING
227
- k_thread_abort (k_current_get ());
228
- #else
229
- for (;;) {
230
- k_cpu_idle ();
231
- }
232
- #endif
233
-
234
- /*
235
- * Compiler can't tell that k_thread_abort() won't return and issues a
236
- * warning unless we tell it that control never gets this far.
237
- */
238
-
239
- CODE_UNREACHABLE ;
240
- }
241
-
242
211
#ifdef CONFIG_MULTITHREADING
243
212
void _impl_k_thread_start (struct k_thread * thread )
244
213
{
Original file line number Diff line number Diff line change
1
+ zephyr_sources(thread_entry.c)
1
2
add_subdirectory (crc)
2
3
add_subdirectory_ifdef(CONFIG_JSON_LIBRARY json)
3
4
if (NOT CONFIG_NATIVE_APPLICATION)
Original file line number Diff line number Diff line change
1
+ /*
2
+ * Copyright (c) 2018 Intel Corporation
3
+ *
4
+ * SPDX-License-Identifier: Apache-2.0
5
+ */
6
+
7
+ /**
8
+ * @file
9
+ * @brief Thread entry
10
+ *
11
+ * This file provides the common thread entry function
12
+ */
13
+
14
+ #include <kernel.h>
15
+
16
+ /*
17
+ * Common thread entry point function (used by all threads)
18
+ *
19
+ * This routine invokes the actual thread entry point function and passes
20
+ * it three arguments. It also handles graceful termination of the thread
21
+ * if the entry point function ever returns.
22
+ *
23
+ * This routine does not return, and is marked as such so the compiler won't
24
+ * generate preamble code that is only used by functions that actually return.
25
+ */
26
+ FUNC_NORETURN void _thread_entry (k_thread_entry_t entry ,
27
+ void * p1 , void * p2 , void * p3 )
28
+ {
29
+ entry (p1 , p2 , p3 );
30
+
31
+ #ifdef CONFIG_MULTITHREADING
32
+ k_thread_abort (k_current_get ());
33
+ #else
34
+ for (;;) {
35
+ k_cpu_idle ();
36
+ }
37
+ #endif
38
+
39
+ /*
40
+ * Compiler can't tell that k_thread_abort() won't return and issues a
41
+ * warning unless we tell it that control never gets this far.
42
+ */
43
+
44
+ CODE_UNREACHABLE ;
45
+ }
You can’t perform that action at this time.
0 commit comments