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-next>] [day] [month] [year] [list]
Date:	Tue, 10 Dec 2013 14:37:39 +0100
From:	Ulf Hansson <ulf.hansson@...aro.org>
To:	"Rafael J. Wysocki" <rjw@...ysocki.net>,
	Len Brown <len.brown@...el.com>, Pavel Machek <pavel@....cz>,
	linux-pm@...r.kernel.org
Cc:	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
	Ulf Hansson <ulf.hansson@...aro.org>
Subject: [PATCH V2 0/3] PM: Enable option of re-use runtime PM callbacks at system suspend

To put devices into low power state during system suspend, it is convenient
for some runtime PM supported power domains, subsystems and drivers to have
the option of re-using and invoking the runtime PM callbacks from their system
PM callbacks.

The benefit is that we don't need to implement wrapper functions which
handles runtime PM resourses, typically called from both runtime PM and system
PM callbacks.

Some new helper macros for defining the PM callbacks are added.

SET_PM_RUNTIME_PM_OPS; to define runtime PM callbacks for CONFIG_PM instead of
CONFIG_PM_RUNTIME.

SET_LATE_SYSTEM_SLEEP_PM_OPS; to define common late/early system PM callbacks,
same approach is applicable to the existing SET_SYSTEM_SLEEP_PM_OPS which
defines common suspend/resume system PM callbacks.

A minor fix was needed for the platform bus, which runtime PM callbacks are set
to the pm_generic_runtime_suspend|resume functions. These were implemented only
for CONFIG_PM_RUNTIME and thus the platform bus prevented driver's runtime PM
callbacks to be invoked when only CONFIG_PM_SLEEP was used. We move them into
CONFIG_PM to resolve the problem.

Changes in v2:
	Updated commit messages to try to better reflect the changes. 
	Removed the below patches from this patch set. Let's leave those to be
	addressed separately, if needed.
	- PM / Sleep: Add pm_generic functions to re-use runtime PM callbacks
	- drm/exynos: Convert to suspend_late/resume_early callbacks for fimc


Ulf Hansson (3):
  PM / Runtime: Add second macro for definition of runtime PM callbacks
  PM / Runtime: Implement the pm_generic_runtime functions for
    CONFIG_PM
  PM / Sleep: Add macro to define common late/early system PM callbacks

 drivers/base/power/generic_ops.c |    4 ++--
 include/linux/pm.h               |   21 +++++++++++++++++++++
 include/linux/pm_runtime.h       |   12 ++++++++----
 3 files changed, 31 insertions(+), 6 deletions(-)

-- 
1.7.9.5

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