[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20151104221125.GU19782@codeaurora.org>
Date: Wed, 4 Nov 2015 14:11:25 -0800
From: Stephen Boyd <sboyd@...eaurora.org>
To: Viresh Kumar <viresh.kumar@...aro.org>
Cc: Rafael Wysocki <rjw@...ysocki.net>, mturquette@...libre.com,
linaro-kernel@...ts.linaro.org, linux-pm@...r.kernel.org,
Bartlomiej Zolnierkiewicz <b.zolnierkie@...sung.com>,
Dan Carpenter <dan.carpenter@...cle.com>,
Dmitry Torokhov <dtor@...omium.org>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Len Brown <len.brown@...el.com>,
open list <linux-kernel@...r.kernel.org>,
Nishanth Menon <nm@...com>, Pavel Machek <pavel@....cz>
Subject: Re: [PATCH] PM / OPP: Protect updates to list_dev with mutex
On 10/30, Viresh Kumar wrote:
> dev_opp_list_lock is used everywhere to protect device and OPP lists,
> but dev_pm_opp_set_sharing_cpus() is missed somehow. And instead we used
> rcu-lock, which wouldn't help here as we are adding a new list_dev.
>
> This also fixes a problem where we have called kzalloc(..., GFP_KERNEL)
> from within rcu-lock, which isn't allowed as kzalloc can sleep when
> called with GFP_KERNEL.
>
> With CONFIG_DEBUG_ATOMIC_SLEEP set, we will see the caller vomiting.
>
> Fixes: 8d4d4e98acd6 ("PM / OPP: Add helpers for initializing CPU OPPs")
> Reported-by: Michael Turquette <mturquette@...libre.com>
> Signed-off-by: Viresh Kumar <viresh.kumar@...aro.org>
> ---
Reviewed-by: Stephen Boyd <sboyd@...eaurora.org>
I assume some other patch will come to fix the comment and/or add
the lockdep check.
--
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum,
a Linux Foundation Collaborative Project
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists