kernel_samsung_a34x-permissive/kernel/sched/tune.h
2024-04-28 15:49:01 +02:00

45 lines
1 KiB
C
Executable file

#ifdef CONFIG_SCHED_TUNE
#include <linux/reciprocal_div.h>
/*
* System energy normalization constants
*/
struct target_nrg {
unsigned long min_power;
unsigned long max_power;
struct reciprocal_value rdiv;
};
int schedtune_cpu_boost(int cpu);
int schedtune_task_boost(struct task_struct *tsk);
int schedtune_prefer_idle(struct task_struct *tsk);
void schedtune_enqueue_task(struct task_struct *p, int cpu);
void schedtune_dequeue_task(struct task_struct *p, int cpu);
unsigned long stune_util(int cpu, unsigned long other_util);
#ifdef CONFIG_UCLAMP_TASK_GROUP
extern struct schedtune root_schedtune;
struct uclamp_se
uclamp_st_restrict(struct task_struct *p, enum uclamp_id clamp_id);
void init_root_st_uclamp(int clamp_id);
void uclamp_update_root_st(void);
#endif
#else /* CONFIG_SCHED_TUNE */
#define schedtune_cpu_boost(cpu) 0
#define schedtune_task_boost(tsk) 0
#define schedtune_prefer_idle(tsk) 0
#define schedtune_enqueue_task(task, cpu) do { } while (0)
#define schedtune_dequeue_task(task, cpu) do { } while (0)
#endif /* CONFIG_SCHED_TUNE */