Linux Power Management development
 help / color / mirror / Atom feed
* [RFC PATCH 0/3] PM: hibernate: encrypted snapshots under lockdown
@ 2026-07-13 15:39 Sean Rhodes
  2026-07-13 15:39 ` [RFC PATCH 1/3] PM: hibernate: add seed-wrapped encrypted snapshots Sean Rhodes
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Sean Rhodes @ 2026-07-13 15:39 UTC (permalink / raw)
  To: Rafael J. Wysocki, Len Brown, Pavel Machek, linux-pm,
	linux-kernel
  Cc: Evan Green, Xueqin Luo

This is an RFC for allowing hibernate with lockdown enabled.

The kernel still refuses plain hibernate images under lockdown. This adds an
encrypted snapshot path instead. Early userspace gives the kernel a seed, the
kernel locks it, and /dev/snapshot can then create/load encrypted images. If
that seed is not present and locked, lockdown keeps blocking hibernate as it
does today.

This is based on the older encrypted hibernate work, but with the TPM policy
pushed out of the kernel. The kernel side just handles the snapshot encryption
and the seed ABI.

Testing on Star Labs StarFighter: dmesg shows the seed was locked, S4
entry/exit, and no errors.

Sending as RFC because the ABI and early-userspace split need review before
this should be a proper v1.

Evan Green (1):
  PM: hibernate: add seed-wrapped encrypted snapshots

Sean Rhodes (2):
  PM: hibernate: permit encrypted snapshot device under lockdown
  PM: hibernate: document encrypted snapshot seed ABI

 Documentation/ABI/testing/sysfs-power   |  14 +
 Documentation/power/userland-swsusp.rst |  19 +
 include/uapi/linux/suspend_ioctls.h     |  31 +-
 kernel/power/Kconfig                    |  15 +
 kernel/power/Makefile                   |   1 +
 kernel/power/hibernate.c                |  32 +
 kernel/power/power.h                    |   2 +
 kernel/power/snapenc.c                  | 878 ++++++++++++++++++++++++
 kernel/power/snapshot.c                 |   5 +
 kernel/power/user.c                     |  94 ++-
 kernel/power/user.h                     | 133 ++++
 11 files changed, 1204 insertions(+), 20 deletions(-)
 create mode 100644 kernel/power/snapenc.c
 create mode 100644 kernel/power/user.h


base-commit: dd3210c47e8d3ac6b4e9141fc68acc03b38c0ba3
-- 
2.53.0

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2026-07-13 15:39 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-13 15:39 [RFC PATCH 0/3] PM: hibernate: encrypted snapshots under lockdown Sean Rhodes
2026-07-13 15:39 ` [RFC PATCH 1/3] PM: hibernate: add seed-wrapped encrypted snapshots Sean Rhodes
2026-07-13 15:39 ` [RFC PATCH 2/3] PM: hibernate: permit encrypted snapshot device under lockdown Sean Rhodes
2026-07-13 15:39 ` [RFC PATCH 3/3] PM: hibernate: document encrypted snapshot seed ABI Sean Rhodes

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox