Greg Kroah-Hartman | b244131 | 2017-11-01 15:07:57 +0100 | [diff] [blame] | 1 | /* SPDX-License-Identifier: GPL-2.0 */ |
Thomas Gleixner | 38498a6 | 2012-04-20 13:05:44 +0000 | [diff] [blame] | 2 | #ifndef SMPBOOT_H |
| 3 | #define SMPBOOT_H |
| 4 | |
Thomas Gleixner | 29d5e04 | 2012-04-20 13:05:45 +0000 | [diff] [blame] | 5 | struct task_struct; |
| 6 | |
Thomas Gleixner | 29d5e04 | 2012-04-20 13:05:45 +0000 | [diff] [blame] | 7 | #ifdef CONFIG_GENERIC_SMP_IDLE_THREAD |
| 8 | struct task_struct *idle_thread_get(unsigned int cpu); |
| 9 | void idle_thread_set_boot_cpu(void); |
Suresh Siddha | 3bb5d2e | 2012-04-20 17:08:50 -0700 | [diff] [blame] | 10 | void idle_threads_init(void); |
Thomas Gleixner | 29d5e04 | 2012-04-20 13:05:45 +0000 | [diff] [blame] | 11 | #else |
| 12 | static inline struct task_struct *idle_thread_get(unsigned int cpu) { return NULL; } |
| 13 | static inline void idle_thread_set_boot_cpu(void) { } |
Thomas Gleixner | 43a18b1 | 2012-05-04 12:52:25 +0200 | [diff] [blame] | 14 | static inline void idle_threads_init(void) { } |
Thomas Gleixner | 29d5e04 | 2012-04-20 13:05:45 +0000 | [diff] [blame] | 15 | #endif |
| 16 | |
Thomas Gleixner | f97f8f0 | 2012-07-16 10:42:36 +0000 | [diff] [blame] | 17 | int smpboot_create_threads(unsigned int cpu); |
Thomas Gleixner | 931ef16 | 2016-02-26 18:43:36 +0000 | [diff] [blame] | 18 | int smpboot_park_threads(unsigned int cpu); |
| 19 | int smpboot_unpark_threads(unsigned int cpu); |
Thomas Gleixner | f97f8f0 | 2012-07-16 10:42:36 +0000 | [diff] [blame] | 20 | |
Thomas Gleixner | 4cb28ce | 2016-02-26 18:43:38 +0000 | [diff] [blame] | 21 | void __init cpuhp_threads_init(void); |
| 22 | |
Thomas Gleixner | 38498a6 | 2012-04-20 13:05:44 +0000 | [diff] [blame] | 23 | #endif |