Loading include/linux/sched/sysctl.h +1 −1 Original line number Original line Diff line number Diff line Loading @@ -131,6 +131,6 @@ extern int sched_little_cluster_coloc_fmin_khz_handler(struct ctl_table *table, extern char sched_lib_name[LIB_PATH_LENGTH]; extern char sched_lib_name[LIB_PATH_LENGTH]; extern unsigned int sched_lib_mask_force; extern unsigned int sched_lib_mask_force; extern bool is_sched_lib_based_app(pid_t pid); extern bool is_sched_lib_based_app(pid_t pid); extern unsigned long *sched_busy_hysteresis_cpubits; extern unsigned int sysctl_sched_busy_hysteresis_enable_cpus; #endif /* _LINUX_SCHED_SYSCTL_H */ #endif /* _LINUX_SCHED_SYSCTL_H */ kernel/sched/sched_avg.c +2 −4 Original line number Original line Diff line number Diff line Loading @@ -26,9 +26,7 @@ static DEFINE_PER_CPU(unsigned long, iowait_prod_sum); static DEFINE_PER_CPU(spinlock_t, nr_lock) = __SPIN_LOCK_UNLOCKED(nr_lock); static DEFINE_PER_CPU(spinlock_t, nr_lock) = __SPIN_LOCK_UNLOCKED(nr_lock); static s64 last_get_time; static s64 last_get_time; static struct cpumask sched_busy_hysteresis_cpumask; unsigned int sysctl_sched_busy_hysteresis_enable_cpus; unsigned long *sched_busy_hysteresis_cpubits = cpumask_bits(&sched_busy_hysteresis_cpumask); static DEFINE_PER_CPU(atomic64_t, last_busy_time) = ATOMIC64_INIT(0); static DEFINE_PER_CPU(atomic64_t, last_busy_time) = ATOMIC64_INIT(0); #define NR_THRESHOLD_PCT 15 #define NR_THRESHOLD_PCT 15 Loading Loading @@ -107,7 +105,7 @@ static inline void update_last_busy_time(int cpu, bool dequeue, { { bool nr_run_trigger = false, load_trigger = false; bool nr_run_trigger = false, load_trigger = false; if (!cpumask_test_cpu(cpu, &sched_busy_hysteresis_cpumask)) if (!(BIT(cpu) & sysctl_sched_busy_hysteresis_enable_cpus)) return; return; if (prev_nr_run >= BUSY_NR_RUN && per_cpu(nr, cpu) < BUSY_NR_RUN) if (prev_nr_run >= BUSY_NR_RUN && per_cpu(nr, cpu) < BUSY_NR_RUN) Loading kernel/sysctl.c +5 −3 Original line number Original line Diff line number Diff line Loading @@ -443,10 +443,12 @@ static struct ctl_table kern_table[] = { }, }, { { .procname = "sched_busy_hysteresis_enable_cpus", .procname = "sched_busy_hysteresis_enable_cpus", .data = &sched_busy_hysteresis_cpubits, .data = &sysctl_sched_busy_hysteresis_enable_cpus, .maxlen = NR_CPUS, .maxlen = sizeof(unsigned int), .mode = 0644, .mode = 0644, .proc_handler = proc_do_large_bitmap, .proc_handler = proc_douintvec_minmax, .extra1 = &zero, .extra2 = &two_hundred_fifty_five, }, }, #endif #endif #ifdef CONFIG_SCHED_DEBUG #ifdef CONFIG_SCHED_DEBUG Loading Loading
include/linux/sched/sysctl.h +1 −1 Original line number Original line Diff line number Diff line Loading @@ -131,6 +131,6 @@ extern int sched_little_cluster_coloc_fmin_khz_handler(struct ctl_table *table, extern char sched_lib_name[LIB_PATH_LENGTH]; extern char sched_lib_name[LIB_PATH_LENGTH]; extern unsigned int sched_lib_mask_force; extern unsigned int sched_lib_mask_force; extern bool is_sched_lib_based_app(pid_t pid); extern bool is_sched_lib_based_app(pid_t pid); extern unsigned long *sched_busy_hysteresis_cpubits; extern unsigned int sysctl_sched_busy_hysteresis_enable_cpus; #endif /* _LINUX_SCHED_SYSCTL_H */ #endif /* _LINUX_SCHED_SYSCTL_H */
kernel/sched/sched_avg.c +2 −4 Original line number Original line Diff line number Diff line Loading @@ -26,9 +26,7 @@ static DEFINE_PER_CPU(unsigned long, iowait_prod_sum); static DEFINE_PER_CPU(spinlock_t, nr_lock) = __SPIN_LOCK_UNLOCKED(nr_lock); static DEFINE_PER_CPU(spinlock_t, nr_lock) = __SPIN_LOCK_UNLOCKED(nr_lock); static s64 last_get_time; static s64 last_get_time; static struct cpumask sched_busy_hysteresis_cpumask; unsigned int sysctl_sched_busy_hysteresis_enable_cpus; unsigned long *sched_busy_hysteresis_cpubits = cpumask_bits(&sched_busy_hysteresis_cpumask); static DEFINE_PER_CPU(atomic64_t, last_busy_time) = ATOMIC64_INIT(0); static DEFINE_PER_CPU(atomic64_t, last_busy_time) = ATOMIC64_INIT(0); #define NR_THRESHOLD_PCT 15 #define NR_THRESHOLD_PCT 15 Loading Loading @@ -107,7 +105,7 @@ static inline void update_last_busy_time(int cpu, bool dequeue, { { bool nr_run_trigger = false, load_trigger = false; bool nr_run_trigger = false, load_trigger = false; if (!cpumask_test_cpu(cpu, &sched_busy_hysteresis_cpumask)) if (!(BIT(cpu) & sysctl_sched_busy_hysteresis_enable_cpus)) return; return; if (prev_nr_run >= BUSY_NR_RUN && per_cpu(nr, cpu) < BUSY_NR_RUN) if (prev_nr_run >= BUSY_NR_RUN && per_cpu(nr, cpu) < BUSY_NR_RUN) Loading
kernel/sysctl.c +5 −3 Original line number Original line Diff line number Diff line Loading @@ -443,10 +443,12 @@ static struct ctl_table kern_table[] = { }, }, { { .procname = "sched_busy_hysteresis_enable_cpus", .procname = "sched_busy_hysteresis_enable_cpus", .data = &sched_busy_hysteresis_cpubits, .data = &sysctl_sched_busy_hysteresis_enable_cpus, .maxlen = NR_CPUS, .maxlen = sizeof(unsigned int), .mode = 0644, .mode = 0644, .proc_handler = proc_do_large_bitmap, .proc_handler = proc_douintvec_minmax, .extra1 = &zero, .extra2 = &two_hundred_fifty_five, }, }, #endif #endif #ifdef CONFIG_SCHED_DEBUG #ifdef CONFIG_SCHED_DEBUG Loading