summaryrefslogtreecommitdiff
path: root/core/cryptsetup/encrypt_hook
diff options
context:
space:
mode:
Diffstat (limited to 'core/cryptsetup/encrypt_hook')
-rw-r--r--core/cryptsetup/encrypt_hook5
1 files changed, 3 insertions, 2 deletions
diff --git a/core/cryptsetup/encrypt_hook b/core/cryptsetup/encrypt_hook
index 372b7ba57..11db3443a 100644
--- a/core/cryptsetup/encrypt_hook
+++ b/core/cryptsetup/encrypt_hook
@@ -11,7 +11,9 @@ run_hook() {
$cryptkey
EOF
- if resolved=$(resolve_device "${ckdev}" ${rootdelay}); then
+ if [ "$ckdev" = "rootfs" ]; then
+ ckeyfile=$ckarg1
+ elif resolved=$(resolve_device "${ckdev}" ${rootdelay}); then
case ${ckarg1} in
*[!0-9]*)
# Use a file on the device
@@ -50,7 +52,6 @@ EOF
for cryptopt in ${cryptoptions//,/ }; do
case ${cryptopt} in
allow-discards)
- echo "Enabling TRIM/discard support."
cryptargs="${cryptargs} --allow-discards"
;;
*)