Comment 8 for bug 1878340

Revision history for this message
In , alecfeldman (alecfeldman-linux-kernel-bugs) wrote :

From looking deeper into this issue and reading the FAQ on the bcache site, this appears to be a catch 22 issue. During resume, you are not allowed to make any changes to the disk. However, with bcache, this can be tricky: any read you make from a bcache device could result in a write to update the caching device. Currently bcache has no good ways of solving this. This means resume must finish before bcache starts. However, if the resume image is on the bcache backing device, the image must be accessed first. Using resume_offset to use the swap file on the backing device must be updating the caching device, and subsequently causing data loss. If I have reached the correct conclusion from the data loss that occured on my system and the limitation listed on the bcache FAQ, then that means resuming from a swap file on a backing device, at least with the cache enabled, is not possible. Disabling the cache during resume may prevent data loss from occuring.