lkml.org 
[lkml]   [2014]   [Oct]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH 2/2] PM / Domains: Extract code to power off/on a PM domain
From
On 23 October 2014 14:12, Geert Uytterhoeven <geert+renesas@glider.be> wrote:
> PM domains are powered on/off from various places. Some callers do
> latency measurements, others don't. Consolidate using two helper
> functions, which always measure the latencies, and update the stored
> latencies when needed.
>
> Other minor changes:
> - Use pr_warn() instead of pr_warning(),
> - There's no need to check genpd->name, %s handles NULL pointers fine,
> - Make the warning format strings identical, to save memory.
>
> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>

Reviewed-by: Ulf Hansson <ulf.hansson@linaro.org>

Though, some minor thoughts below.

> ---
> drivers/base/power/domain.c | 101 ++++++++++++++++++++++++++------------------
> 1 file changed, 60 insertions(+), 41 deletions(-)
>
> diff --git a/drivers/base/power/domain.c b/drivers/base/power/domain.c
> index 28d6e8bf746c4683..7b2007be51188ff8 100644
> --- a/drivers/base/power/domain.c
> +++ b/drivers/base/power/domain.c
> @@ -151,6 +151,59 @@ static void genpd_recalc_cpu_exit_latency(struct generic_pm_domain *genpd)
> genpd->cpuidle_data->idle_state->exit_latency = usecs64;
> }
>
> +static int do_genpd_power_on(struct generic_pm_domain *genpd)

Should we try to agree on the prefixes of the function names in genpd?
Currently there are a mix of them.

May I suggest we try to stick to this:

Exported functions:
pm_genpd_*
_pm_genpd_*
__pm_genpd_*

Static functions:
genpd_*
_genpd_*
__genpd_*

What do you think? Do you have any better suggestions?

Kind regards
Uffe


\
 
 \ /
  Last update: 2014-10-29 15:01    [W:0.044 / U:3.568 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site