Talk:Custom Initramfs/Hibernation

Hi frostschutz, Did you make more progress on this? My laptop never hibernated 'cos of its AMDGPU driver; reading around, that might now be fixed, but in the meantime I've started using an initramfs, so your article would be useful, if it were complete...

My first question is to wonder why the initramfs is involved - at least for the swap partition case. I'd like to believe the kernel saw it was resuming, loaded memory from the resume partition, and away it goes - anything else seems madness... But as there seem to be initramfs hooks for resume in Arch, Debian, Systemd, etc. I presume it's not that simple, hence your article.

If the initramfs needs to support resume, at least for swap partition, I'd presume it should look to see if resume is possible, and if so, do it, as above, and should not get its fingers dirty with anything else at all (eg fsck, LVM, crypto (unless needed to read the swap partition)).

Not using a real swap partition for resume strikes me as really scary - the initramfs will need to do fs-related stuff to locate the hibernation data, which is dangerously close to transgressing the rules on touching filesystems. Goverp (talk) 08:36, 13 July 2021 (UTC)