lkml.org 
[lkml]   [2009]   [Jul]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Subject[PATCH V2 0/4] introduce device async actions mechanism
From
Date
Hi,

this is the patch set I made to speed up the device
suspend/resume/shutdown process.

A new mechanism called Device Async Actions is introduced
in this patch set.

The basic idea is that,
if the suspend/resume/shutdown process of a device group, including
a root device and its child devices, are independent of other devices,
we create an async domain for this device group,
and make them suspend/resume/shutdown asynchronously.

Note that this mechanism is not designed for all the devices.
Generally speaking, if we want to suspend/resume/shutdown a device
asynchronously, we should
1. find out a suitable device async group that contains this device.
2. get the root device in the device async group.
3. root device registers an async domain for this device async group,
with the proper async action type.

I tried to make it more generic but failed.
Because currently the dependency are pulled from the device tree, i.e.
parent devices will not be suspended until all of their children have
been suspended and children devices will not be resumed before the
parents.

But some hardware breaks this rule.
e.g.
00:1a.0 USB Controller: Intel Corporation 82801H USB UHCI Controller
00:1a.1 USB Controller: Intel Corporation 82801H USB UHCI Controller
00:1a.7 USB Controller: Intel Corporation 82801H USB2 EHCI Controller
these pci devices are siblings, but 00:1a.7 must be resumed after
00:1a.0, said by Alan Stern, while we can not get this dependency
from device tree.

Currently, in order to make sure that it won't bring any side effects,
I only convert the ACPI battery and i8042 to use this framework, which
reduces the S3 kernel time (kernel suspend and kernel resume time) from
7.0s to less than 6.5s.
And it also reduces 0.4s shutdown time in my test.

Any comments are welcome. :)

thanks,
rui

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2009-07-24 05:03    [W:0.087 / U:0.240 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site