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] [day] [month] [year] [list]
Date:	Fri, 26 Sep 2014 19:40:40 +0300
From:	Grygorii Strashko <grygorii.strashko@...com>
To:	Kevin Hilman <khilman@...nel.org>
CC:	<santosh.shilimkar@...com>,
	"Rafael J. Wysocki" <rjw@...ysocki.net>,
	Geert Uytterhoeven <geert+renesas@...der.be>,
	<linux-pm@...r.kernel.org>, <ben.dooks@...ethink.co.uk>,
	<laurent.pinchart@...asonboard.com>, <grant.likely@...retlab.ca>,
	<ulf.hansson@...aro.org>, <linux-arm-kernel@...ts.infradead.org>,
	<linux-kernel@...r.kernel.org>
Subject: Re: [RFC PATCH 2/4] ARM: keystone: pm: switch to use generic pm domains

On 09/26/2014 01:23 AM, Kevin Hilman wrote:
> Grygorii Strashko <grygorii.strashko@...com> writes:
>
>> This patch switches Keystone 2 PM code to use Generic PM domains
>> instead of PM  clock domains because of the lack of DT support
>> for the last.
>>
>> Keystone 2 PM domain should be specified per device for which
>> Runtime PM has to be enabled and handles the list of functional clocks
>> to enable/disable device.
>>
>> Example:
>>   qmss_domain: qmss_pm_controller {
>> 	compatible = "ti,keystone-pm-controller";
>> 	clocks = <&chipclk13>;
>> 	#power-domain-cells = <0>;
>>   };
>>
>>   qmss: qmss@...0000 {
>> 	compatible = "ti,keystone-navigator-qmss";
>> 	...
>> 	power-domains = <&qmss_domain>;
>>
>> Signed-off-by: Grygorii Strashko <grygorii.strashko@...com>
>
> [...]
>
>> +static int keystone_pm_domain_power_off(struct generic_pm_domain *genpd)
>> +{
>> +	int ret;
>> +	struct keystone_domain *dm = container_of(genpd,
>> +						  struct keystone_domain,
>> +						  base);
>> +
>> +	/* Enable reset clocks for all devices in the PU domain */
>
> This says enable clocks...
>
>> +	ret = pm_clk_suspend(dm->dev);
>
> ...but this calls clk_disable().
>
>> +	if (ret)
>> +		dev_err(dm->dev, "can't turn off clocks %d\n", ret);
>> +
>> +	return ret;
>> +}
>> +
>> +static int keystone_pm_domain_power_on(struct generic_pm_domain *genpd)
>> +{
>> +	int ret;
>> +	struct keystone_domain *dm = container_of(genpd,
>> +						  struct keystone_domain,
>> +						  base);
>> +
>> +	/* Disable reset clocks for all devices in the PU domain */
>
> And this says disable clocks...
>
>> +	ret = pm_clk_resume(dm->dev);
>
> ...but this calls clk_enable().
>
> -ECONFUSED.
>

Will update.

Thanks you for comments.

Regards,
-grygorii



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