Commit a6183cff authored by Flavio Ceolin's avatar Flavio Ceolin Committed by Anas Nashif
Browse files

pm: docs: sys_suspend -> pm_system_suspend



Change references to an old function name.

Signed-off-by: default avatarFlavio Ceolin <flavio.ceolin@intel.com>
parent 7e3e2093
Loading
Loading
Loading
Loading
+6 −6
Original line number Diff line number Diff line
@@ -180,7 +180,7 @@ in power saving mode. This method allows saving power even when the CPU is
active. The components that use the devices need to be power aware and should
be able to make decisions related to managing device power. In this method, the
SOC interface can enter CPU or SOC power states quickly when
:code:`sys_suspend()` gets called. This is because it does not need to
:code:`pm_system_suspend()` gets called. This is because it does not need to
spend time doing device power management if the devices are already put in
the appropriate power state by the application or component managing the
devices.
@@ -189,7 +189,7 @@ Central method
==============

In this method device power management is mostly done inside
:code:`sys_suspend()` along with entering a CPU or SOC power state.
:code:`pm_system_suspend()` along with entering a CPU or SOC power state.

If a decision to enter deep sleep is made, the implementation would enter it
only after checking if the devices are not in the middle of a hardware
@@ -332,21 +332,21 @@ off, then such transactions would be left in an inconsistent state. This
infrastructure guards such transactions by indicating to the SOC interface that
the device is in the middle of a hardware transaction.

When the :code:`sys_suspend()` is called, the SOC interface checks if any device
When the :code:`pm_system_suspend()` is called, the SOC interface checks if any device
is busy. The SOC interface can then decide to execute a power management scheme other than deep sleep or
to defer power management operations until the next call of
:code:`sys_suspend()`.
:code:`pm_system_suspend()`.

An alternative to using the busy status mechanism is to use the
`distributed method`_ of device power management. In such a method where the
device power management is handled in a distributed manner rather than centrally in
:code:`sys_suspend()`, the decision to enter deep sleep can be made based
:code:`pm_system_suspend()`, the decision to enter deep sleep can be made based
on whether all devices are already turned off.

This feature can be also used to emulate a hardware feature found in some SOCs
that causes the system to automatically enter deep sleep when all devices are idle.
In such an usage, the busy status can be set by default and cleared as each
device becomes idle. When :code:`sys_suspend()` is called, deep sleep can
device becomes idle. When :code:`pm_system_suspend()` is called, deep sleep can
be entered if no device is found to be busy.

Here are the APIs used to set, clear, and check the busy status of devices.
+1 −1
Original line number Diff line number Diff line
@@ -423,7 +423,7 @@ static int i2c_dw_transfer(const struct device *dev,

	/*
	 * While waiting at device_sync_sem, kernel can switch to idle
	 * task which in turn can call sys_suspend() hook of Power
	 * task which in turn can call pm_system_suspend() hook of Power
	 * Management App (PMA).
	 * device_busy_set() call here, would indicate to PMA that it should not
	 * execute PM policies that would turn off this ip block, causing an