USB resume guarantees
Tilman Schmidt <[email protected]>
| Newsgroups | gmane.linux.usb.devel |
|---|---|
| Organization | me - organized?? |
| Message-ID | <[email protected]> |
While trying to add suspend/resume support to the USB drivers I maintain, I came across the following unexpected sequence of events with kernel 2.6.24-rc2: - I request suspend to disk by doing echo shutdown > /sys/power/disk ; echo disk > /sys/power/state - My driver's suspend method is called, which uses tasklet_disable() to prevent a tasklet from resubmitting URBs. - The system powers down as expected. - I power it up again. - The USB subsystem (compiled with CONFIG_USB_DEBUG) syslogs "root hub lost power or was reset" for all the USB busses. - My driver's disconnect method is called. *Not* the resume method, *not* the reset_resume method, *just* the disconnect method. - My driver's probe method is called. - Driver operation is blocked because the tasklet is still disabled. There are tasklet_enable() calls in my resume and reset_resume methods, but those were never called. - When I unplug the device to clear up the condition, khubd and ksoftirqd start hogging my CPU. From reading Documentation/usb/power-management.txt I gathered the impression that suspend and resume/reset_resume calls would be paired, iow I could rely on either resume or reset_resume being called once for every call of suspend, but obviously that ain't so. So what are the possible sequences of events my driver must be prepared to cope with? Thanks Tilman -- Tilman Schmidt E-Mail: [email protected] Bonn, Germany Diese Nachricht besteht zu 100% aus wiederverwerteten Bits. Ungeöffnet mindestens haltbar bis: (siehe Rückseite) ------------------------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ _______________________________________________ [email protected] To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel
signature.asc
(application/pgp-signature, 253 B)
-----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.3rc1 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFHN4WcMdB4Whm86/kRAlVVAJ4/6WJwXG+m7NPFgkbIFvSSmBC0XQCeIJxy URC3d6B1OrOY78mU0rhV+24= =fbSD -----END PGP SIGNATURE-----