Re: [PATCH] Hotplug for device power state changes
From: Todd Poynor
Date: Mon May 03 2004 - 17:07:19 EST
Nigel Cunningham wrote:
Given this model, I would suggest that hotplug should silently drop any
events that happen while suspending, and queue events that occur while
resuming until the kernelspace part of resuming is complete and
userspace can run as normal. It shouldn't rely upon device
suspend/resume notifications because they can and do happen while we're
still in the process of suspending and resuming. The means to detect
whether we're suspending or resuming or running normally could be
implemented as a simple function that could test the status of the
different suspend implementations.
If needed, there's already a "system_running" flag used to ignore the
underlying usermode helper execution if requested prior to the system
being ready for such an event at boot time, and perhaps this could be
co-opted or extended for use at suspend/resume time. Sounds like the
correct behavior is to leave the exec requests queued until userspace is
resumed (and I'd assume that device power state notifications are not
needed, but perhaps hotplug events and/or modprobes of drivers for
hotpluggable devices and associated features may be generated at resume
time). Thanks,
--
Todd Poynor
MontaVista Software
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/