[lkml]   [2017]   [Sep]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH V2] PM / OPP: Call notifier without holding opp_table->lock
Hi Viresh,

On 2017년 09월 21일 05:25, Viresh Kumar wrote:
> The notifier callbacks may want to call some OPP helper routines which
> may try to take the same opp_table->lock again and cause a deadlock. One
> such usecase was reported by Chanwoo Choi, where calling
> dev_pm_opp_disable() leads us to the devfreq's OPP notifier handler,
> which further calls dev_pm_opp_find_freq_floor() and it deadlocks.
> We don't really need the opp_table->lock to be held across the notifier
> call though, all we want to make sure is that the 'opp' doesn't get
> freed while being used from within the notifier chain. We can do it with
> help of dev_pm_opp_get/put() as well. Let's do it.
> Reported-by: Chanwoo Choi <>
> Reviewed-by: Stephen Boyd <>
> Signed-off-by: Viresh Kumar <>
> ---
> V1->V2:
> - s/Lets/Let's/ in commit log and added Stephen's tag.

Thanks for your fixup. Looks good to me.
IMHO, this patch should be posted to

Tested-by: Chanwoo Choi <>
Reviewed-by: Chanwoo Choi <>


Best Regards,
Chanwoo Choi
Samsung Electronics

 \ /
  Last update: 2017-09-21 19:26    [W:0.040 / U:1.084 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site