lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAMuHMdWA+KeEoS+79Qos958r=4rWGN_ZeAbhP9FB5ZoEoQKqpQ@mail.gmail.com>
Date:	Wed, 29 Oct 2014 14:32:30 +0100
From:	Geert Uytterhoeven <geert@...ux-m68k.org>
To:	Ulf Hansson <ulf.hansson@...aro.org>
Cc:	Geert Uytterhoeven <geert+renesas@...der.be>,
	"Rafael J. Wysocki" <rjw@...ysocki.net>,
	Pavel Machek <pavel@....cz>, Len Brown <len.brown@...el.com>,
	"linux-pm@...r.kernel.org" <linux-pm@...r.kernel.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 2/2] PM / Domains: Extract code to power off/on a PM domain

Hi Ulf,

On Wed, Oct 29, 2014 at 2:25 PM, Ulf Hansson <ulf.hansson@...aro.org> wrote:
> On 23 October 2014 14:12, Geert Uytterhoeven <geert+renesas@...der.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@...der.be>
>
> Reviewed-by: Ulf Hansson <ulf.hansson@...aro.org>

Thanks for your review.

>> --- 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?

Sounds sane.

So:

s/do_genpd_power_on/genpd_power_on/
s/do_genpd_power_off/genpd_power_off/

(somehow I thought the latter were already in use, but I was wrong)

Note that there are lots of static pm_genpd_*() functions.

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@...ux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds
--
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ