In Linux when a new process is created, it inherits the normal_prio value of it’s parent process for it’s static_prio. Where does this actually happen??
Is it done in dup_task_struct() function or in copy_process() function??
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
It actually happens in sched_fork which is called by copy_process
The parent’s priority is transferred into the child initially something like this
where p is child’s
task_structandcurrentpoints to parent.And then
normal_priois modified like this__normal_prio(p)finally boils down to something likeCheck out the 2 links I’ve added to explore more.