Messages in this thread | | | Date | Thu, 23 Apr 2020 20:41:22 -0400 | From | Steven Rostedt <> | Subject | Re: [PATCH] sched: make p->prio independent of p->mm |
| |
On Fri, 24 Apr 2020 08:30:28 +0800 Hillf Danton <hdanton@sina.com> wrote:
> > I believe Peter meant axing the double check, not the check together. > > > > That is, instead of: > > > > if (p->flags & PF_KTHREAD) { > > if (attr->sched_priority > MAX_RT_PRIO - 1) > > return -EINVAL; > > } else { > > if (attr->sched_priority > MAX_USER_RT_PRIO - 1) > > return -EINVAL; > > } > > > > Just have: > > > > if (attr->sched_priority > MAX_RT_PRIO -1) > > return -EINVAL; > > > Got it, thank you :) Spin in couple of days.
I still think getting rid of MAX_USER_RT_PRIO would be good too.
-- Steve
| |