mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-12-02 00:24:12 +08:00
325ea10c08
Do the following cleanups and simplifications: - sched/sched.h already includes <asm/paravirt.h>, so no need to include it in sched/core.c again. - order the <linux/sched/*.h> headers alphabetically - add all <linux/sched/*.h> headers to kernel/sched/sched.h - remove all unnecessary includes from the .c files that are already included in kernel/sched/sched.h. Finally, make all scheduler .c files use a single common header: #include "sched.h" ... which now contains a union of the relied upon headers. This makes the various .c files easier to read and easier to handle. Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-kernel@vger.kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org>
27 lines
637 B
C
27 lines
637 B
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
|
|
#define IDX_INVALID -1
|
|
|
|
struct cpudl_item {
|
|
u64 dl;
|
|
int cpu;
|
|
int idx;
|
|
};
|
|
|
|
struct cpudl {
|
|
raw_spinlock_t lock;
|
|
int size;
|
|
cpumask_var_t free_cpus;
|
|
struct cpudl_item *elements;
|
|
};
|
|
|
|
#ifdef CONFIG_SMP
|
|
int cpudl_find(struct cpudl *cp, struct task_struct *p, struct cpumask *later_mask);
|
|
void cpudl_set(struct cpudl *cp, int cpu, u64 dl);
|
|
void cpudl_clear(struct cpudl *cp, int cpu);
|
|
int cpudl_init(struct cpudl *cp);
|
|
void cpudl_set_freecpu(struct cpudl *cp, int cpu);
|
|
void cpudl_clear_freecpu(struct cpudl *cp, int cpu);
|
|
void cpudl_cleanup(struct cpudl *cp);
|
|
#endif /* CONFIG_SMP */
|