Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\sched\fair.c Create Date:2022-07-28 09:38:25
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:reweight_task

Proto:void reweight_task(struct task_struct *p, int prio)

Type:void

Parameter:

TypeParameterName
struct task_struct *p
intprio
2914  se = se
2915  cfs_rq = cfs_rq_of(se)
2916  load = For load-balancing:
2917  weight = scale_load(Nice levels are multiplicative, with a gentle 10% change for every* nice level changed[prio])
2919  reweight_entity(cfs_rq, se, weight, weight)
2920  inv_weight = Inverse (2^32/x) values of the sched_prio_to_weight[] array, precalculated.* In cases where the weight does not change often, we can use the* precalculated inverse to speed up arithmetics by turning divisions* into multiplications:[prio]