mirror of
git://slackware.nl/current.git
synced 2024-12-30 10:24:23 +01:00
32 lines
1.1 KiB
Diff
32 lines
1.1 KiB
Diff
|
--- ./init.orig 2018-04-18 13:55:09.661574866 -0500
|
||
|
+++ ./init 2019-12-15 12:09:45.337013433 -0600
|
||
|
@@ -219,11 +219,15 @@
|
||
|
fi
|
||
|
|
||
|
LUKSLIST_DEFERRED=""
|
||
|
- LUKSLIST=$(echo $LUKSDEV | tr -s ':' ' ')
|
||
|
+ for dev in $(echo $LUKSDEV | tr -s ':' ' ') ; do
|
||
|
+ LUKSLIST="$LUKSLIST $(findfs $dev)"
|
||
|
+ done
|
||
|
+
|
||
|
+ for dev in $(echo $LUKSTRIM | tr -s ':' ' ') ; do
|
||
|
+ TRIMLIST="$TRIMLIST $(findfs $dev)"
|
||
|
+ done
|
||
|
+
|
||
|
for LUKSDEV in $LUKSLIST ; do
|
||
|
- if echo $LUKSDEV | grep -q "LABEL=" || echo $LUKSDEV | grep -q "UUID=" ; then
|
||
|
- LUKSDEV=$(findfs $LUKSDEV)
|
||
|
- fi
|
||
|
if /sbin/cryptsetup isLuks ${LUKSDEV} 1>/dev/null 2>/dev/null ; then
|
||
|
if echo $ROOTDEV | grep -q "LABEL=" || echo $ROOTDEV | grep -q "UUID=" ; then
|
||
|
CRYPTDEV="luks$(basename $LUKSDEV)"
|
||
|
@@ -232,7 +236,7 @@
|
||
|
else
|
||
|
CRYPTDEV="luks$(basename $LUKSDEV)"
|
||
|
fi
|
||
|
- if echo $LUKSTRIM | grep -wq $LUKSDEV 2>/dev/null ; then
|
||
|
+ if echo "$TRIMLIST" | grep -wq "$LUKSDEV" 2>/dev/null ; then
|
||
|
LUKSOPTS="--allow-discards"
|
||
|
else
|
||
|
LUKSOPTS=""
|