diff options
author | Leah Rowe <leah@libreboot.org> | 2025-01-12 13:45:00 +0000 |
---|---|---|
committer | Leah Rowe <leah@libreboot.org> | 2025-01-12 13:45:00 +0000 |
commit | 66d084e7f7cba7a38e43de5204f439dd4ed4255b (patch) | |
tree | 9b898ed13e1d238975bbd46cf584696912f7188c /config/grub/xhci | |
parent | 5a3b0dab9668bbdc96d2bcf7e541fe0d99035b98 (diff) |
grub.cfg: scan luks *inside lvm*
the user might have boot their kernel inside luks
inside lvm for some dumb reason
it's theoretically possible that the user would be
so silly indeed
Signed-off-by: Leah Rowe <leah@libreboot.org>
Diffstat (limited to 'config/grub/xhci')
-rw-r--r-- | config/grub/xhci/config/payload | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/config/grub/xhci/config/payload b/config/grub/xhci/config/payload index ebfd1fea..d1f81fd3 100644 --- a/config/grub/xhci/config/payload +++ b/config/grub/xhci/config/payload @@ -191,15 +191,29 @@ menuentry 'Load Operating System (incl. fully encrypted disks) [o]' --hotkey='o search_bootcfg crypto + lvmvol="" + # after cryptomount, lvm volumes might be available # using * is slow on some machines, but we use it here, # just once. in so doing, we find every lvm volume for vol in (*); do if regexp ^lvm/ $vol; then + lvmvol="${lvmvol} ${vol}" try_bootcfg "${vol}" fi done + # user might have put luks inside lvm + set pager=0 + echo "Attempting to unlock encrypted LVMs" + for vol in ${lvmvol}; do + cryptomount "$vol" + done + set pager=1 + echo + + search_bootcfg crypto + true # Prevent pager requiring to accept each line instead of whole screen } |