From: Lukasz Luba <lukasz.luba@arm.com>
To: Beata Michalska <beata.michalska@arm.com>,
linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org
Cc: vireshk@kernel.org, nm@ti.com, sboyd@kernel.org
Subject: Re: [PATCH] opp: Invalidate current opp when draining the opp list
Date: Thu, 4 Mar 2021 17:27:46 +0000 [thread overview]
Message-ID: <2ffd8863-9ea9-85dd-60a9-035d21e2ee11@arm.com> (raw)
In-Reply-To: <1614870454-18709-1-git-send-email-beata.michalska@arm.com>
Hi Beata,
On 3/4/21 3:07 PM, Beata Michalska wrote:
> The current_opp when set, grabs additional reference on the opp,
> which is then supposed to be dropped upon releasing the opp table.
> Still both dev_pm_opp_remove_table and dev_pm_opp_remove_all_dynamic
> will completely drain the OPPs list, including dropping the additional
> reference on current_opp. This may lead to an attempt to access
> memory that has already been released. Make sure that while draining
> the list (in both dynamic and static cases) the current_opp gets
> actually invalidated.
>
> Fixes: 81c4d8a3c414 ("opp: Keep track of currently programmed OPP")
>
> Signed-off-by: Beata Michalska <beata.michalska@arm.com>
> ---
> drivers/opp/core.c | 49 ++++++++++++++++++++++++++++++++-----------------
> 1 file changed, 32 insertions(+), 17 deletions(-)
The change looks good.
Reviewed-by: Lukasz Luba <lukasz.luba@arm.com>
Regards,
Lukasz
next prev parent reply other threads:[~2021-03-04 17:29 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-04 15:07 [PATCH] opp: Invalidate current opp when draining the opp list Beata Michalska
2021-03-04 17:27 ` Lukasz Luba [this message]
2021-03-05 4:24 ` Viresh Kumar
2021-03-05 13:55 ` Beata Michalska
2021-03-08 11:50 ` Viresh Kumar
2021-03-08 18:14 ` Beata Michalska
2021-03-09 4:31 ` Viresh Kumar
2021-03-09 12:14 ` Beata Michalska
2021-03-10 8:47 ` Viresh Kumar
2021-03-10 23:03 ` Beata Michalska
2021-03-12 3:49 ` Viresh Kumar
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=2ffd8863-9ea9-85dd-60a9-035d21e2ee11@arm.com \
--to=lukasz.luba@arm.com \
--cc=beata.michalska@arm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=nm@ti.com \
--cc=sboyd@kernel.org \
--cc=vireshk@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).