• Home
  • Raw
  • Download

Lines Matching refs:policy

2062 static inline int __normal_prio(int policy, int rt_prio, int nice)  in __normal_prio()  argument
2066 if (dl_policy(policy)) in __normal_prio()
2068 else if (rt_policy(policy)) in __normal_prio()
2085 return __normal_prio(p->policy, p->rt_priority, PRIO_TO_NICE(p->static_prio)); in normal_prio()
4513 p->policy = SCHED_NORMAL; in sched_fork()
7412 int policy = attr->sched_policy; in __setscheduler_params() local
7414 if (policy == SETPARAM_POLICY) in __setscheduler_params()
7415 policy = p->policy; in __setscheduler_params()
7417 p->policy = policy; in __setscheduler_params()
7419 if (dl_policy(policy)) in __setscheduler_params()
7421 else if (fair_policy(policy)) in __setscheduler_params()
7454 int oldpolicy = -1, policy = attr->sched_policy; in __sched_setscheduler() local
7468 if (policy < 0) { in __sched_setscheduler()
7470 policy = oldpolicy = p->policy; in __sched_setscheduler()
7474 if (!valid_policy(policy)) in __sched_setscheduler()
7488 if ((dl_policy(policy) && !__checkparam_dl(attr)) || in __sched_setscheduler()
7489 (rt_policy(policy) != (attr->sched_priority != 0))) in __sched_setscheduler()
7496 if (fair_policy(policy)) { in __sched_setscheduler()
7502 if (rt_policy(policy)) { in __sched_setscheduler()
7507 if (policy != p->policy && !rlim_rtprio) in __sched_setscheduler()
7522 if (dl_policy(policy)) in __sched_setscheduler()
7529 if (task_has_idle_policy(p) && !idle_policy(policy)) { in __sched_setscheduler()
7567 if (dl_policy(policy) || dl_policy(p->policy)) { in __sched_setscheduler()
7594 if (unlikely(policy == p->policy)) { in __sched_setscheduler()
7595 if (fair_policy(policy) && attr->sched_nice != task_nice(p)) in __sched_setscheduler()
7597 if (rt_policy(policy) && attr->sched_priority != p->rt_priority) in __sched_setscheduler()
7599 if (dl_policy(policy) && dl_param_changed(p, attr)) in __sched_setscheduler()
7616 if (rt_bandwidth_enabled() && rt_policy(policy) && in __sched_setscheduler()
7624 if (dl_bandwidth_enabled() && dl_policy(policy) && in __sched_setscheduler()
7643 if (unlikely(oldpolicy != -1 && oldpolicy != p->policy)) { in __sched_setscheduler()
7644 policy = oldpolicy = -1; in __sched_setscheduler()
7656 if ((dl_policy(policy) || dl_task(p)) && sched_dl_overflow(p, policy, attr)) { in __sched_setscheduler()
7664 newprio = __normal_prio(policy, attr->sched_priority, attr->sched_nice); in __sched_setscheduler()
7732 static int _sched_setscheduler(struct task_struct *p, int policy, in _sched_setscheduler() argument
7736 .sched_policy = policy, in _sched_setscheduler()
7742 if ((policy != SETPARAM_POLICY) && (policy & SCHED_RESET_ON_FORK)) { in _sched_setscheduler()
7744 policy &= ~SCHED_RESET_ON_FORK; in _sched_setscheduler()
7745 attr.sched_policy = policy; in _sched_setscheduler()
7762 int sched_setscheduler(struct task_struct *p, int policy, in sched_setscheduler() argument
7765 return _sched_setscheduler(p, policy, param, true); in sched_setscheduler()
7794 int sched_setscheduler_nocheck(struct task_struct *p, int policy, in sched_setscheduler_nocheck() argument
7797 return _sched_setscheduler(p, policy, param, false); in sched_setscheduler_nocheck()
7847 do_sched_setscheduler(pid_t pid, int policy, struct sched_param __user *param) in do_sched_setscheduler() argument
7862 retval = sched_setscheduler(p, policy, &lparam); in do_sched_setscheduler()
7931 SYSCALL_DEFINE3(sched_setscheduler, pid_t, pid, int, policy, struct sched_param __user *, param) in SYSCALL_DEFINE3() argument
7933 if (policy < 0) in SYSCALL_DEFINE3()
7936 return do_sched_setscheduler(pid, policy, param); in SYSCALL_DEFINE3()
8014 retval = p->policy in SYSCALL_DEFINE1()
8131 kattr.sched_policy = p->policy; in SYSCALL_DEFINE4()
8654 SYSCALL_DEFINE1(sched_get_priority_max, int, policy) in SYSCALL_DEFINE1() argument
8658 switch (policy) { in SYSCALL_DEFINE1()
8681 SYSCALL_DEFINE1(sched_get_priority_min, int, policy) in SYSCALL_DEFINE1() argument
8685 switch (policy) { in SYSCALL_DEFINE1()