lkml.org 
[lkml]   [2013]   [Nov]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2] sched: Check sched_domain before computing group power.
* Preeti Murthy <preeti.lkml@gmail.com> [2013-11-13 16:22:37]:

> Hi Srikar,
>
> update_group_power() is called only during load balancing during
> update_sg_lb_stats().
> Load balancing begins at the base domain of the CPU,rq(cpu)->sd. This is
> checked for
> NULL. So how can update_group_power() be called in a scenario where the
> base domain
> of the CPU is not initialized? I say 'initialized' since you check for NULL
> on rq(cpu)->sd.
>

update_group_power() also gets called from init_sched_groups_power().
And if you see the oops message, we know that the oops happens from that
path. In build_sched_domains(), we do cpu_attach_domain() what updates
rq->sd after the call to init_sched_groups_power(). So by the time
init_sched_groups_power() is called rq->sd is not yet initialized.

We only hit oops case, when the sd->flags has SD_OVERLAP set.



> In the changelog, you say 'updated'. Are you saying that it has a stale
> value?

I said, "before the sched_domain for a cpu is updated", so its not yet
updated or has stale value. As I said earlier in this mail, the
initialization happens after we do a update_group_power().

> Please do elaborate on how you observed this.
>

Does this clarify?

--
Thanks and Regards
Srikar Dronamraju



\
 
 \ /
  Last update: 2013-11-13 12:41    [W:0.224 / U:0.328 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site