[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <200908032318.35070.rjw@sisk.pl>
Date: Mon, 3 Aug 2009 23:18:33 +0200
From: "Rafael J. Wysocki" <rjw@...k.pl>
To: Zhang Rui <rui.zhang@...el.com>
Cc: Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
"linux-pm" <linux-pm@...ts.linux-foundation.org>,
"linux-acpi" <linux-acpi@...r.kernel.org>,
Pavel Machek <pavel@....cz>, Len Brown <lenb@...nel.org>,
Alan Stern <stern@...land.harvard.edu>,
Arjan van de Ven <arjan@...ux.intel.com>, dtor@...l.ru
Subject: Re: [PATCH V2 0/4] introduce device async actions mechanism
On Friday 24 July 2009, Zhang Rui wrote:
> Hi,
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.
Well, I'm not sure we'll need that.
> 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.
I don't really think this is the right approach. IMO, we should rather try to
identify groups of devices for which the PM callbacks (forget about .shutdown()
for now) can be executed in parallel. One such group is leaf devices, ie.
devices that have no children. Of course, some of them will depend of the
other indirectly, so we should make it possible to declare (in the driver)
whether the device can be suspended/resumed asynchronously and use the
following logic (at the core level), in pseudo code:
if (has_no_children(dev) && asynchronous_suspend_resume_allowed(dev))
async_resume(dev);
else
resume(dev);
and analogously for suspend. Then, we can easily use one async domain for all
of these devices.
Later, we can add async domains for devices that have children, but can be
suspended and woken up in parallel with each other. IOW, I think the async
domains should span the levels rather than branches of the device tree.
Thanks,
Rafael
--
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