|
|
@@ -7437,10 +7437,10 @@ static void update_cfs_rq_h_load(struct cfs_rq *cfs_rq)
|
|
|
if (cfs_rq->last_h_load_update == now)
|
|
|
return;
|
|
|
|
|
|
- cfs_rq->h_load_next = NULL;
|
|
|
+ WRITE_ONCE(cfs_rq->h_load_next, NULL);
|
|
|
for_each_sched_entity(se) {
|
|
|
cfs_rq = cfs_rq_of(se);
|
|
|
- cfs_rq->h_load_next = se;
|
|
|
+ WRITE_ONCE(cfs_rq->h_load_next, se);
|
|
|
if (cfs_rq->last_h_load_update == now)
|
|
|
break;
|
|
|
}
|
|
|
@@ -7450,7 +7450,7 @@ static void update_cfs_rq_h_load(struct cfs_rq *cfs_rq)
|
|
|
cfs_rq->last_h_load_update = now;
|
|
|
}
|
|
|
|
|
|
- while ((se = cfs_rq->h_load_next) != NULL) {
|
|
|
+ while ((se = READ_ONCE(cfs_rq->h_load_next)) != NULL) {
|
|
|
load = cfs_rq->h_load;
|
|
|
load = div64_ul(load * se->avg.load_avg,
|
|
|
cfs_rq_load_avg(cfs_rq) + 1);
|