Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1450196

Re: [PATCH v3] PM / OPP: optimize dev_pm_opp_set_rate() performance a bit

From Viresh Kumar <viresh.kumar@linaro.org>
Newsgroups linux.kernel
Subject Re: [PATCH v3] PM / OPP: optimize dev_pm_opp_set_rate() performance a bit
Date 2016-07-26 00:40 +0200
Message-ID <rYWHx-2cA-81@gated-at.bofh.it> (permalink)
References <rYHp7-16r-9@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On 25-07-16, 14:11, Jisheng Zhang wrote:
> In dev_pm_opp_set_rate(), _find_opp_table() is called 4 times: once by
> _get_opp_clk(), once by dev_pm_opp_set_rate() itself, and twice by
> dev_pm_opp_find_freq_ceil(). If there are several opp_tables in the
> system, three times of opp table finding is a big waste. This patch
> reduced the call of _find_opp_table() to twice.
> 
> Signed-off-by: Jisheng Zhang <jszhang@marvell.com>
> ---
> Since v2:
>  - fix gcc warnings
> 
> Since v1:
>  - avoid opp_table pointer usage after the rcu_read_unlock() as pointed
>    out by Viresh, thus we can only reduced the call of _find_opp_table
>    to twice.
> 
>  drivers/base/power/opp/core.c | 31 +++++++++++++++++++------------
>  1 file changed, 19 insertions(+), 12 deletions(-)

Acked-by: Viresh Kumar <viresh.kumar@linaro.org>

-- 
viresh

Back to linux.kernel | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

[PATCH v3] PM / OPP: optimize dev_pm_opp_set_rate() performance a bit Jisheng Zhang <jszhang@marvell.com> - 2016-07-25 08:20 +0200
  Re: [PATCH v3] PM / OPP: optimize dev_pm_opp_set_rate() performance  a bit Viresh Kumar <viresh.kumar@linaro.org> - 2016-07-26 00:40 +0200

csiph-web