.\" This manpage has been automatically generated by docbook2man .\" from a DocBook document. This tool can be found at: .\" .\" Please send any bug reports, improvements, comments, patches, .\" etc. to Steve Cheng . .TH "DEVICE_SUSPEND" "9" "09 October 2005" "" "" .SH NAME device_suspend \- Save state and stop all devices in system. .SH SYNOPSIS "SYNOPSIS" .sp \fB .sp int device_suspend (pm_message_t \fIstate\fB); \fR .SH "ARGUMENTS" .TP \fB\fIstate\fB\fR Power state to put each device in. .SH "DESCRIPTION" .PP Walk the dpm_active list, call ->\fBsuspend\fR for each device, and move it to dpm_off. Check the return value for each. If it returns 0, then we move the the device to the dpm_off list. If it returns -EAGAIN, we move it to the dpm_off_irq list. If we get a different error, try and back out. .PP If we hit a failure with any of the devices, call \fBdevice_resume\fR above to bring the suspended devices back to life.