"Theodore Ts'o" <tytso@xxxxxxx> writes: > Another fix would be making sure that the kernel isues the file system > syncs, and waits for them to be completed, *before* we freeze the > disk. That way, if there are any dirty pages, they can be flushed to > stable store so that if the battery runs down while the laptop is > suspended, the user won't see data loss. That's exactly how it works now. The kernel syncs the fs before suspending, but during that sync, even though there were no dirty pages and so nothing has been written to the disk and it has been runtime suspended, the fs issues a flush, which wakes the disk up, only to be put right back to sleep so the system can transition to S3.