Simplify the code a bit by using newly added (to kldstat(8) '-q') option.
This commit is contained in:
parent
7386c52294
commit
0b524fa9c8
@ -46,10 +46,7 @@ geli_start()
|
||||
return
|
||||
fi
|
||||
|
||||
geli load >/dev/null 2>&1
|
||||
if ! kldstat -m g_eli >/dev/null 2>&1; then
|
||||
err 1 'geom_eli module failed to load.'
|
||||
fi
|
||||
kldstat -q -m g_eli || geli load || err 1 'geom_eli module failed to load.'
|
||||
|
||||
if [ -z "${geli_tries}" ]; then
|
||||
if [ -n "${geli_attach_attempts}" ]; then
|
||||
|
Loading…
x
Reference in New Issue
Block a user